Skip to content
This repository has been archived by the owner on Nov 17, 2020. It is now read-only.

Commit

Permalink
No need to forward-declare tls_atom_version() type
Browse files Browse the repository at this point in the history
It was needed to fix the build with Erlang R16B03. Now that the minimum
version is Erlang 18.3 in master, we can revert what was done in
c9a9a9b.

[#118562897]
  • Loading branch information
dumbbell committed Jul 6, 2016
1 parent 9ac4ae3 commit bd25b0e
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 21 deletions.
10 changes: 0 additions & 10 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -24,16 +24,6 @@ include erlang.mk
include mk/rabbitmq-build.mk
include mk/rabbitmq-dist.mk

# --------------------------------------------------------------------
# Compilation.
# --------------------------------------------------------------------

# $(ERTS_VER) is set in `rabbitmq-build.mk` above.
tls_atom_version_MAX_ERTS_VER = 6.0
ifeq ($(call compare_version,$(ERTS_VER),$(tls_atom_version_MAX_ERTS_VER),<),true)
RMQ_ERLC_OPTS += -Ddefine_tls_atom_version
endif

# --------------------------------------------------------------------
# Framing sources generation.
# --------------------------------------------------------------------
Expand Down
4 changes: 0 additions & 4 deletions mk/rabbitmq-build.mk
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,6 @@ lager_extra_sinks = $(subst $(space),$(comma),$(LAGER_EXTRA_SINKS))
RMQ_ERLC_OPTS += +'{parse_transform,lager_transform}' \
+'{lager_extra_sinks,[$(lager_extra_sinks)]}'

# Erlang R16B03 has no support for new types in Erlang 17.0, leading to
# a build-time error.
ERTS_VER := $(shell erl -version 2>&1 | sed -E 's/.* version //')

# Push our compilation options to both the normal and test ERLC_OPTS.
ERLC_OPTS += $(RMQ_ERLC_OPTS)
TEST_ERLC_OPTS += $(RMQ_ERLC_OPTS)
Expand Down
7 changes: 0 additions & 7 deletions src/rabbit_net.erl
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,6 @@
-module(rabbit_net).
-include("rabbit.hrl").

-ifdef(define_tls_atom_version).
%% In Erlang R16B03, tls_atom_version() is defined in ssl_internal.hrl,
%% which is not included by ssl_api.hrl. Instead of including it here,
%% we redefine it to avoid too much pollution.
-type tls_atom_version() :: sslv3 | tlsv1 | 'tlsv1.1' | 'tlsv1.2'.
-endif.

-include_lib("ssl/src/ssl_api.hrl").

-export([is_ssl/1, ssl_info/1, controlling_process/2, getstat/2,
Expand Down

0 comments on commit bd25b0e

Please sign in to comment.