From 313c553bafd5d542c75ed625141e9267070eccfb Mon Sep 17 00:00:00 2001 From: "H. Vetinari" Date: Wed, 25 May 2022 13:11:53 +0200 Subject: [PATCH] turn into multi-output recipe --- recipe/{bld.bat => build-abseil.bat} | 0 recipe/{build.sh => build-abseil.sh} | 0 recipe/meta.yaml | 69 ++++++++++++++++------------ 3 files changed, 39 insertions(+), 30 deletions(-) rename recipe/{bld.bat => build-abseil.bat} (100%) rename recipe/{build.sh => build-abseil.sh} (100%) diff --git a/recipe/bld.bat b/recipe/build-abseil.bat similarity index 100% rename from recipe/bld.bat rename to recipe/build-abseil.bat diff --git a/recipe/build.sh b/recipe/build-abseil.sh similarity index 100% rename from recipe/build.sh rename to recipe/build-abseil.sh diff --git a/recipe/meta.yaml b/recipe/meta.yaml index 7d3953f..15d7810 100644 --- a/recipe/meta.yaml +++ b/recipe/meta.yaml @@ -1,5 +1,16 @@ {% set version = "20220623.0" %} +{% set absl_libs = [ + "base", "civil_time", "cord", "cordz_functions", "cordz_handle", "cordz_info", + "cordz_sample_token", "examine_stack", "exponential_biased", "failure_signal_handler", + "flags", "flags_commandlineflag", "flags_config", "flags_marshalling", "flags_parse", + "flags_private_handle_accessor", "flags_program_name", "flags_reflection", "flags_usage", + "hash", "hashtablez_sampler", "int128", "log_severity", "low_level_hash", "periodic_sampler", + "random_distributions", "random_seed_gen_exception", "random_seed_sequences", "raw_hash_set", + "scoped_set_env", "spinlock_wait", "stacktrace", "status", "statusor", "strerror", "strings", + "symbolize", "synchronization", "time", "time_zone" +] %} + package: name: abseil-cpp version: {{ version }} @@ -18,38 +29,36 @@ build: run_exports: - {{ pin_subpackage("abseil-cpp", max_pin="x.x") }} -requirements: - build: - - {{ compiler('c') }} - - {{ compiler('cxx') }} - - cmake - - ninja +outputs: + - name: abseil-cpp + script: build-abseil.sh # [unix] + script: build-abseil.bat # [win] + build: + run_exports: + - {{ pin_subpackage("abseil-cpp", max_pin="x.x") }} -{% set absl_libs = [ - "base", "civil_time", "cord", "cordz_functions", "cordz_handle", "cordz_info", - "cordz_sample_token", "examine_stack", "exponential_biased", "failure_signal_handler", - "flags", "flags_commandlineflag", "flags_config", "flags_marshalling", "flags_parse", - "flags_private_handle_accessor", "flags_program_name", "flags_reflection", "flags_usage", - "hash", "hashtablez_sampler", "int128", "log_severity", "low_level_hash", "periodic_sampler", - "random_distributions", "random_seed_gen_exception", "random_seed_sequences", "raw_hash_set", - "scoped_set_env", "spinlock_wait", "stacktrace", "status", "statusor", "strerror", "strings", - "symbolize", "synchronization", "time", "time_zone" -] %} -test: - commands: - # windows (DLL + import library) - - if not exist %LIBRARY_BIN%\\abseil_dll.dll exit 1 # [win] - - if not exist %LIBRARY_LIB%\\abseil_dll.lib exit 1 # [win] + requirements: + build: + - {{ compiler('c') }} + - {{ compiler('cxx') }} + - cmake + - ninja + + test: + commands: + # windows-only (almost-)all-in-one DLL + import library + - if not exist %LIBRARY_BIN%\\abseil_dll.dll exit 1 # [win] + - if not exist %LIBRARY_LIB%\\abseil_dll.lib exit 1 # [win] - # absl_libs - {% for each_lib in absl_libs %} - # presence of shared libs - - test -f $PREFIX/lib/libabsl_{{ each_lib }}${SHLIB_EXT} # [unix] - # absence of static libs - - test ! -f $PREFIX/lib/libabsl_{{ each_lib }}.a # [unix] - # TODO: do we want to get rid of the static windows libs? - # - if exist %LIBRARY_LIB%\\absl_{{ each_lib }}.lib exit 1 # [win] - {% endfor %} + # absl_* libraries + {% for each_lib in absl_libs %} + # presence of shared libs + - test -f $PREFIX/lib/libabsl_{{ each_lib }}${SHLIB_EXT} # [unix] + # absence of static libs + - test ! -f $PREFIX/lib/libabsl_{{ each_lib }}.a # [unix] + # TODO: do we want to get rid of the static windows libs? + # - if exist %LIBRARY_LIB%\\absl_{{ each_lib }}.lib exit 1 # [win] + {% endfor %} about: home: https://github.com/abseil/abseil-cpp