diff options
| author | David Wragg <david@rabbitmq.com> | 2011-01-30 09:02:12 +0000 |
|---|---|---|
| committer | David Wragg <david@rabbitmq.com> | 2011-01-30 09:02:12 +0000 |
| commit | 5a149c9047487e6daef073c661d5951569b81a0a (patch) | |
| tree | 9861edaeb11fb15cab8acf8fdd97a342e8605f0f | |
| parent | f702995d658e363c0d92c5b2b30d2b8632550f0f (diff) | |
| download | rabbitmq-server-git-5a149c9047487e6daef073c661d5951569b81a0a.tar.gz | |
Make the USE_SPECS erlang version check more robust
And eliminate extraneous processes forked on each erlc.
| -rw-r--r-- | Makefile | 6 |
1 files changed, 2 insertions, 4 deletions
@@ -42,13 +42,11 @@ RABBIT_PLT=rabbit.plt ifndef USE_SPECS # our type specs rely on features and bug fixes in dialyzer that are # only available in R14A upwards (R13B04 is erts 5.7.5) -# -# NB: the test assumes that version number will only contain single digits -USE_SPECS=$(shell if [ $$(erl -noshell -eval 'io:format(erlang:system_info(version)), halt().') \> "5.7.5" ]; then echo "true"; else echo "false"; fi) +USE_SPECS:=$(shell erl -noshell -eval 'io:format(lists:map(fun erlang:list_to_integer/1, string:tokens(erlang:system_info(version), ".")) >= [5,8]),halt().') endif #other args: +native +"{hipe,[o3,verbose]}" -Ddebug=true +debug_info +no_strict_record_tests -ERLC_OPTS=-I $(INCLUDE_DIR) -o $(EBIN_DIR) -Wall -v +debug_info $(shell [ $(USE_SPECS) = "true" ] && echo "-Duse_specs") +ERLC_OPTS=-I $(INCLUDE_DIR) -o $(EBIN_DIR) -Wall -v +debug_info $(if $(filter true,$(USE_SPECS)),-Duse_specs) VERSION=0.0.0 TARBALL_NAME=rabbitmq-server-$(VERSION) |
