346N/A#
346N/A# CDDL HEADER START
346N/A#
346N/A# The contents of this file are subject to the terms of the
346N/A# Common Development and Distribution License (the "License").
346N/A# You may not use this file except in compliance with the License.
346N/A#
346N/A# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
346N/A# or http://www.opensolaris.org/os/licensing.
346N/A# See the License for the specific language governing permissions
346N/A# and limitations under the License.
346N/A#
346N/A# When distributing Covered Code, include this CDDL HEADER in each
346N/A# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
346N/A# If applicable, add the following below this CDDL HEADER, with the
346N/A# fields enclosed by brackets "[]" replaced with your own identifying
346N/A# information: Portions Copyright [yyyy] [name of copyright owner]
346N/A#
346N/A# CDDL HEADER END
346N/A#
346N/A
346N/A#
3996N/A# Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved.
346N/A#
346N/A
4256N/A# Built in SFW with gcc and builds cleanly now only with gcc
3996N/ACOMPILER = gcc
3996N/A
346N/Ainclude ../../make-rules/shared-macros.mk
346N/A
4256N/APATH=$(JAVA_HOME)/bin:/usr/bin
783N/A
1273N/ACOMPONENT_NAME= erlang
4256N/ACOMPONENT_VERSION= 17.5
618N/ACOMPONENT_PROJECT_URL= http://www.erlang.org/
1273N/ACOMPONENT_SRC_NAME= otp_src
1273N/ACOMPONENT_SRC= $(COMPONENT_SRC_NAME)_$(COMPONENT_VERSION)
4256N/ACOMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.gz
844N/ACOMPONENT_ARCHIVE_HASH= \
4256N/A sha256:3c28820c981b30c50df8ac2a4a238e5813454fa3ed2ad530bc7948a282846474
618N/ACOMPONENT_ARCHIVE_URL= $(COMPONENT_PROJECT_URL)download/$(COMPONENT_ARCHIVE)
1273N/ACOMPONENT_BUGDB= utility/erlang
346N/A
346N/A# manpages
346N/ACOMPONENT_NAME_1= otp_doc_man
346N/ACOMPONENT_SRC_1= $(COMPONENT_NAME_1)_$(COMPONENT_VERSION)
4256N/ACOMPONENT_ARCHIVE_1= $(COMPONENT_SRC_1).tar.gz
844N/ACOMPONENT_ARCHIVE_HASH_1= \
4256N/A sha256:85b1b2a1011fc01af550f1fe9e5a599a4c5f2a35d264d2804af1d05590a857c3
618N/ACOMPONENT_ARCHIVE_URL_1= $(COMPONENT_PROJECT_URL)download/$(COMPONENT_ARCHIVE_1)
346N/A
346N/A# HTML documentation
346N/ACOMPONENT_NAME_2= otp_doc_html
346N/ACOMPONENT_SRC_2= $(COMPONENT_NAME_2)_$(COMPONENT_VERSION)
4256N/ACOMPONENT_ARCHIVE_2= $(COMPONENT_SRC_2).tar.gz
844N/ACOMPONENT_ARCHIVE_HASH_2= \
4256N/A sha256:baba1d373c1faacf4a1a6ec1220d57d0cb2b977edb74f32cd58dc786361c6cf5
618N/ACOMPONENT_ARCHIVE_URL_2= $(COMPONENT_PROJECT_URL)download/$(COMPONENT_ARCHIVE_2)
346N/A
3090N/ATPNO= 18548
3090N/A
3996N/Ainclude $(WS_MAKE_RULES)/prep.mk
3996N/Ainclude $(WS_MAKE_RULES)/configure.mk
3996N/Ainclude $(WS_MAKE_RULES)/ips.mk
346N/A
346N/ACONFIGURE_OPTIONS += CFLAGS="$(CFLAGS)"
346N/ACONFIGURE_OPTIONS += CPPFLAGS="$(CPPFLAGS) -I/usr/include/gd2"
346N/ACONFIGURE_OPTIONS += --enable-smp-support
346N/ACONFIGURE_OPTIONS += --enable-threads
4256N/A# The HiPE portion is a bit sensitive, and only seems to work 64-bit on
2656N/A# amd64 (thus the variant.arch tagging in erlang.p5m). erts/config.log
4256N/A# can be very interesting if issues occur.
346N/ACONFIGURE_OPTIONS += --enable-hipe
346N/ACONFIGURE_OPTIONS += --with-ssl
346N/ACONFIGURE_OPTIONS += --enable-dynamic-ssl-lib
346N/A
2656N/ACONFIGURE_BINDIR.64 = $(CONFIGURE_PREFIX)/bin
2656N/A
346N/ACONFIGURE_OPTIONS.64 += LDFLAGS="$(LDFLAGS) -m64"
346N/ACONFIGURE_OPTIONS.64 += LIBS="-m64"
346N/A
2656N/A# Needed for 'set name=info.source-url' action in erlang-doc.p5m
4256N/APKG_MACROS += COMPONENT_ARCHIVE_URL_2=$(COMPONENT_ARCHIVE_URL_2)
2656N/A
351N/A# Use cp(1) instead of cloney because erlang's 'install' target uses 'tar'
351N/A# to copy files and our tar doesn't handle long links by default. Between
351N/A# the use of 'tar' and 'ld', a path adjustment wasn't an option due to the
4256N/A# need for /usr/bin/ld and /usr/gnu/bin/tar. This is still the case with
4256N/A# erlang version 17.5.
346N/ACOMPONENT_PRE_CONFIGURE_ACTION = \
351N/A ($(CP) -rp $(SOURCE_DIR)/. $(@D))
4256N/ACONFIGURE_SCRIPT = $(@D)/configure
4256N/A
4256N/A# Always show the build and link lines for easier debugging.
4256N/ACOMPONENT_BUILD_ARGS += V=1
346N/A
346N/ACOMPONENT_INSTALL_ARGS += INSTALL_PREFIX=$(PROTO_DIR)
346N/A
2656N/ACOMPONENT_TEST_ENV += ERL_TOP=$(BUILD_DIR_64)
2656N/ACOMPONENT_TEST_TARGETS = tests
2656N/A
4256N/A# Remove the two lines which contains the tester's username.
4256N/ACOMPONENT_TEST_TRANSFORMS += \
4256N/A '-e "s|/ldisk/tests|XXX_UID_XXX|g" ' \
4256N/A '-e "/XXX_UID_XXX/d" '
4256N/A
2656N/AASLR_MODE = $(ASLR_ENABLE)
2656N/A
4256N/Aconfigure: $(CONFIGURE_64)
4256N/A
2656N/Abuild: $(BUILD_64)
346N/A
2656N/Ainstall: $(INSTALL_64)
346N/A # Undelivered useless files:
346N/A # erlang/lib/crypto-*/priv/obj
346N/A # erlang/lib/ssl-*/priv/obj
346N/A # erlang/Install
346N/A # erlang/misc
346N/A # erlang/*/*.bat
346N/A # manpages: start.1 werl.1
346N/A $(RM) -r documentation
346N/A $(MKDIR) documentation && cd documentation && \
346N/A $(UNPACK) $(UNPACK_ARGS) ../$(COMPONENT_ARCHIVE_1) && \
346N/A $(UNPACK) $(UNPACK_ARGS) ../$(COMPONENT_ARCHIVE_2)
346N/A # remove INSTALL_PREFIX from path
2656N/A $(PERL) -pi -e "s|$(PROTO_DIR)||g" \
346N/A $(PROTO_DIR)/usr/lib/$(MACH64)/erlang/bin/erl \
346N/A $(PROTO_DIR)/usr/lib/$(MACH64)/erlang/releases/RELEASES
346N/A
346N/Aclean::
346N/A $(RM) -r documentation
346N/A
2656N/Atest: $(TEST_64)
346N/A
3996N/AREQUIRED_PACKAGES += library/ncurses
3996N/AREQUIRED_PACKAGES += library/security/openssl
4256N/AREQUIRED_PACKAGES += library/security/openssl/openssl-fips-140
4256N/AREQUIRED_PACKAGES += library/zlib
3996N/AREQUIRED_PACKAGES += shell/ksh93
3996N/AREQUIRED_PACKAGES += system/core-os
3996N/AREQUIRED_PACKAGES += system/library
3996N/AREQUIRED_PACKAGES += system/library/math
3996N/AREQUIRED_PACKAGES += system/linker