aboutsummaryrefslogtreecommitdiffstats
path: root/testing/erlang
diff options
context:
space:
mode:
authorJohn Regan <john@jrjrtech.com>2015-02-19 10:31:56 -0500
committerLeonardo Arena <rnalrd@alpinelinux.org>2015-02-19 15:55:16 +0000
commitd619822e8905167b4a0b4e993d8c0e1c64aa445a (patch)
tree1e3029ad6905003f7e6bd4dddf24374485c926fb /testing/erlang
parentf8b1a52e683440dcb7e4b3222f33669a79805802 (diff)
downloadaports-d619822e8905167b4a0b4e993d8c0e1c64aa445a.tar.gz
aports-d619822e8905167b4a0b4e993d8c0e1c64aa445a.tar.bz2
aports-d619822e8905167b4a0b4e993d8c0e1c64aa445a.tar.xz
testing/erlang: updating to 17.4
Signed-off-by: Leonardo Arena <rnalrd@alpinelinux.org>
Diffstat (limited to 'testing/erlang')
-rw-r--r--testing/erlang/APKBUILD301
-rw-r--r--testing/erlang/otp-0001-Do-not-format-man-pages-and-do-not-install-miscellan.patch41
-rw-r--r--testing/erlang/otp-0002-Remove-rpath.patch32
-rw-r--r--testing/erlang/otp-0003-Do-not-install-C-sources.patch161
-rw-r--r--testing/erlang/otp-0004-Do-not-install-Java-sources.patch32
-rw-r--r--testing/erlang/otp-0005-Do-not-install-nteventlog-and-related-doc-files-on-n.patch61
-rw-r--r--testing/erlang/otp-0006-Do-not-install-erlang-sources.patch1006
-rw-r--r--testing/erlang/otp-0007-Split-off-webtool-dependency-from-tools.patch40
-rw-r--r--testing/erlang/otp-0008-Introduce-os-getenv-2.patch63
-rw-r--r--testing/erlang/otp-0009-Patch-removes-support-for-SSLv3-protocol-because-it-.patch100
-rw-r--r--testing/erlang/remove-private-unit32.patch11
-rw-r--r--testing/erlang/replace_glibc_check.patch20
12 files changed, 1868 insertions, 0 deletions
diff --git a/testing/erlang/APKBUILD b/testing/erlang/APKBUILD
new file mode 100644
index 0000000000..00238fa0c1
--- /dev/null
+++ b/testing/erlang/APKBUILD
@@ -0,0 +1,301 @@
+# Contributor: Michael Mason <ms13sp@gmail.com>
+# Maintainer: John Regan <john@jrjrtech.com>
+
+# TODO: create subpackages
+# Check how fedora does it:
+# http://pkgs.fedoraproject.org/gitweb/?p=erlang.git;a=blob;f=erlang.spec
+
+pkgname=erlang
+pkgver=17.4
+pkgrel=0
+pkgdesc="General-purpose programming language and runtime environment"
+url="http://www.erlang.org/"
+license="ERPL"
+arch="all"
+depends="$pkgname-kernel $pkgname-stdlib $pkgname-compiler"
+makedepends="perl-dev zlib-dev ncurses-dev openssl-dev openjdk7 unixodbc-dev"
+install=""
+subpackages="$pkgname-dev
+ $pkgname-asn1:asn
+ $pkgname-common-test:common_test
+ $pkgname-compiler:compiler
+ $pkgname-cosevent:cos_event
+ $pkgname-coseventdomain:cos_event_domain
+ $pkgname-cosfiletransfer:cos_file_transfer
+ $pkgname-cosproperty:cos_property
+ $pkgname-costime:cos_time
+ $pkgname-costransaction:cos_transactions
+ $pkgname-crypto:crypto
+ $pkgname-debugger:debugger
+ $pkgname-dialyzer:dialyzer
+ $pkgname-diameter:diameter
+ $pkgname-edoc:edoc
+ $pkgname-eldap:eldap
+ $pkgname-erl-docgen:erl_docgen
+ $pkgname-erl-interface:erl_interface
+ $pkgname-erts:erts
+ $pkgname-et:et
+ $pkgname-eunit:eunit
+ $pkgname-gs:gs
+ $pkgname-hipe:hipe
+ $pkgname-ic:ic
+ $pkgname-inets:inets
+ $pkgname-jinterface:jinterface
+ $pkgname-kernel:kernel
+ $pkgname-megaco:megaco
+ $pkgname-mnesia:mnesia
+ $pkgname-observer:observer
+ $pkgname-odbc:odbc
+ $pkgname-orber:orber
+ $pkgname-os-mon:os_mon
+ $pkgname-ose:ose
+ $pkgname-otp-mibs:otp_mibs
+ $pkgname-parsetools:parsetools
+ $pkgname-percept:percept
+ $pkgname-public-key:public_key
+ $pkgname-reltool:reltool
+ $pkgname-runtime-tools:runtime_tools
+ $pkgname-sasl:sasl
+ $pkgname-snmp:snmp
+ $pkgname-ssh:ssh
+ $pkgname-ssl:ssl
+ $pkgname-stdlib:stdlib
+ $pkgname-syntax-tools:syntax_tools
+ $pkgname-test-server:test_server
+ $pkgname-tools:tools
+ $pkgname-typer:typer
+ $pkgname-webtool:webtool
+ $pkgname-xmerl:xmerl"
+# Patches found: http://pkgs.fedoraproject.org/gitweb/?p=erlang.git;a=tree
+source="http://www.erlang.org/download/otp_src_$pkgver.tar.gz
+ otp-0001-Do-not-format-man-pages-and-do-not-install-miscellan.patch
+ otp-0002-Remove-rpath.patch
+ otp-0003-Do-not-install-C-sources.patch
+ otp-0004-Do-not-install-Java-sources.patch
+ otp-0005-Do-not-install-nteventlog-and-related-doc-files-on-n.patch
+ otp-0006-Do-not-install-erlang-sources.patch
+ otp-0007-Split-off-webtool-dependency-from-tools.patch
+ otp-0008-Introduce-os-getenv-2.patch
+ otp-0009-Patch-removes-support-for-SSLv3-protocol-because-it-.patch
+ remove-private-unit32.patch
+ replace_glibc_check.patch"
+
+_builddir="$srcdir"/otp_src_$pkgver
+
+# subpackage versions
+asn_ver="3.0.3"
+common_test_ver="1.9"
+compiler_ver="5.0.3"
+cos_event_ver="2.1.15"
+cos_event_domain_ver="1.1.14"
+cos_file_transfer_ver="1.1.16"
+cos_property_ver="1.1.17"
+cos_time_ver="1.1.14"
+cos_transactions_ver="1.2.14"
+crypto_ver="3.4.2"
+debugger_ver="4.0.2"
+dialyzer_ver="2.7.3"
+diameter_ver="1.8"
+edoc_ver="0.7.16"
+eldap_ver="1.1"
+erl_docgen_ver="0.3.7"
+erl_interface_ver="3.7.20"
+erts_ver="6.3"
+et_ver="1.5"
+eunit_ver="2.2.9"
+gs_ver="1.5.16"
+hipe_ver="3.11.2"
+ic_ver="4.3.6"
+inets_ver="5.10.4"
+jinterface_ver="1.5.12"
+kernel_ver="3.1"
+megaco_ver="3.17.3"
+mnesia_ver="4.12.4"
+observer_ver="2.0.3"
+odbc_ver="2.10.22"
+orber_ver="3.7.1"
+os_mon_ver="2.3"
+ose_ver="1.0.2"
+otp_mibs_ver="1.0.10"
+parsetools_ver="2.0.12"
+percept_ver="0.8.10"
+public_key_ver="0.22.1"
+reltool_ver="0.6.6"
+runtime_tools_ver="1.8.15"
+sasl_ver="2.4.1"
+snmp_ver="5.1.1"
+ssh_ver="3.1"
+ssl_ver="5.3.8"
+stdlib_ver="2.3"
+syntax_tools_ver="1.6.17"
+test_server_ver="3.7.2"
+tools_ver="2.7.1"
+typer_ver="0.9.8"
+webtool_ver="0.8.10"
+xmerl_ver="1.3.7"
+
+prepare() {
+ local i
+ cd "$_builddir"
+ for i in $source; do
+ case $i in
+ *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
+ esac
+ done
+}
+
+build() {
+ cd "$_builddir"
+ export CPPFLAGS="-D_BSD_SOURCE $CPPFLAGS"
+ export PATH="/usr/lib/jvm/java-1.7-openjdk/bin:$PATH"
+ ./configure --prefix=/usr \
+ --sysconfdir=/etc \
+ --mandir=/usr/share/man \
+ --infodir=/usr/share/info \
+ --host="$CHOST" \
+ --build="$CBUILD" \
+ --enable-threads \
+ --enable-shared-zlib \
+ --enable-ssl=dynamic-ssl-lib \
+ || return 1
+ make -j1 || return 1
+}
+
+package() {
+ cd "$_builddir"
+ make -j1 DESTDIR="$pkgdir" install || return 1
+ rm -rf "$pkgdir"/usr/lib/erlang/lib/wx-*
+}
+
+_mv_erlang_lib() {
+ local lib=$1
+ local ver=$2
+ depends="$pkgname"
+ pkgver=$ver
+
+ mkdir -p "$subpkgdir"/usr/lib/erlang/lib
+ mv "$pkgdir"/usr/lib/erlang/lib/$lib-$ver "$subpkgdir"/usr/lib/erlang/lib/
+}
+
+asn() { _mv_erlang_lib asn1 $asn_ver; }
+common_test() { _mv_erlang_lib common_test $common_test_ver; }
+compiler() { _mv_erlang_lib compiler $compiler_ver; }
+cos_event() { _mv_erlang_lib cosEvent $cos_event_ver; }
+cos_event_domain() { _mv_erlang_lib cosEventDomain $cos_event_domain_ver; }
+cos_file_transfer() { _mv_erlang_lib cosFileTransfer $cos_file_transfer_ver; }
+cos_property() { _mv_erlang_lib cosProperty $cos_property_ver; }
+cos_time() { _mv_erlang_lib cosTime $cos_time_ver; }
+cos_transactions() { _mv_erlang_lib cosTransactions $cos_transactions_ver; }
+crypto() { _mv_erlang_lib crypto $crypto_ver; }
+debugger() { _mv_erlang_lib debugger $debugger_ver; }
+dialyzer() { _mv_erlang_lib dialyzer $dialyzer_ver; }
+diameter() { _mv_erlang_lib diameter $diameter_ver; }
+edoc() { _mv_erlang_lib edoc $edoc_ver; }
+eldap() { _mv_erlang_lib eldap $eldap_ver; }
+erl_docgen() { _mv_erlang_lib erl_docgen $erl_docgen_ver; }
+erl_interface() { _mv_erlang_lib erl_interface $erl_interface_ver; }
+erts() { _mv_erlang_lib erts $erts_ver; }
+et() { _mv_erlang_lib et $et_ver; }
+eunit() { _mv_erlang_lib eunit $eunit_ver; }
+gs() { _mv_erlang_lib gs $gs_ver; }
+hipe() { _mv_erlang_lib hipe $hipe_ver; }
+ic() { _mv_erlang_lib ic $ic_ver; }
+inets() { _mv_erlang_lib inets $inets_ver; }
+jinterface() { _mv_erlang_lib jinterface $jinterface_ver; }
+kernel() { _mv_erlang_lib kernel $kernel_ver; }
+megaco() { _mv_erlang_lib megaco $megaco_ver; }
+mnesia() { _mv_erlang_lib mnesia $mnesia_ver; }
+observer() { _mv_erlang_lib observer $observer_ver; }
+odbc() { _mv_erlang_lib odbc $odbc_ver; }
+orber() { _mv_erlang_lib orber $orber_ver; }
+os_mon() { _mv_erlang_lib os_mon $os_mon_ver; }
+ose() { _mv_erlang_lib ose $ose_ver; }
+otp_mibs() { _mv_erlang_lib otp_mibs $otp_mibs_ver; }
+parsetools() { _mv_erlang_lib parsetools $parsetools_ver; }
+percept() { _mv_erlang_lib percept $percept_ver; }
+public_key() { _mv_erlang_lib public_key $public_key_ver; }
+reltool() { _mv_erlang_lib reltool $reltool_ver; }
+runtime_tools() { _mv_erlang_lib runtime_tools $runtime_tools_ver; }
+sasl() { _mv_erlang_lib sasl $sasl_ver; }
+snmp() { _mv_erlang_lib snmp $snmp_ver; }
+ssh() { _mv_erlang_lib ssh $ssh_ver; }
+ssl() { _mv_erlang_lib ssl $ssl_ver; }
+stdlib() { _mv_erlang_lib stdlib $stdlib_ver; }
+syntax_tools() { _mv_erlang_lib syntax_tools $syntax_tools_ver; }
+test_server() { _mv_erlang_lib test_server $test_server_ver; }
+tools() { _mv_erlang_lib tools $tools_ver; }
+typer() { _mv_erlang_lib typer $typer_ver; }
+webtool() { _mv_erlang_lib webtool $webtool_ver; }
+xmerl() { _mv_erlang_lib xmerl $xmerl_ver; }
+
+dev() {
+ local i= j=
+ depends="$pkgname=$pkgver-r$pkgrel $depends_dev"
+ pkgdesc="$pkgdesc (development files)"
+
+ cd "$pkgdir" || return 0
+ local libdirs=usr/
+ [ -d lib/ ] && libdirs="lib/ $libdirs"
+ for i in usr/include usr/lib/pkgconfig usr/share/aclocal\
+ usr/share/gettext usr/bin/*-config \
+ usr/share/vala/vapi usr/share/gir-[0-9]*\
+ usr/share/qt*/mkspecs \
+ usr/lib/qt*/mkspecs \
+ usr/lib/cmake \
+ $(find . -name include -type d) \
+ $(find $libdirs -name '*.[acho]' \
+ -o -name '*.prl' 2>/dev/null); do
+ if [ -e "$pkgdir/$i" ] || [ -L "$pkgdir/$i" ]; then
+ d="$subpkgdir/${i%/*}" # dirname $i
+ mkdir -p "$d"
+ mv "$pkgdir/$i" "$d"
+ rmdir "$pkgdir/${i%/*}" 2>/dev/null
+ fi
+ done
+ # move *.so links needed when linking the apps to -dev packages
+ for i in lib/*.so usr/lib/*.so; do
+ if [ -L "$i" ]; then
+ mkdir -p "$subpkgdir"/"${i%/*}"
+ mv "$i" "$subpkgdir/$i" || return 1
+ fi
+ done
+ return 0
+}
+
+
+md5sums="3d33c4c6bd7950240dcd7479edd9c7d8 otp_src_17.4.tar.gz
+5eb1ff3dd4ccf1a2a9e038ca599d535c otp-0001-Do-not-format-man-pages-and-do-not-install-miscellan.patch
+6202359c7326ad45da303dea5b865ed7 otp-0002-Remove-rpath.patch
+49e76b9d1356c432141cc9e472ece48f otp-0003-Do-not-install-C-sources.patch
+b16edcf58468e7f33da182ba622d9372 otp-0004-Do-not-install-Java-sources.patch
+3bd87bbf27b341b93d1f36025d2cea3c otp-0005-Do-not-install-nteventlog-and-related-doc-files-on-n.patch
+df2f5d70293bce953d94cb4ae76bb3a8 otp-0006-Do-not-install-erlang-sources.patch
+df323f3ed63e1112826ddc8012cae9d8 otp-0007-Split-off-webtool-dependency-from-tools.patch
+4689e0e5fd9040a86433d36e23020a6e otp-0008-Introduce-os-getenv-2.patch
+316027d711101e06258d0d85de30e3b0 otp-0009-Patch-removes-support-for-SSLv3-protocol-because-it-.patch
+20b48b781961fbff5dfc81df383c12e0 remove-private-unit32.patch
+06b7d939d3a18839d1c696998085c9c0 replace_glibc_check.patch"
+sha256sums="0d82eda6ae7ac6f0f860093324e540fa514497068ec3b4177800284e8c761f56 otp_src_17.4.tar.gz
+18b235111ab59e89f6257ffa2b6a0c48933fda3107c9a4e6f15b718d080c5f37 otp-0001-Do-not-format-man-pages-and-do-not-install-miscellan.patch
+f431800227050a8665c958ed9f21738adb7bbab5cbadb863eeb282f3da193a33 otp-0002-Remove-rpath.patch
+b4b2cfd436b9e75ea998784cce40492aa41512417321332e5b315361e80383d8 otp-0003-Do-not-install-C-sources.patch
+94380dab56a7687f6646b8e0b9e6433086ba36efd568ca41a7059312c3b9b5b1 otp-0004-Do-not-install-Java-sources.patch
+899dbbe6f4c8595720d995a951676303a45573d2a4fff46c77cbf1876281290b otp-0005-Do-not-install-nteventlog-and-related-doc-files-on-n.patch
+ff3600d52418ac5d70161955d6cebd2d6ce0fd93700afdc1834df29fc437a705 otp-0006-Do-not-install-erlang-sources.patch
+b15610e9cc879467e2387db1eef450827bc58bf4cbc9ffd5d40272ba6b76c8d2 otp-0007-Split-off-webtool-dependency-from-tools.patch
+0dca75b3fc682b03d3ed736100ef4589bd7fcc28af53325a1d36c46a2a56330e otp-0008-Introduce-os-getenv-2.patch
+450b48773c767b01ce78e91d4d54a74f9fa2d093729c82278c0defb14723529d otp-0009-Patch-removes-support-for-SSLv3-protocol-because-it-.patch
+c593c4715a31054031174fcc1a52d562440534e22762f7c19a76e0abedeef9c7 remove-private-unit32.patch
+37c762d495d252b69266b6ef59ae83d52ae9544c3a93845ca1f8225507f48249 replace_glibc_check.patch"
+sha512sums="a2626eea451a5e81027072d08eee158856deabd9fec9d648a736d6fcf0797f5009f8cd749dc3fb4f64d8af6f80d505e3709ea4e6cc0183ddbe365e88c27cc201 otp_src_17.4.tar.gz
+2fa0a9259432df4af3e10aacdbc8a782d11f86f4f06f6ff3299c698177744a26caaab248b8b00d89c99eb9a41ba9530037c5852dde73add58cb253e64de60258 otp-0001-Do-not-format-man-pages-and-do-not-install-miscellan.patch
+2111ce99ecc59e44d707b92d3f10b109e326f2e5f68d342c2b0e20089dcd43c45bae1eeda48f9a2d7e655696dd707fb99a6ca3936302813a0dfbdad098edc48d otp-0002-Remove-rpath.patch
+076cf7e08cfdf015170abfe936f62c98bbb9a743235eabfd29362b79c95f1bcdde7ddfb1c4a46503765e53a13b1aeaaa433ea4f51ca1721057bb90a8977a873b otp-0003-Do-not-install-C-sources.patch
+5a89290eaaf622192f7ef32e70f8a1301581afa5541902aa961c0c4431183d9822668daa1d48bfc2dee010ab747b0c1f4511525a243be42c8cff252bdd7906f7 otp-0004-Do-not-install-Java-sources.patch
+f799a25a319c0382f66e4079fb5486644900f4746c53c33d16a795a2d8d5a015853a978918c93a46cbdb23a90fd4fcefd840238e509b9500c74e2797e20971d2 otp-0005-Do-not-install-nteventlog-and-related-doc-files-on-n.patch
+ec0c06c8e219458f9fc624a98360a302d3facbb3f0ae4eaefabac04789d0019a493287956682d70f99d64134a7fe2dbaf86f74a28afdf2264d36893085260d88 otp-0006-Do-not-install-erlang-sources.patch
+de19924f6aa652a93481a16f89f6eff4181f76a776f8a3ebd0c9a5b2f6344b8d3d4c2bb6192a5ef542d2dd02095d9bb9a2f094c248c01446daeb5abed2d471fe otp-0007-Split-off-webtool-dependency-from-tools.patch
+52c3cadd0ee294c209dc031623c415334a1946b9f77ed1acfb7c9e9e1b1d2a0186b7996098ea53d0cdfb4fc3d0c4a53587af0df1887040c4aafa9aad4cb74488 otp-0008-Introduce-os-getenv-2.patch
+c4465ee5369d066a258e4cd06267a57150e8701f23530ce246bc8bb91d1a141f613f97a2a438a19b3e39aaab815f3e78eb64cf7f31d0404fb03b288db826a6d9 otp-0009-Patch-removes-support-for-SSLv3-protocol-because-it-.patch
+0f5b2899de78c5481b38250583a1ef8825aec2ac74eaecf35a6ad3d1165ba6422dca6206d349d5a6f61d7fdb26dac688c2dbe13632cf23b671913af674593764 remove-private-unit32.patch
+8dc50e4d89173142b6b795bf802c991a1442648f934f623c2a6ddd1ebd075d8dc30d0ec584584cd8f36e8d22e947b9a1062c70e79c14090530c7a1ad678b9eca replace_glibc_check.patch"
diff --git a/testing/erlang/otp-0001-Do-not-format-man-pages-and-do-not-install-miscellan.patch b/testing/erlang/otp-0001-Do-not-format-man-pages-and-do-not-install-miscellan.patch
new file mode 100644
index 0000000000..6aeadc8a4d
--- /dev/null
+++ b/testing/erlang/otp-0001-Do-not-format-man-pages-and-do-not-install-miscellan.patch
@@ -0,0 +1,41 @@
+From: Peter Lemenkov <lemenkov@gmail.com>
+Date: Thu, 25 Feb 2010 16:45:28 +0300
+Subject: [PATCH] Do not format man-pages and do not install miscellaneous
+ utilities for dealing with man-pages.
+
+Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
+
+diff --git a/erts/etc/common/Makefile.in b/erts/etc/common/Makefile.in
+index 0cf965f..94e82a8 100644
+--- a/erts/etc/common/Makefile.in
++++ b/erts/etc/common/Makefile.in
+@@ -550,10 +550,6 @@ endif
+ ifneq ($(INSTALL_TOP_BIN),)
+ $(INSTALL_PROGRAM) $(INSTALL_TOP_BIN) "$(RELEASE_PATH)"
+ endif
+-ifneq ($(INSTALL_MISC),)
+- $(INSTALL_DIR) "$(RELEASE_PATH)/misc"
+- $(INSTALL_SCRIPT) $(INSTALL_MISC) "$(RELEASE_PATH)/misc"
+-endif
+ ifneq ($(INSTALL_SRC),)
+ $(INSTALL_DIR) "$(RELEASE_PATH)/erts-$(VSN)/src"
+ $(INSTALL_DATA) $(INSTALL_SRC) "$(RELEASE_PATH)/erts-$(VSN)/src"
+diff --git a/erts/etc/unix/Install.src b/erts/etc/unix/Install.src
+index 8eb1db7..9e340bb 100644
+--- a/erts/etc/unix/Install.src
++++ b/erts/etc/unix/Install.src
+@@ -140,14 +140,5 @@ cp -p ../releases/%I_SYSTEM_VSN%/start_*.boot .
+ cp -p ../releases/%I_SYSTEM_VSN%/no_dot_erlang.boot .
+ cp -p $Name.boot start.boot
+ cp -p ../releases/%I_SYSTEM_VSN%/$Name.script start.script
+-#
+-# Fixing the man pages
+-#
+-
+-if [ -d "$ERL_ROOT/man" ]
+-then
+- cd "$ERL_ROOT"
+- ./misc/format_man_pages "$ERL_ROOT"
+-fi
+
+ exit 0
diff --git a/testing/erlang/otp-0002-Remove-rpath.patch b/testing/erlang/otp-0002-Remove-rpath.patch
new file mode 100644
index 0000000000..492734fe30
--- /dev/null
+++ b/testing/erlang/otp-0002-Remove-rpath.patch
@@ -0,0 +1,32 @@
+From: Peter Lemenkov <lemenkov@gmail.com>
+Date: Thu, 25 Feb 2010 16:57:43 +0300
+Subject: [PATCH] Remove rpath
+
+Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
+
+diff --git a/lib/crypto/c_src/Makefile.in b/lib/crypto/c_src/Makefile.in
+index 8c92b5b..5b36c19 100644
+--- a/lib/crypto/c_src/Makefile.in
++++ b/lib/crypto/c_src/Makefile.in
+@@ -89,7 +89,7 @@ endif
+ DYNAMIC_CRYPTO_LIB=@SSL_DYNAMIC_ONLY@
+
+ ifeq ($(DYNAMIC_CRYPTO_LIB),yes)
+-SSL_DED_LD_RUNTIME_LIBRARY_PATH = @SSL_DED_LD_RUNTIME_LIBRARY_PATH@
++SSL_DED_LD_RUNTIME_LIBRARY_PATH =
+ CRYPTO_LINK_LIB=$(SSL_DED_LD_RUNTIME_LIBRARY_PATH) -L$(SSL_LIBDIR) -l$(SSL_CRYPTO_LIBNAME)
+ EXTRA_FLAGS = -DHAVE_DYNAMIC_CRYPTO_LIB
+ else
+diff --git a/lib/crypto/priv/Makefile b/lib/crypto/priv/Makefile
+index 0989f14..0d29444 100644
+--- a/lib/crypto/priv/Makefile
++++ b/lib/crypto/priv/Makefile
+@@ -60,7 +60,7 @@ OBJS = $(OBJDIR)/crypto.o
+ # ----------------------------------------------------
+
+ $(SO_NIFLIB): $(OBJS)
+- $(SO_LD) $(SO_LDFLAGS) -L$(SO_SSL_LIBDIR) -Wl,-R$(SO_SSL_LIBDIR) \
++ $(SO_LD) $(SO_LDFLAGS) -L$(SO_SSL_LIBDIR) \
+ -o $@ $^ -lcrypto
+
+ $(DLL_NIFLIB): $(OBJS)
diff --git a/testing/erlang/otp-0003-Do-not-install-C-sources.patch b/testing/erlang/otp-0003-Do-not-install-C-sources.patch
new file mode 100644
index 0000000000..f89bcb79ff
--- /dev/null
+++ b/testing/erlang/otp-0003-Do-not-install-C-sources.patch
@@ -0,0 +1,161 @@
+From: Peter Lemenkov <lemenkov@gmail.com>
+Date: Fri, 18 Jun 2010 23:41:33 +0400
+Subject: [PATCH] Do not install C sources
+
+Don't install *.c and *.o files.
+
+Excepts ones from the internal erl_interface. These
+API headers are necessary. See rhbz #818419 for the
+explanation why they're necessary for the low-level
+interaction with the Erlang nodes:
+
+https://bugzilla.redhat.com/818419
+
+Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
+
+diff --git a/lib/asn1/c_src/Makefile b/lib/asn1/c_src/Makefile
+index a7cd03f..6da4d75 100644
+--- a/lib/asn1/c_src/Makefile
++++ b/lib/asn1/c_src/Makefile
+@@ -142,8 +142,6 @@ release_spec: opt
+ ifneq ($(findstring ose,$(TARGET)),ose)
+ $(INSTALL_PROGRAM) $(NIF_SHARED_OBJ_FILE) "$(RELSYSDIR)/priv/lib"
+ endif
+- $(INSTALL_DIR) "$(RELSYSDIR)/c_src"
+- $(INSTALL_DATA) *.c "$(RELSYSDIR)/c_src"
+
+ release_docs_spec:
+
+diff --git a/lib/crypto/c_src/Makefile.in b/lib/crypto/c_src/Makefile.in
+index 5b36c19..470821e 100644
+--- a/lib/crypto/c_src/Makefile.in
++++ b/lib/crypto/c_src/Makefile.in
+@@ -199,14 +199,10 @@ docs:
+ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+- $(INSTALL_DIR) "$(RELSYSDIR)/priv/obj"
+ $(INSTALL_DIR) "$(RELSYSDIR)/priv/lib"
+- $(INSTALL_DATA) $(NIF_MAKEFILE) "$(RELSYSDIR)/priv/obj"
+ ifneq ($(findstring ose,$(TARGET)),ose)
+- $(INSTALL_PROGRAM) $(CRYPTO_OBJS) "$(RELSYSDIR)/priv/obj"
+ $(INSTALL_PROGRAM) $(NIF_LIB) "$(RELSYSDIR)/priv/lib"
+ ifeq ($(DYNAMIC_CRYPTO_LIB),yes)
+- $(INSTALL_PROGRAM) $(CALLBACK_OBJS) "$(RELSYSDIR)/priv/obj"
+ $(INSTALL_PROGRAM) $(CALLBACK_LIB) "$(RELSYSDIR)/priv/lib"
+ endif
+ endif
+diff --git a/lib/erl_interface/src/Makefile.in b/lib/erl_interface/src/Makefile.in
+index 7c09b60..2c14f9e 100644
+--- a/lib/erl_interface/src/Makefile.in
++++ b/lib/erl_interface/src/Makefile.in
+@@ -904,14 +904,14 @@ ifneq ($(EXE_TARGETS),)
+ $(INSTALL_PROGRAM) $(EXE_TARGETS) "$(RELSYSDIR)/bin"
+ endif
+ $(INSTALL_DATA) $(EXTRA) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) connect/*.[ch] "$(RELSYSDIR)/src/connect"
+- $(INSTALL_DATA) decode/*.[ch] "$(RELSYSDIR)/src/decode"
+- $(INSTALL_DATA) encode/*.[ch] "$(RELSYSDIR)/src/encode"
+- $(INSTALL_DATA) epmd/*.[ch] "$(RELSYSDIR)/src/epmd"
+- $(INSTALL_DATA) misc/*.[ch] "$(RELSYSDIR)/src/misc"
+- $(INSTALL_DATA) registry/*.[ch] "$(RELSYSDIR)/src/registry"
+- $(INSTALL_DATA) legacy/*.[ch] "$(RELSYSDIR)/src/legacy"
+- $(INSTALL_DATA) prog/*.[ch] "$(RELSYSDIR)/src/prog"
++ $(INSTALL_DATA) connect/*.h "$(RELSYSDIR)/src/connect"
++ $(INSTALL_DATA) decode/*.h "$(RELSYSDIR)/src/decode"
++ $(INSTALL_DATA) encode/*.h "$(RELSYSDIR)/src/encode"
++ $(INSTALL_DATA) epmd/*.h "$(RELSYSDIR)/src/epmd"
++ $(INSTALL_DATA) misc/*.h "$(RELSYSDIR)/src/misc"
++ $(INSTALL_DATA) registry/*.h "$(RELSYSDIR)/src/registry"
++ $(INSTALL_DATA) legacy/*.h "$(RELSYSDIR)/src/legacy"
++ $(INSTALL_DATA) prog/*.h "$(RELSYSDIR)/src/prog"
+
+ release_docs:
+
+diff --git a/lib/ic/c_src/Makefile.in b/lib/ic/c_src/Makefile.in
+index ed860ab..96206ae 100644
+--- a/lib/ic/c_src/Makefile.in
++++ b/lib/ic/c_src/Makefile.in
+@@ -144,12 +144,10 @@ $(OBJDIR)/%.o: %.c
+ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+- $(INSTALL_DIR) "$(RELSYSDIR)/c_src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DIR) "$(RELSYSDIR)/priv/lib"
+ $(INSTALL_DIR) "$(RELEASE_PATH)/usr/include"
+ $(INSTALL_DIR) "$(RELEASE_PATH)/usr/lib"
+- $(INSTALL_DATA) ic.c ic_tmo.c "$(RELSYSDIR)/c_src"
+ $(INSTALL_DATA) $(IDL_FILES) $(H_FILES) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(LIBRARY) "$(RELSYSDIR)/priv/lib"
+ $(INSTALL_DATA) $(IDL_FILES) $(H_FILES) "$(RELEASE_PATH)/usr/include"
+diff --git a/lib/megaco/src/flex/Makefile.in b/lib/megaco/src/flex/Makefile.in
+index 6111cf2..bd62e8b 100644
+--- a/lib/megaco/src/flex/Makefile.in
++++ b/lib/megaco/src/flex/Makefile.in
+@@ -270,7 +270,7 @@ release_spec: opt
+ $(INSTALL_DATA) $(ERL_FILES) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src/flex"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+ ifeq ($(ENABLE_MEGACO_FLEX_SCANNER),true)
+- $(INSTALL_DATA) $(FLEX_FILES) $(C_TARGETS) "$(RELSYSDIR)/src/flex"
++ $(INSTALL_DATA) $(FLEX_FILES) "$(RELSYSDIR)/src/flex"
+ $(INSTALL_PROGRAM) $(SOLIBS) "$(RELSYSDIR)/priv/lib"
+ endif
+
+diff --git a/lib/odbc/c_src/Makefile.in b/lib/odbc/c_src/Makefile.in
+index 6572d28..c7093ae 100644
+--- a/lib/odbc/c_src/Makefile.in
++++ b/lib/odbc/c_src/Makefile.in
+@@ -128,11 +128,8 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ ifdef EXE_TARGET
+- $(INSTALL_DIR) "$(RELSYSDIR)/c_src"
+- $(INSTALL_DATA) $(C_FILES) $(H_FILES) "$(RELSYSDIR)/c_src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/priv"
+ $(INSTALL_DIR) "$(RELSYSDIR)/priv/bin"
+- $(INSTALL_DIR) "$(RELSYSDIR)/priv/obj"
+ $(INSTALL_PROGRAM) $(EXE_TARGET) "$(RELSYSDIR)/priv/bin"
+ endif
+
+diff --git a/lib/os_mon/c_src/Makefile.in b/lib/os_mon/c_src/Makefile.in
+index f84ccf7..05d194f 100644
+--- a/lib/os_mon/c_src/Makefile.in
++++ b/lib/os_mon/c_src/Makefile.in
+@@ -125,8 +125,6 @@ $(OBJDIR)/memsup.o: memsup.h
+ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+- $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(C_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/priv/bin"
+ $(INSTALL_PROGRAM) $(TARGET_FILES) "$(RELSYSDIR)/priv/bin"
+
+diff --git a/lib/runtime_tools/c_src/Makefile.in b/lib/runtime_tools/c_src/Makefile.in
+index d46b499..4309aae 100644
+--- a/lib/runtime_tools/c_src/Makefile.in
++++ b/lib/runtime_tools/c_src/Makefile.in
+@@ -156,10 +156,8 @@ docs:
+ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+- $(INSTALL_DIR) "$(RELSYSDIR)/priv/obj"
+ $(INSTALL_DIR) "$(RELSYSDIR)/priv/lib"
+ ifneq ($(findstring ose,$(TARGET)),ose)
+- $(INSTALL_PROGRAM) $(DYNTRACE_OBJS) "$(RELSYSDIR)/priv/obj"
+ $(INSTALL_PROGRAM) $(NIF_LIB) $(SOLIBS) "$(RELSYSDIR)/priv/lib"
+ endif
+
+diff --git a/lib/tools/c_src/Makefile.in b/lib/tools/c_src/Makefile.in
+index b1eb69f..1acfdbf 100644
+--- a/lib/tools/c_src/Makefile.in
++++ b/lib/tools/c_src/Makefile.in
+@@ -197,8 +197,6 @@ include ../vsn.mk
+ RELSYSDIR = $(RELEASE_PATH)/lib/tools-$(TOOLS_VSN)
+
+ release_spec: all
+- $(INSTALL_DIR) "$(RELSYSDIR)/c_src"
+- $(INSTALL_DATA) $(EMEM_SRCS) $(EMEM_HEADERS) "$(RELSYSDIR)/c_src"
+ ifneq ($(PROGS),)
+ $(INSTALL_DIR) "$(RELSYSDIR)/bin"
+ $(INSTALL_PROGRAM) $(PROGS) "$(RELSYSDIR)/bin"
diff --git a/testing/erlang/otp-0004-Do-not-install-Java-sources.patch b/testing/erlang/otp-0004-Do-not-install-Java-sources.patch
new file mode 100644
index 0000000000..65323fa79d
--- /dev/null
+++ b/testing/erlang/otp-0004-Do-not-install-Java-sources.patch
@@ -0,0 +1,32 @@
+From: Peter Lemenkov <lemenkov@gmail.com>
+Date: Sat, 19 Jun 2010 09:25:18 +0400
+Subject: [PATCH] Do not install Java sources
+
+Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
+
+diff --git a/lib/ic/java_src/com/ericsson/otp/ic/Makefile b/lib/ic/java_src/com/ericsson/otp/ic/Makefile
+index 273614e..5b1fb57 100644
+--- a/lib/ic/java_src/com/ericsson/otp/ic/Makefile
++++ b/lib/ic/java_src/com/ericsson/otp/ic/Makefile
+@@ -112,8 +112,6 @@ docs:
+ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+- $(INSTALL_DIR) "$(RELSYSDIR)/java_src/com/ericsson/otp/ic"
+- $(INSTALL_DATA) $(JAVA_FILES) "$(RELSYSDIR)/java_src/com/ericsson/otp/ic"
+ $(INSTALL_DIR) "$(RELSYSDIR)/priv"
+ $(INSTALL_DATA) $(JAVA_DEST_ROOT)$(JARFILE) "$(RELSYSDIR)/priv"
+
+diff --git a/lib/jinterface/java_src/com/ericsson/otp/erlang/Makefile b/lib/jinterface/java_src/com/ericsson/otp/erlang/Makefile
+index ea3ab77..e95757e 100644
+--- a/lib/jinterface/java_src/com/ericsson/otp/erlang/Makefile
++++ b/lib/jinterface/java_src/com/ericsson/otp/erlang/Makefile
+@@ -119,8 +119,6 @@ release release_docs release_tests release_html:
+ $(V_at)$(MAKE) $(MFLAGS) RELEASE_PATH="$(RELEASE_PATH)" $(TARGET_MAKEFILE) $@_spec
+
+ release_spec: opt
+- $(V_at)$(INSTALL_DIR) "$(RELSYSDIR)/java_src/com/ericsson/otp/erlang"
+- $(V_at)$(INSTALL_DATA) $(JAVA_SRC) "$(RELSYSDIR)/java_src/com/ericsson/otp/erlang"
+ $(V_at)$(INSTALL_DIR) "$(RELSYSDIR)/priv"
+ $(V_at)$(INSTALL_DATA) $(JAVA_DEST_ROOT)$(JARFILE) "$(RELSYSDIR)/priv"
+ $(V_at)$(INSTALL_DIR) "$(RELSYSDIR)/ebin"
diff --git a/testing/erlang/otp-0005-Do-not-install-nteventlog-and-related-doc-files-on-n.patch b/testing/erlang/otp-0005-Do-not-install-nteventlog-and-related-doc-files-on-n.patch
new file mode 100644
index 0000000000..cf8e970cba
--- /dev/null
+++ b/testing/erlang/otp-0005-Do-not-install-nteventlog-and-related-doc-files-on-n.patch
@@ -0,0 +1,61 @@
+From: Peter Lemenkov <lemenkov@gmail.com>
+Date: Sat, 19 Jun 2010 09:59:39 +0400
+Subject: [PATCH] Do not install nteventlog and related doc-files on non-win32
+ systems
+
+Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
+
+diff --git a/lib/os_mon/doc/src/Makefile b/lib/os_mon/doc/src/Makefile
+index 08fd23e..5606cfc 100644
+--- a/lib/os_mon/doc/src/Makefile
++++ b/lib/os_mon/doc/src/Makefile
+@@ -35,12 +35,17 @@ RELSYSDIR = $(RELEASE_PATH)/lib/$(APPLICATION)-$(VSN)
+ # Target Specs
+ # ----------------------------------------------------
+ XML_APPLICATION_FILES = ref_man.xml
++ifeq ($(findstring win32,$(TARGET)),win32)
++NTEVENTLOG_DOCFILE=nteventlog.xml
++else
++NTEVENTLOG_DOCFILE=
++endif
+ XML_REF3_FILES = cpu_sup.xml \
+ disksup.xml \
+ memsup.xml \
+ os_mon_mib.xml \
+ os_sup.xml \
+- nteventlog.xml
++ $(NTEVENTLOG_DOCFILE)
+
+ XML_REF6_FILES = os_mon_app.xml
+
+diff --git a/lib/os_mon/src/Makefile b/lib/os_mon/src/Makefile
+index cd2dade..4e78cf8 100644
+--- a/lib/os_mon/src/Makefile
++++ b/lib/os_mon/src/Makefile
+@@ -33,8 +33,13 @@ RELSYSDIR = $(RELEASE_PATH)/lib/os_mon-$(VSN)
+ # ----------------------------------------------------
+ # Target Specs
+ # ----------------------------------------------------
++ifeq ($(findstring win32,$(TARGET)),win32)
++NTEVENTLOG=nteventlog
++else
++NTEVENTLOG=
++endif
+ MODULES= disksup memsup cpu_sup os_mon os_mon_mib os_sup os_mon_sysinfo \
+- nteventlog
++ $(NTEVENTLOG)
+
+ INCLUDE=../include
+ CSRC=../c_src
+@@ -78,7 +83,11 @@ docs:
+ # ----------------------------------------------------
+
+ $(APP_TARGET): $(APP_SRC) ../vsn.mk
++ifeq ($(findstring win32,$(TARGET)),win32)
+ $(vsn_verbose)sed -e 's;%VSN%;$(VSN);' $< > $@
++else
++ $(vsn_verbose)sed -e 's;%VSN%;$(VSN);;s;,\s*nteventlog;;' $< > $@
++endif
+
+ $(APPUP_TARGET): $(APPUP_SRC) ../vsn.mk
+ $(vsn_verbose)sed -e 's;%VSN%;$(VSN);' $< > $@
diff --git a/testing/erlang/otp-0006-Do-not-install-erlang-sources.patch b/testing/erlang/otp-0006-Do-not-install-erlang-sources.patch
new file mode 100644
index 0000000000..9e0e3a9aba
--- /dev/null
+++ b/testing/erlang/otp-0006-Do-not-install-erlang-sources.patch
@@ -0,0 +1,1006 @@
+From: Hans Ulrich Niedermann <hun@n-dimensional.de>
+Date: Mon, 21 Mar 2011 15:41:49 +0100
+Subject: [PATCH] Do not install erlang sources
+
+Don't install *.erl, *.xrl, *.yrl, and *.asn1 files at all.
+
+Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
+Signed-off-by: Hans Ulrich Niedermann <hun@n-dimensional.de>
+
+diff --git a/erts/preloaded/src/Makefile b/erts/preloaded/src/Makefile
+index 4ea2d41..e1466c1 100644
+--- a/erts/preloaded/src/Makefile
++++ b/erts/preloaded/src/Makefile
+@@ -85,8 +85,6 @@ $(APP_TARGET): $(APP_SRC) $(ERL_TOP)/erts/vsn.mk
+ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: $(APP_TARGET)
+- $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(BEAM_FILES) $(STUBS_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(STATIC_TARGET_FILES) $(APP_TARGET) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/asn1/src/Makefile b/lib/asn1/src/Makefile
+index 6798da0..4e3ae0e 100644
+--- a/lib/asn1/src/Makefile
++++ b/lib/asn1/src/Makefile
+@@ -154,7 +154,7 @@ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(APP_TARGET) $(APPUP_TARGET) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) $(APP_SRC) $(APPUP_SRC) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/examples"
+ $(INSTALL_DATA) $(EXAMPLES) "$(RELSYSDIR)/examples"
+
+diff --git a/lib/common_test/src/Makefile b/lib/common_test/src/Makefile
+index 8d74546..a25d85d 100644
+--- a/lib/common_test/src/Makefile
++++ b/lib/common_test/src/Makefile
+@@ -140,7 +140,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+diff --git a/lib/compiler/src/Makefile b/lib/compiler/src/Makefile
+index c6d09d8..46dcdf4 100644
+--- a/lib/compiler/src/Makefile
++++ b/lib/compiler/src/Makefile
+@@ -165,8 +165,8 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) $(EXTRA_FILES) \
+- $(YRL_FILE) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(HRL_FILES) $(EXTRA_FILES) \
++ "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(INSTALL_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/cosEvent/src/Makefile b/lib/cosEvent/src/Makefile
+index 2864ee0..0e27bb6 100644
+--- a/lib/cosEvent/src/Makefile
++++ b/lib/cosEvent/src/Makefile
+@@ -202,7 +202,7 @@ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(APP_TARGET) $(APPUP_TARGET) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) $(GEN_ERL_FILES) $(IDL_FILES) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(HRL_FILES) $(IDL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(GEN_HRL_FILES) "$(RELSYSDIR)/include"
+
+diff --git a/lib/cosEventDomain/src/Makefile b/lib/cosEventDomain/src/Makefile
+index b4b74bd..420f566 100644
+--- a/lib/cosEventDomain/src/Makefile
++++ b/lib/cosEventDomain/src/Makefile
+@@ -171,7 +171,7 @@ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(APP_TARGET) $(APPUP_TARGET) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) $(GEN_ERL_FILES) $(IDL_FILES) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(HRL_FILES) $(IDL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(EXTERNAL_GEN_HRL_FILES) "$(RELSYSDIR)/include"
+
+diff --git a/lib/cosFileTransfer/src/Makefile b/lib/cosFileTransfer/src/Makefile
+index 9d3abb9..c3d83a5 100644
+--- a/lib/cosFileTransfer/src/Makefile
++++ b/lib/cosFileTransfer/src/Makefile
+@@ -179,9 +179,7 @@ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(APP_TARGET) $(APPUP_TARGET) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(GEN_FILES) $(IDL_FILES) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) $(GEN_ERL_FILES) $(IDL_FILES) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(HRL_FILES) $(GEN_HRL_FILES) $(IDL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+- $(INSTALL_DATA) $(GEN_HRL_FILES) "$(RELSYSDIR)/include"
+
+ release_docs_spec:
+diff --git a/lib/cosNotification/src/Makefile b/lib/cosNotification/src/Makefile
+index 13153bd..0860700 100644
+--- a/lib/cosNotification/src/Makefile
++++ b/lib/cosNotification/src/Makefile
+@@ -370,8 +370,7 @@ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(APP_TARGET) $(APPUP_TARGET) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(GEN_FILES) $(IDL_FILES) $(YECC_FILES) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) $(IDL_FILES) $(YECC_FILES) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(GEN_HRL_FILES) $(HRL_FILES) $(IDL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(GEN_HRL_FILES) "$(RELSYSDIR)/include"
+
+diff --git a/lib/cosProperty/src/Makefile b/lib/cosProperty/src/Makefile
+index d7b75d8..fba8746 100644
+--- a/lib/cosProperty/src/Makefile
++++ b/lib/cosProperty/src/Makefile
+@@ -179,8 +179,7 @@ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(APP_TARGET) $(APPUP_TARGET) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(GEN_FILES) $(IDL_FILES) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) $(GEN_ERL_FILES) $(IDL_FILES) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(GEN_HRL_FILES) $(HRL_FILES) $(IDL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(GEN_HRL_FILES) "$(RELSYSDIR)/include"
+
+diff --git a/lib/cosTime/src/Makefile b/lib/cosTime/src/Makefile
+index 0ab2b41..c29caeb 100644
+--- a/lib/cosTime/src/Makefile
++++ b/lib/cosTime/src/Makefile
+@@ -198,8 +198,7 @@ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(APP_TARGET) $(APPUP_TARGET) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(GEN_FILES) $(IDL_FILES) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) $(GEN_ERL_FILES) $(IDL_FILES) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(GEN_HRL_FILES) $(HRL_FILES) $(IDL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(GEN_HRL_FILES) "$(RELSYSDIR)/include"
+
+diff --git a/lib/cosTransactions/src/Makefile b/lib/cosTransactions/src/Makefile
+index 7b4a9cf..290707c 100644
+--- a/lib/cosTransactions/src/Makefile
++++ b/lib/cosTransactions/src/Makefile
+@@ -173,7 +173,7 @@ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(APP_TARGET) $(APPUP_TARGET) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) $(GEN_ERL_FILES) $(IDL_FILE) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(HRL_FILES) $(IDL_FILE) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(EXTERNAL_GEN_HRL_FILES) "$(RELSYSDIR)/include"
+
+diff --git a/lib/crypto/src/Makefile b/lib/crypto/src/Makefile
+index c185c15..68bacba 100644
+--- a/lib/crypto/src/Makefile
++++ b/lib/crypto/src/Makefile
+@@ -81,8 +81,6 @@ docs:
+ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+- $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(APP_TARGET) \
+ $(APPUP_TARGET) "$(RELSYSDIR)/ebin"
+diff --git a/lib/debugger/src/Makefile b/lib/debugger/src/Makefile
+index d61519f..bfdb0c9 100644
+--- a/lib/debugger/src/Makefile
++++ b/lib/debugger/src/Makefile
+@@ -116,7 +116,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(INTERNAL_HRL_FILES) $(TOOLBOX_FILES) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) $(TOOLBOX_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(TARGET_TOOLBOX_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/dialyzer/src/Makefile b/lib/dialyzer/src/Makefile
+index 91fbdca..01fb30c 100644
+--- a/lib/dialyzer/src/Makefile
++++ b/lib/dialyzer/src/Makefile
+@@ -151,7 +151,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) $(EXTRA_FILES) \
++ $(INSTALL_DATA) $(HRL_FILES) $(EXTRA_FILES) \
+ "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(INSTALL_FILES) "$(RELSYSDIR)/ebin"
+diff --git a/lib/diameter/src/Makefile b/lib/diameter/src/Makefile
+index 9afccf2..107d65b 100644
+--- a/lib/diameter/src/Makefile
++++ b/lib/diameter/src/Makefile
+@@ -250,11 +250,8 @@ release_spec: opt
+ $(MAKE) $(EXAMPLE_DIRS:%/=release_examples_%)
+
+ $(TARGET_DIRS:%/=release_src_%): release_src_%:
+- $(INSTALL_DIR) "$(RELSYSDIR)/src/$*"
+- $(INSTALL_DATA) $(filter $*/%, $(TARGET_MODULES:%=%.erl) \
+- $(INTERNAL_HRLS)) \
+- $(filter $*/%, compiler/$(DICT_YRL).yrl) \
+- "$(RELSYSDIR)/src/$*"
++ $(INSTALL_DATA) $(filter $*/%, $(INTERNAL_HRLS)) \
++ "$(RELSYSDIR)/src/$*" || true
+
+ $(EXAMPLE_DIRS:%/=release_examples_%): release_examples_%:
+ $(INSTALL_DIR) "$(RELSYSDIR)/examples/$*"
+diff --git a/lib/edoc/src/Makefile b/lib/edoc/src/Makefile
+index 4e5a418..c0bb0c3 100644
+--- a/lib/edoc/src/Makefile
++++ b/lib/edoc/src/Makefile
+@@ -88,7 +88,7 @@ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(OBJECTS) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(SOURCES) $(HRL_FILES) $(YRL_FILE) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src"
+
+ release_docs_spec:
+
+diff --git a/lib/eldap/src/Makefile b/lib/eldap/src/Makefile
+index 2e1110e..b7f9b09 100644
+--- a/lib/eldap/src/Makefile
++++ b/lib/eldap/src/Makefile
+@@ -98,10 +98,6 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(APP_TARGET) $(APPUP_TARGET) "$(RELSYSDIR)/ebin"
+- $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) "$(RELSYSDIR)/src"
+- $(INSTALL_DIR) "$(RELSYSDIR)/asn1"
+- $(INSTALL_DATA) ../asn1/$(ASN1_FILES) "$(RELSYSDIR)/asn1"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(EXTERNAL_HRL_FILES) "$(RELSYSDIR)/include"
+
+diff --git a/lib/erl_docgen/src/Makefile b/lib/erl_docgen/src/Makefile
+index ef96f5d..d9a2f0d 100644
+--- a/lib/erl_docgen/src/Makefile
++++ b/lib/erl_docgen/src/Makefile
+@@ -89,8 +89,6 @@ $(APPUP_TARGET): $(APPUP_SRC) ../vsn.mk
+ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+- $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/et/src/Makefile b/lib/et/src/Makefile
+index 377e593..668e278 100644
+--- a/lib/et/src/Makefile
++++ b/lib/et/src/Makefile
+@@ -108,7 +108,6 @@ release_spec: opt
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(APP_TARGET) $(APPUP_TARGET) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/include"
+diff --git a/lib/eunit/src/Makefile b/lib/eunit/src/Makefile
+index 47aef10..78ddc74 100644
+--- a/lib/eunit/src/Makefile
++++ b/lib/eunit/src/Makefile
+@@ -120,7 +120,6 @@ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(PARSE_TRANSFORM_BIN) $(OBJECTS) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(PARSE_TRANSFORM) $(SOURCES) "$(RELSYSDIR)/src"
+ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(INCLUDE_DELIVERABLES) "$(RELSYSDIR)/include"
+diff --git a/lib/gs/src/Makefile b/lib/gs/src/Makefile
+index f0200ca..86d3f74 100644
+--- a/lib/gs/src/Makefile
++++ b/lib/gs/src/Makefile
+@@ -108,8 +108,8 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(APP_SRC) $(ERL_FILES) $(HRL_FILES) $(GEN_HRL_FILES) \
+- $(GSTK_GENERIC) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(HRL_FILES) $(GEN_HRL_FILES) \
++ "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/priv/bitmap"
+diff --git a/lib/hipe/cerl/Makefile b/lib/hipe/cerl/Makefile
+index d13dfb3..b09d62b 100644
+--- a/lib/hipe/cerl/Makefile
++++ b/lib/hipe/cerl/Makefile
+@@ -101,7 +101,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/cerl"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) "$(RELSYSDIR)/cerl"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/cerl"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/hipe/flow/Makefile b/lib/hipe/flow/Makefile
+index 75e156b..5e394ca 100644
+--- a/lib/hipe/flow/Makefile
++++ b/lib/hipe/flow/Makefile
+@@ -101,7 +101,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/flow"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) $(INC_FILES) "$(RELSYSDIR)/flow"
++ $(INSTALL_DATA) $(HRL_FILES) $(INC_FILES) "$(RELSYSDIR)/flow"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/hipe/icode/Makefile b/lib/hipe/icode/Makefile
+index 87015aa..84f870d 100644
+--- a/lib/hipe/icode/Makefile
++++ b/lib/hipe/icode/Makefile
+@@ -119,7 +119,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/icode"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) "$(RELSYSDIR)/icode"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/icode"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/hipe/llvm/Makefile b/lib/hipe/llvm/Makefile
+index 92f3789..82f3e77 100644
+--- a/lib/hipe/llvm/Makefile
++++ b/lib/hipe/llvm/Makefile
+@@ -102,7 +102,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) $(RELSYSDIR)/llvm
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) $(RELSYSDIR)/llvm
++ $(INSTALL_DATA) $(HRL_FILES) $(RELSYSDIR)/llvm
+ $(INSTALL_DIR) $(RELSYSDIR)/ebin
+ $(INSTALL_DATA) $(TARGET_FILES) $(RELSYSDIR)/ebin
+
+diff --git a/lib/hipe/main/Makefile b/lib/hipe/main/Makefile
+index 66e4c3e..2f11670 100644
+--- a/lib/hipe/main/Makefile
++++ b/lib/hipe/main/Makefile
+@@ -117,7 +117,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+ release_spec: opt
+ $(INSTALL_DATA) ../vsn.mk "$(RELSYSDIR)"
+ $(INSTALL_DIR) "$(RELSYSDIR)/main"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) "$(RELSYSDIR)/main"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/main"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/hipe/misc/Makefile b/lib/hipe/misc/Makefile
+index 16166f5..0ba5845 100644
+--- a/lib/hipe/misc/Makefile
++++ b/lib/hipe/misc/Makefile
+@@ -101,7 +101,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/misc"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) "$(RELSYSDIR)/misc"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/misc"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/hipe/rtl/Makefile b/lib/hipe/rtl/Makefile
+index 751e876..98b7911 100644
+--- a/lib/hipe/rtl/Makefile
++++ b/lib/hipe/rtl/Makefile
+@@ -104,7 +104,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/rtl"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) "$(RELSYSDIR)/rtl"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/rtl"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/hipe/util/Makefile b/lib/hipe/util/Makefile
+index a5ee232..f03e41d 100644
+--- a/lib/hipe/util/Makefile
++++ b/lib/hipe/util/Makefile
+@@ -49,7 +49,6 @@ HIPE_MODULES =
+ endif
+ MODULES = hipe_timing hipe_dot hipe_digraph $(HIPE_MODULES)
+
+-HRL_FILES=
+ ERL_FILES= $(MODULES:%=%.erl)
+ TARGET_FILES= $(MODULES:%=$(EBIN)/%.$(EMULATOR))
+ DOC_FILES= $(MODULES:%=$(DOCS)/%.html)
+@@ -103,8 +102,6 @@ $(DOCS)/%.html:%.erl
+ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+- $(INSTALL_DIR) "$(RELSYSDIR)/util"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) "$(RELSYSDIR)/util"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/ic/src/Makefile b/lib/ic/src/Makefile
+index e8769d2..965d0e7 100644
+--- a/lib/ic/src/Makefile
++++ b/lib/ic/src/Makefile
+@@ -199,7 +199,7 @@ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(APP_TARGET) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(YRL_FILE) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/examples"
+ $(INSTALL_DIR) "$(RELSYSDIR)/examples/c-client"
+ $(INSTALL_DATA) $(CCL_EX_FILES) "$(RELSYSDIR)/examples/c-client"
+diff --git a/lib/inets/src/ftp/Makefile b/lib/inets/src/ftp/Makefile
+index 2c3d2b6..de0450e 100644
+--- a/lib/inets/src/ftp/Makefile
++++ b/lib/inets/src/ftp/Makefile
+@@ -90,7 +90,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/ftp"
+- $(INSTALL_DATA) $(HRL_FILES) $(ERL_FILES) "$(RELSYSDIR)/src/ftp"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src/ftp"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/inets/src/http_client/Makefile b/lib/inets/src/http_client/Makefile
+index f0d4ce1..35c4ffc 100644
+--- a/lib/inets/src/http_client/Makefile
++++ b/lib/inets/src/http_client/Makefile
+@@ -91,7 +91,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/http_client"
+- $(INSTALL_DATA) $(HRL_FILES) $(ERL_FILES) "$(RELSYSDIR)/src/http_client"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src/http_client"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/inets/src/http_lib/Makefile b/lib/inets/src/http_lib/Makefile
+index 51167b3..a623824 100644
+--- a/lib/inets/src/http_lib/Makefile
++++ b/lib/inets/src/http_lib/Makefile
+@@ -89,7 +89,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/http_lib"
+- $(INSTALL_DATA) $(HRL_FILES) $(ERL_FILES) "$(RELSYSDIR)/src/http_lib"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src/http_lib"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/inets/src/http_server/Makefile b/lib/inets/src/http_server/Makefile
+index 2660d04..c873a27 100644
+--- a/lib/inets/src/http_server/Makefile
++++ b/lib/inets/src/http_server/Makefile
+@@ -126,7 +126,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/http_server"
+- $(INSTALL_DATA) $(HRL_FILES) $(ERL_FILES) "$(RELSYSDIR)/src/http_server"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src/http_server"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/inets/src/inets_app/Makefile b/lib/inets/src/inets_app/Makefile
+index 22426ee..0b0cfb8 100644
+--- a/lib/inets/src/inets_app/Makefile
++++ b/lib/inets/src/inets_app/Makefile
+@@ -113,7 +113,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/inets_app"
+- $(INSTALL_DATA) $(INTERNAL_HRL_FILES) $(ERL_FILES) "$(RELSYSDIR)/src/inets_app"
++ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src/inets_app"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(EXTERNAL_HRL_FILES) "$(RELSYSDIR)/include"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+diff --git a/lib/inets/src/tftp/Makefile b/lib/inets/src/tftp/Makefile
+index b368b12..5eddaf0 100644
+--- a/lib/inets/src/tftp/Makefile
++++ b/lib/inets/src/tftp/Makefile
+@@ -95,7 +95,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/tftp"
+- $(INSTALL_DATA) $(HRL_FILES) $(ERL_FILES) "$(RELSYSDIR)/src/tftp"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src/tftp"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(BEHAVIOUR_TARGET_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/kernel/src/Makefile b/lib/kernel/src/Makefile
+index c7c70ad..3e1792f 100644
+--- a/lib/kernel/src/Makefile
++++ b/lib/kernel/src/Makefile
+@@ -199,7 +199,6 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/include"
+diff --git a/lib/megaco/src/app/Makefile b/lib/megaco/src/app/Makefile
+index d18da53..4a9f4d2 100644
+--- a/lib/megaco/src/app/Makefile
++++ b/lib/megaco/src/app/Makefile
+@@ -113,7 +113,7 @@ release_spec: opt
+ $(INSTALL_DATA) $(APP_TARGET) $(APPUP_TARGET) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/app"
+- $(INSTALL_DATA) $(ERL_FILES) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src/app"
++ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src/app"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(EXTERNAL_HRL_FILES) "$(RELSYSDIR)/include"
+
+diff --git a/lib/megaco/src/binary/Makefile b/lib/megaco/src/binary/Makefile
+index c1fd66b..0699ffa 100644
+--- a/lib/megaco/src/binary/Makefile
++++ b/lib/megaco/src/binary/Makefile
+@@ -175,7 +175,7 @@ release_spec: opt
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/binary"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) $(ASN1_FILES) "$(RELSYSDIR)/src/binary"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src/binary"
+
+
+ release_docs_spec:
+diff --git a/lib/megaco/src/engine/Makefile b/lib/megaco/src/engine/Makefile
+index 7cecef1..841a88a 100644
+--- a/lib/megaco/src/engine/Makefile
++++ b/lib/megaco/src/engine/Makefile
+@@ -101,7 +101,7 @@ release_spec: opt
+ $(INSTALL_DATA) $(BEHAVIOUR_TARGET_FILES) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/engine"
+- $(INSTALL_DATA) $(ERL_FILES) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src/engine"
++ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src/engine"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+
+
+diff --git a/lib/megaco/src/flex/Makefile.in b/lib/megaco/src/flex/Makefile.in
+index bd62e8b..cce5a8d 100644
+--- a/lib/megaco/src/flex/Makefile.in
++++ b/lib/megaco/src/flex/Makefile.in
+@@ -267,8 +267,6 @@ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/flex"
+ $(INSTALL_DIR) "$(RELSYSDIR)/priv/lib"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+- $(INSTALL_DATA) $(ERL_FILES) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src/flex"
+- $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+ ifeq ($(ENABLE_MEGACO_FLEX_SCANNER),true)
+ $(INSTALL_DATA) $(FLEX_FILES) "$(RELSYSDIR)/src/flex"
+ $(INSTALL_PROGRAM) $(SOLIBS) "$(RELSYSDIR)/priv/lib"
+diff --git a/lib/megaco/src/tcp/Makefile b/lib/megaco/src/tcp/Makefile
+index 0c30aba..aa553ff 100644
+--- a/lib/megaco/src/tcp/Makefile
++++ b/lib/megaco/src/tcp/Makefile
+@@ -93,7 +93,7 @@ release_spec: opt
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/tcp"
+- $(INSTALL_DATA) $(ERL_FILES) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src/tcp"
++ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src/tcp"
+
+
+ release_docs_spec:
+diff --git a/lib/megaco/src/text/Makefile b/lib/megaco/src/text/Makefile
+index cab4256..d5cf217 100644
+--- a/lib/megaco/src/text/Makefile
++++ b/lib/megaco/src/text/Makefile
+@@ -134,7 +134,7 @@ release_spec: opt
+ $(INSTALL_DATA) $(BEAM_TARGET_FILES) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/text"
+- $(INSTALL_DATA) $(ERL_FILES) $(INTERNAL_YRL_FILES) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src/text"
++ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src/text"
+
+
+ release_docs_spec:
+diff --git a/lib/megaco/src/udp/Makefile b/lib/megaco/src/udp/Makefile
+index 9486804..ea4830c 100644
+--- a/lib/megaco/src/udp/Makefile
++++ b/lib/megaco/src/udp/Makefile
+@@ -93,7 +93,7 @@ release_spec: opt
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/udp"
+- $(INSTALL_DATA) $(ERL_FILES) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src/udp"
++ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src/udp"
+
+
+ release_docs_spec:
+diff --git a/lib/mnesia/src/Makefile b/lib/mnesia/src/Makefile
+index ac38fa0..20bce7e 100644
+--- a/lib/mnesia/src/Makefile
++++ b/lib/mnesia/src/Makefile
+@@ -132,7 +132,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(HRL_FILES) $(ERL_FILES) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/observer/src/Makefile b/lib/observer/src/Makefile
+index c120865..6831d23 100644
+--- a/lib/observer/src/Makefile
++++ b/lib/observer/src/Makefile
+@@ -149,7 +149,6 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/examples"
+ $(INSTALL_DATA) $(EXAMPLE_FILES) "$(RELSYSDIR)/examples"
+diff --git a/lib/odbc/src/Makefile b/lib/odbc/src/Makefile
+index bfbda8a..6e4ad54 100644
+--- a/lib/odbc/src/Makefile
++++ b/lib/odbc/src/Makefile
+@@ -109,7 +109,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(EXT_HRL_FILES) "$(RELSYSDIR)/include"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+diff --git a/lib/orber/COSS/CosNaming/Makefile b/lib/orber/COSS/CosNaming/Makefile
+index 8140620..73df530 100644
+--- a/lib/orber/COSS/CosNaming/Makefile
++++ b/lib/orber/COSS/CosNaming/Makefile
+@@ -144,8 +144,8 @@ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(APP_TARGET) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/COSS/CosNaming"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) $(IDL_FILE) "$(RELSYSDIR)/COSS/CosNaming"
+- $(INSTALL_DATA) $(GEN_FILES) "$(RELSYSDIR)/COSS/CosNaming"
++ $(INSTALL_DATA) $(HRL_FILES) $(IDL_FILE) "$(RELSYSDIR)/COSS/CosNaming"
++ $(INSTALL_DATA) $(GEN_HRL_FILES) $(GEN_EXT_HRL_FILES) "$(RELSYSDIR)/COSS/CosNaming"
+
+
+ release_docs_spec:
+diff --git a/lib/orber/src/Makefile b/lib/orber/src/Makefile
+index 398e481..f079e77 100644
+--- a/lib/orber/src/Makefile
++++ b/lib/orber/src/Makefile
+@@ -252,7 +252,7 @@ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(APP_TARGET) $(APPUP_TARGET) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(YRL_FILE) $(GEN_HRL_FILES_LOC) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(GEN_HRL_FILES_LOC) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(EXTERNAL_HRL_FILES) $(GEN_HRL_FILES_EXT) "$(RELSYSDIR)/include"
+
+diff --git a/lib/os_mon/src/Makefile b/lib/os_mon/src/Makefile
+index 4e78cf8..69d434c 100644
+--- a/lib/os_mon/src/Makefile
++++ b/lib/os_mon/src/Makefile
+@@ -104,7 +104,6 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+diff --git a/lib/ose/src/Makefile b/lib/ose/src/Makefile
+index 88f8957..ab08a88 100644
+--- a/lib/ose/src/Makefile
++++ b/lib/ose/src/Makefile
+@@ -93,9 +93,6 @@ $(APPUP_TARGET): $(APPUP_SRC) ../vsn.mk
+ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+- $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) "$(RELSYSDIR)/src"
+- $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/otp_mibs/src/Makefile b/lib/otp_mibs/src/Makefile
+index 6096240..cbc41e6 100644
+--- a/lib/otp_mibs/src/Makefile
++++ b/lib/otp_mibs/src/Makefile
+@@ -95,8 +95,6 @@ $(APPUP_TARGET): $(APPUP_SRC) ../vsn.mk
+ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+- $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGETS) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/parsetools/src/Makefile b/lib/parsetools/src/Makefile
+index 2ee2285..ea075ed 100644
+--- a/lib/parsetools/src/Makefile
++++ b/lib/parsetools/src/Makefile
+@@ -90,8 +90,6 @@ $(APPUP_TARGET): $(APPUP_SRC) ../vsn.mk
+ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+- $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+diff --git a/lib/percept/src/Makefile b/lib/percept/src/Makefile
+index 0282d63..5902da3 100644
+--- a/lib/percept/src/Makefile
++++ b/lib/percept/src/Makefile
+@@ -96,7 +96,6 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src"
+ # $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ # $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/include"
+diff --git a/lib/public_key/asn1/Makefile b/lib/public_key/asn1/Makefile
+index c1b3bc8..3d021cf 100644
+--- a/lib/public_key/asn1/Makefile
++++ b/lib/public_key/asn1/Makefile
+@@ -95,8 +95,8 @@ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/include"
+ $(INSTALL_DIR) "$(RELSYSDIR)/asn1"
+- $(INSTALL_DATA) $(ASN_ASNS) $(ASN_ERLS) $(ASN_HRLS) $(ASN_CONFIGS) \
+- $(GEN_ERLS) "$(RELSYSDIR)/asn1"
++ $(INSTALL_DATA) $(ASN_ASNS) $(ASN_HRLS) $(ASN_CONFIGS) \
++ "$(RELSYSDIR)/asn1"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/public_key/src/Makefile b/lib/public_key/src/Makefile
+index 09393e8..eb4c54d 100644
+--- a/lib/public_key/src/Makefile
++++ b/lib/public_key/src/Makefile
+@@ -49,8 +49,6 @@ MODULES = \
+
+ HRL_FILES = $(INCLUDE)/public_key.hrl
+
+-INTERNAL_HRL_FILES =
+-
+ ERL_FILES = $(MODULES:%=%.erl)
+
+ TARGET_FILES= $(MODULES:%=$(EBIN)/%.$(EMULATOR))
+@@ -103,8 +101,6 @@ $(APPUP_TARGET): $(APPUP_SRC) ../vsn.mk
+ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+- $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(INTERNAL_HRL_FILES) $(ERL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/include"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+diff --git a/lib/reltool/src/Makefile b/lib/reltool/src/Makefile
+index b8387ff..2012af9 100644
+--- a/lib/reltool/src/Makefile
++++ b/lib/reltool/src/Makefile
+@@ -99,7 +99,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(INTERNAL_HRL_FILES) $(ERL_FILES) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(APP_TARGET) $(APPUP_TARGET) "$(RELSYSDIR)/ebin"
+diff --git a/lib/runtime_tools/src/Makefile b/lib/runtime_tools/src/Makefile
+index 8d2bcfe..d1a9cac 100644
+--- a/lib/runtime_tools/src/Makefile
++++ b/lib/runtime_tools/src/Makefile
+@@ -96,8 +96,6 @@ docs:
+ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+- $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/include"
+ $(INSTALL_DIR) "$(RELSYSDIR)/examples"
+diff --git a/lib/sasl/src/Makefile b/lib/sasl/src/Makefile
+index ab2d3a3..bb53a67 100644
+--- a/lib/sasl/src/Makefile
++++ b/lib/sasl/src/Makefile
+@@ -92,7 +92,6 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+diff --git a/lib/snmp/src/agent/Makefile b/lib/snmp/src/agent/Makefile
+index beed696..752072d 100644
+--- a/lib/snmp/src/agent/Makefile
++++ b/lib/snmp/src/agent/Makefile
+@@ -130,7 +130,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/agent"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) "$(RELSYSDIR)/src/agent"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src/agent"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(APP_TARGET) $(APPUP_TARGET) \
+ "$(RELSYSDIR)/ebin"
+diff --git a/lib/snmp/src/app/Makefile b/lib/snmp/src/app/Makefile
+index b8cc4b8..d806efb 100644
+--- a/lib/snmp/src/app/Makefile
++++ b/lib/snmp/src/app/Makefile
+@@ -131,7 +131,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/app"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) "$(RELSYSDIR)/src/app"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src/app"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(APP_TARGET) $(APPUP_TARGET) \
+ "$(RELSYSDIR)/ebin"
+diff --git a/lib/snmp/src/compile/Makefile b/lib/snmp/src/compile/Makefile
+index f63fc18..9759451 100644
+--- a/lib/snmp/src/compile/Makefile
++++ b/lib/snmp/src/compile/Makefile
+@@ -122,7 +122,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/compiler"
+- $(INSTALL_DATA) $(ESCRIPT_SRC) $(PARSER_SRC) $(ERL_FILES) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src/compiler"
++ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src/compiler"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(EBIN_FILES) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/bin"
+diff --git a/lib/snmp/src/manager/Makefile b/lib/snmp/src/manager/Makefile
+index c76dbac..548823a 100644
+--- a/lib/snmp/src/manager/Makefile
++++ b/lib/snmp/src/manager/Makefile
+@@ -113,7 +113,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/manager"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) "$(RELSYSDIR)/src/manager"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src/manager"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+ # $(INSTALL_DIR) "$(RELSYSDIR)/include"
+diff --git a/lib/snmp/src/misc/Makefile b/lib/snmp/src/misc/Makefile
+index 698c341..3344a0c 100644
+--- a/lib/snmp/src/misc/Makefile
++++ b/lib/snmp/src/misc/Makefile
+@@ -111,7 +111,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/misc"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) "$(RELSYSDIR)/src/misc"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src/misc"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+ # $(INSTALL_DIR) "$(RELSYSDIR)/include"
+diff --git a/lib/ssh/src/Makefile b/lib/ssh/src/Makefile
+index 90d7110..e725c6c 100644
+--- a/lib/ssh/src/Makefile
++++ b/lib/ssh/src/Makefile
+@@ -135,7 +135,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(INTERNAL_HRL_FILES) $(ERL_FILES) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(BEHAVIOUR_TARGET_FILES) $(TARGET_FILES) $(APP_TARGET) \
+ $(APPUP_TARGET) "$(RELSYSDIR)/ebin"
+diff --git a/lib/ssl/src/Makefile b/lib/ssl/src/Makefile
+index 0c00a65..acec405 100644
+--- a/lib/ssl/src/Makefile
++++ b/lib/ssl/src/Makefile
+@@ -137,7 +137,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(BEHAVIOUR_TARGET_FILES) $(TARGET_FILES) $(APP_TARGET) \
+ $(APPUP_TARGET) "$(RELSYSDIR)/ebin"
+diff --git a/lib/stdlib/src/Makefile b/lib/stdlib/src/Makefile
+index 9ab2cd4..876bfd2 100644
+--- a/lib/stdlib/src/Makefile
++++ b/lib/stdlib/src/Makefile
+@@ -203,7 +203,6 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) erl_parse.yrl "$(RELSYSDIR)/src"
+ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/include"
+diff --git a/lib/syntax_tools/src/Makefile b/lib/syntax_tools/src/Makefile
+index c9fbad8..2fc7f18 100644
+--- a/lib/syntax_tools/src/Makefile
++++ b/lib/syntax_tools/src/Makefile
+@@ -82,8 +82,6 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(OBJECTS) "$(RELSYSDIR)/ebin"
+- $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(SOURCES) "$(RELSYSDIR)/src"
+
+ release_docs_spec:
+
+diff --git a/lib/test_server/src/Makefile b/lib/test_server/src/Makefile
+index 35bbad3..deb7caf 100644
+--- a/lib/test_server/src/Makefile
++++ b/lib/test_server/src/Makefile
+@@ -123,7 +123,6 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) $(TS_HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/include"
+diff --git a/lib/tools/src/Makefile b/lib/tools/src/Makefile
+index e606b97..1beb8cc 100644
+--- a/lib/tools/src/Makefile
++++ b/lib/tools/src/Makefile
+@@ -106,7 +106,7 @@ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(YRL_FILE) $(HRL_FILES) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(APP_TARGET) $(APPUP_TARGET) \
+ "$(RELSYSDIR)/ebin"
+diff --git a/lib/typer/src/Makefile b/lib/typer/src/Makefile
+index a7059de..0b1ae2a 100644
+--- a/lib/typer/src/Makefile
++++ b/lib/typer/src/Makefile
+@@ -101,9 +101,6 @@ $(APPUP_TARGET): $(APPUP_SRC) ../vsn.mk
+ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+- $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) $(YRL_FILES) \
+- "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(INSTALL_FILES) "$(RELSYSDIR)/ebin"
+
+diff --git a/lib/webtool/src/Makefile b/lib/webtool/src/Makefile
+index af565c8..6c65b26 100644
+--- a/lib/webtool/src/Makefile
++++ b/lib/webtool/src/Makefile
+@@ -87,8 +87,6 @@ $(APPUP_TARGET): $(APPUP_SRC) ../vsn.mk
+ include $(ERL_TOP)/make/otp_release_targets.mk
+
+ release_spec: opt
+- $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) $(APP_TARGET) $(APPUP_TARGET) \
+ "$(RELSYSDIR)/ebin"
+diff --git a/lib/wx/src/Makefile b/lib/wx/src/Makefile
+index 26574ed..266a5d6 100644
+--- a/lib/wx/src/Makefile
++++ b/lib/wx/src/Makefile
+@@ -121,9 +121,9 @@ $(EBIN)/%.beam: $(EGEN)/%.erl $(HEADER_FILES)
+ include $(ERL_TOP)/make/otp_release_targets.mk
+ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(HRL_FILES) $(ERL_FILES) "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src/gen"
+- $(INSTALL_DATA) $(GEN_HRL) $(GEN_FILES) "$(RELSYSDIR)/src/gen"
++ $(INSTALL_DATA) $(GEN_HRL) "$(RELSYSDIR)/src/gen"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(EXT_HRL) "$(RELSYSDIR)/include"
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+diff --git a/lib/xmerl/src/Makefile b/lib/xmerl/src/Makefile
+index d5ce3fe..e21e4b1 100644
+--- a/lib/xmerl/src/Makefile
++++ b/lib/xmerl/src/Makefile
+@@ -217,9 +217,7 @@ release_spec: opt
+ $(INSTALL_DIR) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DATA) $(TARGET_FILES) "$(RELSYSDIR)/ebin"
+ $(INSTALL_DIR) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) $(ERL_FILES) $(INTERNAL_HRL_FILES) $(APP_SRC) $(APPUP_SRC) "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) xmerl_xpath_parse.yrl "$(RELSYSDIR)/src"
+- $(INSTALL_DATA) xmerl_b64Bin.yrl "$(RELSYSDIR)/src"
++ $(INSTALL_DATA) $(INTERNAL_HRL_FILES) "$(RELSYSDIR)/src"
+ $(INSTALL_DIR) "$(RELSYSDIR)/include"
+ $(INSTALL_DATA) $(HRL_FILES) "$(RELSYSDIR)/include"
+
diff --git a/testing/erlang/otp-0007-Split-off-webtool-dependency-from-tools.patch b/testing/erlang/otp-0007-Split-off-webtool-dependency-from-tools.patch
new file mode 100644
index 0000000000..f2de8ac471
--- /dev/null
+++ b/testing/erlang/otp-0007-Split-off-webtool-dependency-from-tools.patch
@@ -0,0 +1,40 @@
+From: Peter Lemenkov <lemenkov@gmail.com>
+Date: Sat, 8 Nov 2014 22:54:57 +0300
+Subject: [PATCH] Split off webtool dependency from tools
+
+Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
+
+diff --git a/lib/tools/src/cover_web.erl b/lib/tools/src/cover_web.erl
+index 69f2f3b..9085300 100644
+--- a/lib/tools/src/cover_web.erl
++++ b/lib/tools/src/cover_web.erl
+@@ -50,14 +50,25 @@
+ %%%----------------------------------------------------------------------
+ %% Start webtool and webcover from erlang shell
+ start() ->
+- webtool:start(),
+- webtool:start_tools([],"app=webcover"),
++ try
++ % Disable automatic dependency picking up
++ erlang:apply(webtool, start, []),
++ erlang:apply(webtool, start_tools, [[],"app=webcover"])
++ catch
++ error:undef -> error_logger:error_msg("No erlang-webtool found.~nPlease install erlang-webtool package first.~n")
++ end,
+ ok.
+
+ %% Stop webtool and webcover from erlang shell
+ stop() ->
+- webtool:stop_tools([],"app=webcover"),
+- webtool:stop().
++ try
++ % Disable automatic dependency picking up
++ erlang:apply(webtool, stop_tools, [[],"app=webcover"]),
++ erlang:apply(webtool, stop, [])
++ catch
++ error:undef -> error_logger:error_msg("No erlang-webtool found.~nPlease install erlang-webtool package first.~n")
++ end,
++ ok.
+
+
+
diff --git a/testing/erlang/otp-0008-Introduce-os-getenv-2.patch b/testing/erlang/otp-0008-Introduce-os-getenv-2.patch
new file mode 100644
index 0000000000..6c48db2122
--- /dev/null
+++ b/testing/erlang/otp-0008-Introduce-os-getenv-2.patch
@@ -0,0 +1,63 @@
+From: Peter Lemenkov <lemenkov@gmail.com>
+Date: Sat, 8 Nov 2014 15:11:04 +0300
+Subject: [PATCH] Introduce os:getenv/2
+
+Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
+
+diff --git a/lib/kernel/doc/src/os.xml b/lib/kernel/doc/src/os.xml
+index 2b57e75..8b85f24 100644
+--- a/lib/kernel/doc/src/os.xml
++++ b/lib/kernel/doc/src/os.xml
+@@ -100,6 +100,19 @@ DirOut = os:cmd("dir"), % on Win32 platform</code>
+ </desc>
+ </func>
+ <func>
++ <name name="getenv" arity="2"/>
++ <fsummary>Get the value of an environment variable</fsummary>
++ <desc>
++ <p>Returns the <c><anno>Value</anno></c> of the environment variable
++ <c><anno>VarName</anno></c>, or <c>DefaultValue</c> if the environment variable
++ is undefined.</p>
++ <p>If Unicode file name encoding is in effect (see the <seealso
++ marker="erts:erl#file_name_encoding">erl manual
++ page</seealso>), the strings (both <c><anno>VarName</anno></c> and
++ <c><anno>Value</anno></c>) may contain characters with codepoints > 255.</p>
++ </desc>
++ </func>
++ <func>
+ <name name="getpid" arity="0"/>
+ <fsummary>Return the process identifier of the emulator process</fsummary>
+ <desc>
+diff --git a/lib/kernel/src/os.erl b/lib/kernel/src/os.erl
+index 187fd00..8aaf13b 100644
+--- a/lib/kernel/src/os.erl
++++ b/lib/kernel/src/os.erl
+@@ -26,7 +26,7 @@
+
+ %%% BIFs
+
+--export([getenv/0, getenv/1, getpid/0, putenv/2, timestamp/0, unsetenv/1]).
++-export([getenv/0, getenv/1, getenv/2, getpid/0, putenv/2, timestamp/0, unsetenv/1]).
+
+ -spec getenv() -> [string()].
+
+@@ -39,6 +39,19 @@ getenv() -> erlang:nif_error(undef).
+ getenv(_) ->
+ erlang:nif_error(undef).
+
++-spec getenv(VarName, DefaultValue) -> Value when
++ VarName :: string(),
++ DefaultValue :: string(),
++ Value :: string().
++
++getenv(VarName, DefaultValue) ->
++ case os:getenv(VarName) of
++ false ->
++ DefaultValue;
++ Value ->
++ Value
++ end.
++
+ -spec getpid() -> Value when
+ Value :: string().
+
diff --git a/testing/erlang/otp-0009-Patch-removes-support-for-SSLv3-protocol-because-it-.patch b/testing/erlang/otp-0009-Patch-removes-support-for-SSLv3-protocol-because-it-.patch
new file mode 100644
index 0000000000..fa55663342
--- /dev/null
+++ b/testing/erlang/otp-0009-Patch-removes-support-for-SSLv3-protocol-because-it-.patch
@@ -0,0 +1,100 @@
+From: Sergei Golovan <sgolovan@debian.org>
+Date: Sun, 30 Nov 2014 20:20:41 +0300
+Subject: [PATCH] Patch removes support for SSLv3 protocol because it is proved
+ to be insecure and nobody should use it anymore.
+
+
+diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml
+index b53344e..b245621 100644
+--- a/lib/ssl/doc/src/ssl.xml
++++ b/lib/ssl/doc/src/ssl.xml
+@@ -123,7 +123,7 @@
+
+ <p><c>sslsocket() - opaque to the user. </c></p>
+
+- <p><c>protocol() = sslv3 | tlsv1 | 'tlsv1.1' | 'tlsv1.2' </c></p>
++ <p><c>protocol() = tlsv1 | 'tlsv1.1' | 'tlsv1.2' </c></p>
+
+ <p><c>ciphers() = [ciphersuite()] | string() (according to old API)</c></p>
+
+diff --git a/lib/ssl/doc/src/ssl_app.xml b/lib/ssl/doc/src/ssl_app.xml
+index 43cb393..ff12e04 100644
+--- a/lib/ssl/doc/src/ssl_app.xml
++++ b/lib/ssl/doc/src/ssl_app.xml
+@@ -47,10 +47,10 @@
+ </p>
+ <p>Note that the environment parameters can be set on the command line,
+ for instance,</p>
+- <p><c>erl ... -ssl protocol_version '[sslv3, tlsv1]' ...</c>.
++ <p><c>erl ... -ssl protocol_version '[tlsv1.1, tlsv1]' ...</c>.
+ </p>
+ <taglist>
+- <tag><c><![CDATA[protocol_version = [sslv3|tlsv1] <optional>]]></c>.</tag>
++ <tag><c><![CDATA[protocol_version = [tlsv1|tlsv1.1|tlsv1.2] <optional>]]></c>.</tag>
+ <item>
+ <p>Protocol that will be supported by started clients and
+ servers. If this option is not set it will default to all
+@@ -58,6 +58,9 @@
+ Note that this option may be overridden by the version option
+ to ssl:connect/[2,3] and ssl:listen/2.
+ </p>
++ <p>For Debian GNU/Linux distribution the sslv3 protocol was
++ disabled due to its security issues.
++ </p>
+ </item>
+
+ <tag><c><![CDATA[session_lifetime = integer() <optional>]]></c></tag>
+diff --git a/lib/ssl/src/ssl_internal.hrl b/lib/ssl/src/ssl_internal.hrl
+index 75efb64..155fa81 100644
+--- a/lib/ssl/src/ssl_internal.hrl
++++ b/lib/ssl/src/ssl_internal.hrl
+@@ -67,8 +67,8 @@
+ -define(TRUE, 0).
+ -define(FALSE, 1).
+
+--define(ALL_SUPPORTED_VERSIONS, ['tlsv1.2', 'tlsv1.1', tlsv1, sslv3]).
+--define(MIN_SUPPORTED_VERSIONS, ['tlsv1.1', tlsv1, sslv3]).
++-define(ALL_SUPPORTED_VERSIONS, ['tlsv1.2', 'tlsv1.1', tlsv1]).
++-define(MIN_SUPPORTED_VERSIONS, ['tlsv1.1', tlsv1]).
+ -define(ALL_DATAGRAM_SUPPORTED_VERSIONS, ['dtlsv1.2', dtlsv1]).
+ -define(MIN_DATAGRAM_SUPPORTED_VERSIONS, ['dtlsv1.2', dtlsv1]).
+
+diff --git a/lib/ssl/src/ssl_record.hrl b/lib/ssl/src/ssl_record.hrl
+index 6aab35d..1511abd 100644
+--- a/lib/ssl/src/ssl_record.hrl
++++ b/lib/ssl/src/ssl_record.hrl
+@@ -144,6 +144,7 @@
+ %% }).
+
+ -define(LOWEST_MAJOR_SUPPORTED_VERSION, 3).
++-define(LOWEST_MINOR_SUPPORTED_VERSION, 1).
+
+
+ -record(generic_stream_cipher, {
+diff --git a/lib/ssl/src/tls_record.erl b/lib/ssl/src/tls_record.erl
+index f50ea22..aa4fc8d 100644
+--- a/lib/ssl/src/tls_record.erl
++++ b/lib/ssl/src/tls_record.erl
+@@ -276,14 +276,20 @@ supported_protocol_versions([_|_] = Vsns) ->
+ %%--------------------------------------------------------------------
+ -spec is_acceptable_version(tls_version()) -> boolean().
+ is_acceptable_version({N,_})
+- when N >= ?LOWEST_MAJOR_SUPPORTED_VERSION ->
++ when N > ?LOWEST_MAJOR_SUPPORTED_VERSION ->
++ true;
++is_acceptable_version({N,M})
++ when N == ?LOWEST_MAJOR_SUPPORTED_VERSION andalso M >= ?LOWEST_MINOR_SUPPORTED_VERSION ->
+ true;
+ is_acceptable_version(_) ->
+ false.
+
+ -spec is_acceptable_version(tls_version(), Supported :: [tls_version()]) -> boolean().
+ is_acceptable_version({N,_} = Version, Versions)
+- when N >= ?LOWEST_MAJOR_SUPPORTED_VERSION ->
++ when N > ?LOWEST_MAJOR_SUPPORTED_VERSION ->
++ lists:member(Version, Versions);
++is_acceptable_version({N,M} = Version, Versions)
++ when N == ?LOWEST_MAJOR_SUPPORTED_VERSION andalso M >= ?LOWEST_MINOR_SUPPORTED_VERSION ->
+ lists:member(Version, Versions);
+ is_acceptable_version(_,_) ->
+ false.
diff --git a/testing/erlang/remove-private-unit32.patch b/testing/erlang/remove-private-unit32.patch
new file mode 100644
index 0000000000..cfc08cc1fe
--- /dev/null
+++ b/testing/erlang/remove-private-unit32.patch
@@ -0,0 +1,11 @@
+--- otp_src_17.4/erts/emulator/sys/common/erl_poll.h
++++ otp_src_17.4-fixed/erts/emulator/sys/common/erl_poll.h
+@@ -129,7 +129,7 @@
+ #include <sys/epoll.h>
+
+ #define ERTS_POLL_EV_E2N(EV) \
+- ((__uint32_t) (EV))
++ ((uint32_t) (EV))
+ #define ERTS_POLL_EV_N2E(EV) \
+ ((ErtsPollEvents) (EV))
+
diff --git a/testing/erlang/replace_glibc_check.patch b/testing/erlang/replace_glibc_check.patch
new file mode 100644
index 0000000000..170bbbb118
--- /dev/null
+++ b/testing/erlang/replace_glibc_check.patch
@@ -0,0 +1,20 @@
+--- otp_src_17.4/lib/erl_interface/src/connect/ei_resolve.c
++++ otp_src_17.4-fixed/lib/erl_interface/src/connect/ei_resolve.c
+@@ -615,7 +615,7 @@
+ #ifndef HAVE_GETHOSTBYNAME_R
+ return my_gethostbyaddr_r(addr,length,type,hostp,buffer,buflen,h_errnop);
+ #else
+-#if (defined(__GLIBC__) || (__FreeBSD_version >= 602000) || defined(__DragonFly__))
++#if (defined(_BSD_SOURCE) || (__FreeBSD_version >= 602000) || defined(__DragonFly__))
+ struct hostent *result;
+
+ gethostbyaddr_r(addr, length, type, hostp, buffer, buflen, &result,
+@@ -642,7 +642,7 @@
+ #ifndef HAVE_GETHOSTBYNAME_R
+ return my_gethostbyname_r(name,hostp,buffer,buflen,h_errnop);
+ #else
+-#if (defined(__GLIBC__) || (__FreeBSD_version >= 602000) || defined(__DragonFly__) || defined(__ANDROID__))
++#if (defined(_BSD_SOURCE) || (__FreeBSD_version >= 602000) || defined(__DragonFly__) || defined(__ANDROID__))
+ struct hostent *result;
+
+ gethostbyname_r(name, hostp, buffer, buflen, &result, h_errnop);