0N/A#
0N/A# CDDL HEADER START
0N/A#
0N/A# The contents of this file are subject to the terms of the
0N/A# Common Development and Distribution License (the "License").
0N/A# You may not use this file except in compliance with the License.
0N/A#
0N/A# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
0N/A# or http://www.opensolaris.org/os/licensing.
0N/A# See the License for the specific language governing permissions
0N/A# and limitations under the License.
0N/A#
0N/A# When distributing Covered Code, include this CDDL HEADER in each
0N/A# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
0N/A# If applicable, add the following below this CDDL HEADER, with the
0N/A# fields enclosed by brackets "[]" replaced with your own identifying
0N/A# information: Portions Copyright [yyyy] [name of copyright owner]
0N/A#
0N/A# CDDL HEADER END
0N/A#
0N/A
0N/A#
0N/A# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved.
0N/A#
0N/A# Built in SFW with gcc and builds cleanly now only with gcc
0N/ABUILD_BITS= 64
0N/ACOMPILER= gcc
0N/Ainclude ../../make-rules/shared-macros.mk
0N/A
0N/APATH=$(JAVA_HOME)/bin:$(USRBINDIR)
0N/A
0N/ACOMPONENT_NAME= erlang
0N/ACOMPONENT_VERSION= 17.5
0N/ACOMPONENT_PROJECT_URL= http://www.erlang.org/
0N/ACOMPONENT_SRC_NAME= otp_src
0N/ACOMPONENT_SRC= $(COMPONENT_SRC_NAME)_$(COMPONENT_VERSION)
0N/ACOMPONENT_ARCHIVE_HASH= \
0N/A sha256:3c28820c981b30c50df8ac2a4a238e5813454fa3ed2ad530bc7948a282846474
0N/ACOMPONENT_ARCHIVE_URL= $(COMPONENT_PROJECT_URL)download/$(COMPONENT_ARCHIVE)
0N/A
0N/A# manpages
0N/ACOMPONENT_NAME_1= otp_doc_man
0N/ACOMPONENT_SRC_1= $(COMPONENT_NAME_1)_$(COMPONENT_VERSION)
0N/ACOMPONENT_ARCHIVE_1= $(COMPONENT_SRC_1).tar.gz
0N/ACOMPONENT_ARCHIVE_HASH_1= \
0N/A sha256:85b1b2a1011fc01af550f1fe9e5a599a4c5f2a35d264d2804af1d05590a857c3
0N/ACOMPONENT_ARCHIVE_URL_1= $(COMPONENT_PROJECT_URL)download/$(COMPONENT_ARCHIVE_1)
0N/AUNPACK_ARGS_1= -r $(COMPONENT_SRC_1)
0N/APKG_PROTO_DIRS += $(COMPONENT_SRC_1)
0N/A
0N/A# HTML documentation
0N/ACOMPONENT_NAME_2= otp_doc_html
0N/ACOMPONENT_SRC_2= $(COMPONENT_NAME_2)_$(COMPONENT_VERSION)
0N/ACOMPONENT_ARCHIVE_2= $(COMPONENT_SRC_2).tar.gz
0N/ACOMPONENT_ARCHIVE_HASH_2= \
0N/A sha256:baba1d373c1faacf4a1a6ec1220d57d0cb2b977edb74f32cd58dc786361c6cf5
0N/ACOMPONENT_ARCHIVE_URL_2= $(COMPONENT_PROJECT_URL)download/$(COMPONENT_ARCHIVE_2)
0N/AUNPACK_ARGS_2= -r $(COMPONENT_SRC_2)
0N/APKG_PROTO_DIRS += $(COMPONENT_SRC_2)
0N/A
0N/ATPNO= 18548
0N/A
0N/ASYSTEM_TEST_TARGET= configure $(SYSTEM_TEST_64)
0N/Ainclude $(WS_MAKE_RULES)/common.mk
0N/A
0N/A# Fix 64-bit linking.
0N/ALDFLAGS += $(CC_BITS)
0N/A
0N/ACXXFLAGS += -std=c++11
0N/A
0N/ACONFIGURE_OPTIONS += --enable-smp-support
0N/ACONFIGURE_OPTIONS += --enable-threads
0N/A# The HiPE portion is a bit sensitive, and only seems to work 64-bit on
0N/A# amd64 (thus the variant.arch tagging in erlang.p5m). erts/config.log
0N/A# can be very interesting if issues occur.
0N/ACONFIGURE_OPTIONS += --enable-hipe
0N/ACONFIGURE_OPTIONS += --with-ssl
0N/ACONFIGURE_OPTIONS += --enable-dynamic-ssl-lib
0N/A
0N/A# Use cp(1) instead of cloney because erlang's 'install' target uses 'tar'
0N/A# to copy files and our tar doesn't handle long links by default. Between
0N/A# the use of 'tar' and 'ld', a path adjustment wasn't an option due to the
0N/A# need for /usr/bin/ld and /usr/gnu/bin/tar. This is still the case with
0N/A# erlang version 17.5.
0N/ACOMPONENT_PRE_CONFIGURE_ACTION = \
0N/A ($(CP) -rp $(SOURCE_DIR)/. $(@D))
0N/ACONFIGURE_SCRIPT = $(@D)/configure
0N/A
0N/A# We need to re-run the nested configure script for the wx sub-component so
0N/A# that it will properly detect wxWidgets support by adding -std=c++11 to $(CXX)
0N/A# (workaround for the configure script ignoring CXXFLAGS) and with ERL_TOP set
0N/A# so that the wx component knows we're building inside the erlang source tree.
0N/ACOMPONENT_POST_CONFIGURE_ACTION = \
0N/A (cd $(@D)/lib/wx; $(ENV) $(CONFIGURE_ENV) \
0N/A CXX="$(CXX) -std=c++11" \
0N/A ERL_TOP="$(@D)" \
0N/A $(CONFIG_SHELL) \
0N/A ./configure $(CONFIGURE_OPTIONS))
0N/A
0N/A# Always show the build and link lines for easier debugging.
0N/ACOMPONENT_BUILD_ARGS += V=1
0N/A
0N/ACOMPONENT_INSTALL_ARGS += INSTALL_PREFIX=$(PROTO_DIR)
0N/A
0N/ACOMPONENT_TEST_ENV += ERL_TOP=$(BUILD_DIR_64)
0N/ACOMPONENT_TEST_TARGETS = tests
0N/A
0N/A# Remove the two lines which contains the tester's username.
0N/ACOMPONENT_TEST_TRANSFORMS += \
0N/A '-e "s|/ldisk/tests|XXX_UID_XXX|g" ' \
0N/A '-e "/XXX_UID_XXX/d" '
0N/A
0N/ACOMPONENT_SYSTEM_TEST_ENV += ERL_TOP=$(BUILD_DIR_64)
0N/ACOMPONENT_SYSTEM_TEST_TARGETS = tests
0N/A
0N/A# remove INSTALL_PREFIX from path
0N/ACOMPONENT_POST_INSTALL_ACTION += \
0N/A $(PERL) -pi -e "s|$(PROTO_DIR)||g" \
0N/A $(PROTOUSRLIBDIR64)/erlang/bin/erl \
0N/A $(PROTOUSRLIBDIR64)/erlang/releases/RELEASES
0N/A
0N/AREQUIRED_PACKAGES += library/graphics/wxwidgets
0N/AREQUIRED_PACKAGES += library/ncurses
0N/AREQUIRED_PACKAGES += library/security/openssl
0N/AREQUIRED_PACKAGES += library/security/openssl/openssl-fips-140
0N/AREQUIRED_PACKAGES += library/zlib
0N/AREQUIRED_PACKAGES += shell/ksh93
0N/AREQUIRED_PACKAGES += system/core-os
0N/AREQUIRED_PACKAGES += system/library/gcc/gcc-c++-runtime
0N/AREQUIRED_PACKAGES += system/library/gcc/gcc-c-runtime
0N/AREQUIRED_PACKAGES += system/library/math
0N/AREQUIRED_PACKAGES += x11/library/mesa
0N/A