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#
5425N/A# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved.
346N/A#
3817N/A# Built in SFW with gcc and builds cleanly now only with gcc
5680N/ABUILD_BITS= 64
5680N/ACOMPILER= gcc
346N/Ainclude ../../make-rules/shared-macros.mk
346N/A
5680N/APATH=$(JAVA_HOME)/bin:$(USRBINDIR)
783N/A
1244N/ACOMPONENT_NAME= erlang
4162N/ACOMPONENT_VERSION= 17.5
618N/ACOMPONENT_PROJECT_URL= http://www.erlang.org/
1244N/ACOMPONENT_SRC_NAME= otp_src
1244N/ACOMPONENT_SRC= $(COMPONENT_SRC_NAME)_$(COMPONENT_VERSION)
844N/ACOMPONENT_ARCHIVE_HASH= \
4162N/A sha256:3c28820c981b30c50df8ac2a4a238e5813454fa3ed2ad530bc7948a282846474
618N/ACOMPONENT_ARCHIVE_URL= $(COMPONENT_PROJECT_URL)download/$(COMPONENT_ARCHIVE)
346N/A
346N/A# manpages
346N/ACOMPONENT_NAME_1= otp_doc_man
346N/ACOMPONENT_SRC_1= $(COMPONENT_NAME_1)_$(COMPONENT_VERSION)
4162N/ACOMPONENT_ARCHIVE_1= $(COMPONENT_SRC_1).tar.gz
844N/ACOMPONENT_ARCHIVE_HASH_1= \
4162N/A sha256:85b1b2a1011fc01af550f1fe9e5a599a4c5f2a35d264d2804af1d05590a857c3
618N/ACOMPONENT_ARCHIVE_URL_1= $(COMPONENT_PROJECT_URL)download/$(COMPONENT_ARCHIVE_1)
4194N/AUNPACK_ARGS_1= -r $(COMPONENT_SRC_1)
4194N/APKG_PROTO_DIRS += $(COMPONENT_SRC_1)
346N/A
346N/A# HTML documentation
346N/ACOMPONENT_NAME_2= otp_doc_html
346N/ACOMPONENT_SRC_2= $(COMPONENT_NAME_2)_$(COMPONENT_VERSION)
4162N/ACOMPONENT_ARCHIVE_2= $(COMPONENT_SRC_2).tar.gz
844N/ACOMPONENT_ARCHIVE_HASH_2= \
4162N/A sha256:baba1d373c1faacf4a1a6ec1220d57d0cb2b977edb74f32cd58dc786361c6cf5
618N/ACOMPONENT_ARCHIVE_URL_2= $(COMPONENT_PROJECT_URL)download/$(COMPONENT_ARCHIVE_2)
4194N/AUNPACK_ARGS_2= -r $(COMPONENT_SRC_2)
4194N/APKG_PROTO_DIRS += $(COMPONENT_SRC_2)
346N/A
3083N/ATPNO= 18548
3083N/A
5680N/ASYSTEM_TEST_TARGET= configure $(SYSTEM_TEST_64)
5680N/Ainclude $(WS_MAKE_RULES)/common.mk
346N/A
5680N/A# Fix 64-bit linking.
5680N/ALDFLAGS += $(CC_BITS)
5680N/A
6453N/ACXXFLAGS += -std=c++11
6453N/A
346N/ACONFIGURE_OPTIONS += --enable-smp-support
346N/ACONFIGURE_OPTIONS += --enable-threads
4162N/A# The HiPE portion is a bit sensitive, and only seems to work 64-bit on
1358N/A# amd64 (thus the variant.arch tagging in erlang.p5m). erts/config.log
4162N/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
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
4162N/A# need for /usr/bin/ld and /usr/gnu/bin/tar. This is still the case with
4162N/A# erlang version 17.5.
346N/ACOMPONENT_PRE_CONFIGURE_ACTION = \
351N/A ($(CP) -rp $(SOURCE_DIR)/. $(@D))
4162N/ACONFIGURE_SCRIPT = $(@D)/configure
4162N/A
6453N/A# We need to re-run the nested configure script for the wx sub-component so
6453N/A# that it will properly detect wxWidgets support by adding -std=c++11 to $(CXX)
6453N/A# (workaround for the configure script ignoring CXXFLAGS) and with ERL_TOP set
6453N/A# so that the wx component knows we're building inside the erlang source tree.
6453N/ACOMPONENT_POST_CONFIGURE_ACTION = \
6453N/A (cd $(@D)/lib/wx; $(ENV) $(CONFIGURE_ENV) \
6453N/A CXX="$(CXX) -std=c++11" \
6453N/A ERL_TOP="$(@D)" \
6453N/A $(CONFIG_SHELL) \
6453N/A ./configure $(CONFIGURE_OPTIONS))
6453N/A
4162N/A# Always show the build and link lines for easier debugging.
4162N/ACOMPONENT_BUILD_ARGS += V=1
346N/A
346N/ACOMPONENT_INSTALL_ARGS += INSTALL_PREFIX=$(PROTO_DIR)
346N/A
2497N/ACOMPONENT_TEST_ENV += ERL_TOP=$(BUILD_DIR_64)
2497N/ACOMPONENT_TEST_TARGETS = tests
2497N/A
3958N/A# Remove the two lines which contains the tester's username.
3958N/ACOMPONENT_TEST_TRANSFORMS += \
3958N/A '-e "s|/ldisk/tests|XXX_UID_XXX|g" ' \
3958N/A '-e "/XXX_UID_XXX/d" '
3958N/A
5680N/ACOMPONENT_SYSTEM_TEST_ENV += ERL_TOP=$(BUILD_DIR_64)
4760N/ACOMPONENT_SYSTEM_TEST_TARGETS = tests
4760N/A
5680N/A# remove INSTALL_PREFIX from path
5680N/ACOMPONENT_POST_INSTALL_ACTION += \
2497N/A $(PERL) -pi -e "s|$(PROTO_DIR)||g" \
5680N/A $(PROTOUSRLIBDIR64)/erlang/bin/erl \
5680N/A $(PROTOUSRLIBDIR64)/erlang/releases/RELEASES
4337N/A
6453N/AREQUIRED_PACKAGES += library/graphics/wxwidgets
3817N/AREQUIRED_PACKAGES += library/ncurses
3817N/AREQUIRED_PACKAGES += library/security/openssl
6453N/AREQUIRED_PACKAGES += library/security/openssl/openssl-fips-140
4162N/AREQUIRED_PACKAGES += library/zlib
3817N/AREQUIRED_PACKAGES += shell/ksh93
3817N/AREQUIRED_PACKAGES += system/core-os
6453N/AREQUIRED_PACKAGES += system/library/gcc/gcc-c++-runtime
6453N/AREQUIRED_PACKAGES += system/library/gcc/gcc-c-runtime
3817N/AREQUIRED_PACKAGES += system/library/math
6453N/AREQUIRED_PACKAGES += x11/library/mesa