diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
commit | 4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch) | |
tree | ba5f07bf3f9d22d82e54a462313f5d244036c768 /dev-ml/ocamlnet |
reinit the tree, so we can have metadata
Diffstat (limited to 'dev-ml/ocamlnet')
-rw-r--r-- | dev-ml/ocamlnet/Manifest | 10 | ||||
-rw-r--r-- | dev-ml/ocamlnet/files/ocaml405.patch | 145 | ||||
-rw-r--r-- | dev-ml/ocamlnet/metadata.xml | 12 | ||||
-rw-r--r-- | dev-ml/ocamlnet/ocamlnet-4.1.2.ebuild | 81 | ||||
-rw-r--r-- | dev-ml/ocamlnet/ocamlnet-4.1.3.ebuild | 77 | ||||
-rw-r--r-- | dev-ml/ocamlnet/ocamlnet-4.1.4.ebuild | 77 |
6 files changed, 402 insertions, 0 deletions
diff --git a/dev-ml/ocamlnet/Manifest b/dev-ml/ocamlnet/Manifest new file mode 100644 index 000000000000..589543c660f3 --- /dev/null +++ b/dev-ml/ocamlnet/Manifest @@ -0,0 +1,10 @@ +AUX ocaml405.patch 4761 SHA256 494eb62271ac80605a919d7ba4d5bb8dd0f1864e87f1986c450df727cb9f5d80 SHA512 79378c0cb59ca4abc2280932045ca80e5d7e3ff47919067c363f96d32e24899825f79a83bcf0abfc600513eecc8e046382a42937545b4b62f9b5f992d8d29480 WHIRLPOOL 866d3de3169736db6caf602997af2d9b98f9aaaad371d13a41ab4eb329d6bcf2b76ca4e0346b8ec83ea789043b8b86601f55a09977bb98f193f002c53418a95f +DIST ocamlnet-4.1.2.tar.gz 4623183 SHA256 918c3921529cfe545e206b3535a58f43f665165044dd3548f685b583e94f14d8 SHA512 69f42042a54efd662db2217224da53513fc7e72c7b2313d4a4a1128f1b4624f4f6298434f5b19f354b832119ff151abc81e85eb0108d6eb24f30f82d176e0b4d WHIRLPOOL 27e1a8eb24361cadb8b2fb2b61bc6e93d71be8290873ca5bb1eebe16b9c9b1db69eae3b20c8deb3f6656aa79171a817b15acae53159d80ff8f4c946c201de173 +DIST ocamlnet-4.1.3.tar.gz 4553037 SHA256 8a01393ed26c5475bba89aab928e9aa8a366af1e810416d9c916265a7f1cd5c5 SHA512 683ab6f529639c9da01478ba8ba7a1bf89a418ad3872331bb3e29067c0a75ddc0db996630ce5a5dd116967d6e3e756ade02d9a78b865bbc226f95d01af9e3956 WHIRLPOOL 56f2772ea02bbf9c3166d13797083cabc8a8dad8f8c53be7796361383f7c9ff9406e0d273d402a2415b3f5437b163977ad7f5a1bfccb46994de552dd4ebd1acb +DIST ocamlnet-4.1.4.tar.gz 4552969 SHA256 46c3dace26123bdded9fd5ee841a18ede47d4b940e9320ce1db168d5891e1142 SHA512 ca502444f81898ccda27d61760a357aad59624cf3c4c025d49dd1c2e7bc3ef497c199634247ba7731e016c234e5cd92d2599d1ef9ecd55c3b6e7a64fc4773ee0 WHIRLPOOL aab363eaae3528f792218ec360a4dbf927984e6bd85d4bf5eb6292f64da035b6ed67957a43ef8df62208425cbafe4582b65c07e150600db591f76f9483bd46ff +EBUILD ocamlnet-4.1.2.ebuild 1713 SHA256 840082747df285216fcd16ed4ee3b323bb2b1662e75b39c62c8278a4ceb8add8 SHA512 1f6038416a3bf9dd50659dff33c8ebaf200dd732497bd14cfdcaece78829e21073a1b3ec3f49f030f410748ffd6c77b14ec7b4aebef8276f977605cb2d28c63b WHIRLPOOL 5b7a14758b049958d2a96bf8a82c088a28594459d539500b8d72ce1d238c0ad313fb55fc398a35bbba72d0fd3c2dfadd95ff573bea34fbb80b4cf9fa355dedc5 +EBUILD ocamlnet-4.1.3.ebuild 1661 SHA256 718864b459b2060fd80c7f69041a07fcd06a584332676439b7bf7e223b8fe90b SHA512 062da5d5273fbbe357a24e6273b7d6009b976aaf5112eda40fde4038b6d5fc199165b3325c5e10709610f3f639c5acdd430335f36615966e21be90497f5f02fa WHIRLPOOL a52467ba1f0acd60beacebf4154f623601b1e5f283cc2c82c167e36f03bb75c327fad860c33bc2a3d72dac22ea6ea9d8fd11d0c8eae3fe293db566af16eb4485 +EBUILD ocamlnet-4.1.4.ebuild 1661 SHA256 718864b459b2060fd80c7f69041a07fcd06a584332676439b7bf7e223b8fe90b SHA512 062da5d5273fbbe357a24e6273b7d6009b976aaf5112eda40fde4038b6d5fc199165b3325c5e10709610f3f639c5acdd430335f36615966e21be90497f5f02fa WHIRLPOOL a52467ba1f0acd60beacebf4154f623601b1e5f283cc2c82c167e36f03bb75c327fad860c33bc2a3d72dac22ea6ea9d8fd11d0c8eae3fe293db566af16eb4485 +MISC ChangeLog 7591 SHA256 3529d607d32d761e805311d97e78df7318e8ee278e2534186aa44e76f3cb267e SHA512 766a8b0fbc890ed4b8611f37f1f9843b52375d2bdae9b85a6b8744f1fdb2cb59c02875808c61f5dbeca1adcd7a6b5bdc0bd316b5c38b436a004e08f30ee6c44e WHIRLPOOL b2e752ff65e29c197b1ffd1a045d1ca8027f0f49a187b86ff73eb2cd712383d47215369b01a6f10a3faad72f1b825fcb5a6c727d59656e21eb819a9011427a94 +MISC ChangeLog-2015 11602 SHA256 ad19ddb70d18bf8e1e8729014e4871529f0a62a3acd53e263f99701c2b92b676 SHA512 0e4e31b90238c3cf3263636ea6170a299cff214768e8a8e7b36c8c9a56d32ec9fa6da30d08d189df2e05d1e2244954fdb8f660196245510967f2783420b8346d WHIRLPOOL 6f5692eddc354d2f392444bd76a5c2ecc61da28346872af840c0c71086db9efad493ec29797d4807e88757870551c5d673d11610df664d79a42ee5b1a5339188 +MISC metadata.xml 418 SHA256 cb985985a1063f08fcbcdb17ec6498b6ce4869a7506921cd399d2e9563f0de28 SHA512 fc37f93cd3e0ff137825c24b36d564842bad46e4f34a080a6fcbcfdb307fa7a23f8fc82f0edb2a5a08a08e39be866e7f395d28119b8bc595d3af4a11ef1d7578 WHIRLPOOL ed0db148928fb6d5e1d2bd83c1c1958c7a433cad36ee4722fdef03927356cbe69b73e94cd49eac8a9d9162cc78bdabe8739713a1580b2b0638c152b8d610efb4 diff --git a/dev-ml/ocamlnet/files/ocaml405.patch b/dev-ml/ocamlnet/files/ocaml405.patch new file mode 100644 index 000000000000..a112d1fb4473 --- /dev/null +++ b/dev-ml/ocamlnet/files/ocaml405.patch @@ -0,0 +1,145 @@ +commit f3d451b81c4caa8cce7f55af6463ec685e79e227 +Author: Gerd Stolpmann <gerd@gerd-stolpmann.de> +Date: Sun Feb 26 21:04:49 2017 +0100 + + ocaml-4.05: support for O_KEEPEXEC + +diff --git a/code/src/netsys/Makefile b/code/src/netsys/Makefile +index cbc1ce2..cb70a09 100644 +--- a/code/src/netsys/Makefile ++++ b/code/src/netsys/Makefile +@@ -56,7 +56,7 @@ OCAMLC_OPTIONS_FOR_netsys_c_xdr.c = -ccopt -O + OCAMLC_OPTIONS += $(STRING_OPTS) + OCAMLOPT_OPTIONS += $(STRING_OPTS) + +-PP_OPTIONS = -pp "$(CPPO) $(DEF_O_SHARE_DELETE) $(DEF_O_CLOEXEC) $(PP_BYTES) $(PP_DEPRECATED)" ++PP_OPTIONS = -pp "$(CPPO) $(DEF_O_SHARE_DELETE) $(DEF_O_CLOEXEC) $(DEF_O_KEEPEXEC) $(PP_BYTES) $(PP_DEPRECATED)" + + INSTALL_EXTRA += netsys_c_event.h $(OOH_OBJECT) + +diff --git a/code/src/netsys/configure b/code/src/netsys/configure +index 1325843..f4dbc09 100755 +--- a/code/src/netsys/configure ++++ b/code/src/netsys/configure +@@ -437,6 +437,21 @@ else + echo "no" + fi + ++###################################################################### ++ ++printf "Checking for O_KEEPEXEC... " ++mkdir -p tmp ++cat <<_EOF_ >tmp/t.ml ++let x = Unix.O_KEEPEXEC;; ++_EOF_ ++ ++def_o_keepexec="-D NO_O_KEEPEXEC" ++if ocaml unix.cma tmp/t.ml >/dev/null 2>/dev/null; then ++ echo "yes" ++ def_o_keepexec="-D HAVE_O_KEEPEXEC" ++else ++ echo "no" ++fi + + ###################################################################### + +@@ -445,6 +460,7 @@ cat <<EOF >Makefile.conf + NETSYS_LINK_OPTIONS = $netsys_link_options + DEF_O_SHARE_DELETE = $def_o_share_delete + DEF_O_CLOEXEC = $def_o_cloexec ++DEF_O_KEEPEXEC = $def_o_keepexec + OOH_OBJECT = $def_ooh_object + EOF + +diff --git a/code/src/netsys/netsys_c.c b/code/src/netsys/netsys_c.c +index a8b16be..4c30873 100644 +--- a/code/src/netsys/netsys_c.c ++++ b/code/src/netsys/netsys_c.c +@@ -448,32 +448,43 @@ static int at_flags_table[] = { + #ifndef O_RSYNC + #define O_RSYNC 0 + #endif +-#ifndef O_CLOEXEC +-#define NEED_CLOEXEC_EMULATION +-#define O_CLOEXEC 0 +-#endif + + static int open_flag_table[] = { + O_RDONLY, O_WRONLY, O_RDWR, O_NONBLOCK, O_APPEND, O_CREAT, O_TRUNC, O_EXCL, +- O_NOCTTY, O_DSYNC, O_SYNC, O_RSYNC, 0 /* O_SHARE_DELETE */, O_CLOEXEC ++ O_NOCTTY, O_DSYNC, O_SYNC, O_RSYNC, ++ 0 /* O_SHARE_DELETE */, 0 /* O_CLOEXEC */, 0 /* O_KEEPEXEC */ + }; + +-#ifdef NEED_CLOEXEC_EMULATION ++enum { CLOEXEC = 1, KEEPEXEC = 2 }; ++ + static int open_cloexec_table[] = { +- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1 ++ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, CLOEXEC, KEEPEXEC + }; ++#ifndef HAVE_O_KEEPEXEC ++#define unix_cloexec_default 0 + #endif ++ + #endif + + CAMLprim value netsys_openat(value dirfd, value path, value flags, value perm) + { + #ifdef HAVE_AT + CAMLparam4(dirfd, path, flags, perm); +- int ret, cv_flags; ++ int ret, cv_flags, clo_flags, cloexec; + char * p; + + /* shamelessly copied from ocaml distro */ + cv_flags = convert_flag_list(flags, open_flag_table); ++ clo_flags = convert_flag_list(flags, open_cloexec_table); ++ if (clo_flags & CLOEXEC) ++ cloexec = 1; ++ else if (clo_flags & KEEPEXEC) ++ cloexec = 0; ++ else ++ cloexec = unix_cloexec_default; ++#if defined(O_CLOEXEC) ++ if (cloexec) cv_flags |= O_CLOEXEC; ++#endif + p = stat_alloc(string_length(path) + 1); + strcpy(p, String_val(path)); + enter_blocking_section(); +@@ -481,8 +492,8 @@ CAMLprim value netsys_openat(value dirfd, value path, value flags, value perm) + leave_blocking_section(); + stat_free(p); + if (ret == -1) uerror("openat", path); +-#if defined(NEED_CLOEXEC_EMULATION) && defined(FD_CLOEXEC) +- if (convert_flag_list(flags, open_cloexec_table) != 0) { ++#if !defined(O_CLOEXEC) ++ { + int flags = fcntl(Int_val(dirfd), F_GETFD, 0); + if (flags == -1 || fcntl(Int_val(dirfd), F_SETFD, flags | FD_CLOEXEC) == -1) + uerror("openat", path); +diff --git a/code/src/netsys/netsys_posix.ml b/code/src/netsys/netsys_posix.ml +index 602ceae..3bf3e7c 100644 +--- a/code/src/netsys/netsys_posix.ml ++++ b/code/src/netsys/netsys_posix.ml +@@ -715,6 +715,12 @@ type at_flag = AT_EACCESS | AT_SYMLINK_NOFOLLOW | AT_SYMLINK_FOLLOW | + AT_REMOVEDIR + + (* The stubs assume these type definitions: *) ++#ifdef HAVE_O_KEEPEXEC ++type open_flag1 = Unix.open_flag = ++ O_RDONLY | O_WRONLY | O_RDWR | O_NONBLOCK | O_APPEND | O_CREAT | O_TRUNC ++ | O_EXCL | O_NOCTTY | O_DSYNC | O_SYNC | O_RSYNC | O_SHARE_DELETE ++ | O_CLOEXEC | O_KEEPEXEC ++#else + #ifdef HAVE_O_CLOEXEC + type open_flag1 = Unix.open_flag = + O_RDONLY | O_WRONLY | O_RDWR | O_NONBLOCK | O_APPEND | O_CREAT | O_TRUNC +@@ -731,6 +737,7 @@ type open_flag1 = Unix.open_flag = + | O_EXCL | O_NOCTTY | O_DSYNC | O_SYNC | O_RSYNC + #endif + #endif ++#endif + + type access_permission1 = Unix.access_permission = + R_OK | W_OK | X_OK | F_OK diff --git a/dev-ml/ocamlnet/metadata.xml b/dev-ml/ocamlnet/metadata.xml new file mode 100644 index 000000000000..196389cbbc7c --- /dev/null +++ b/dev-ml/ocamlnet/metadata.xml @@ -0,0 +1,12 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>ml@gentoo.org</email> + <name>Gentoo ML Project</name> + </maintainer> +<use> + <flag name="httpd">Enables net-httpd web server component</flag> + <flag name="zip">Enables netzip support to read/write gzip data using object channels</flag> +</use> +</pkgmetadata> diff --git a/dev-ml/ocamlnet/ocamlnet-4.1.2.ebuild b/dev-ml/ocamlnet/ocamlnet-4.1.2.ebuild new file mode 100644 index 000000000000..6d89e100f0ec --- /dev/null +++ b/dev-ml/ocamlnet/ocamlnet-4.1.2.ebuild @@ -0,0 +1,81 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="5" + +inherit eutils findlib + +MY_P=${P/_beta/test} +DESCRIPTION="Modules for OCaml application-level Internet protocols" +HOMEPAGE="http://projects.camlcity.org/projects/ocamlnet.html" +SRC_URI="http://download.camlcity.org/download/${MY_P}.tar.gz" + +LICENSE="ZLIB GPL-2+" +SLOT="0/${PV}" +KEYWORDS="amd64 ppc x86 x86-fbsd" +IUSE="gtk kerberos tk httpd +ocamlopt +pcre ssl zip" +RESTRICT="installsources" + +# the auth-dh compile flag has been disabled as well, since it depends on +# ocaml-cryptgps, which is not available. + +RDEPEND=">=dev-ml/findlib-1.0 + pcre? ( >=dev-ml/pcre-ocaml-5:= ) + >=dev-lang/ocaml-3.10.2:=[ocamlopt?] + tk? ( dev-ml/labltk:= ) + ssl? ( net-libs/gnutls:= ) + gtk? ( >=dev-ml/lablgtk-2:= ) + kerberos? ( virtual/krb5 ) + zip? ( dev-ml/camlzip:= ) + " +DEPEND="${RDEPEND} + virtual/pkgconfig +" + +S=${WORKDIR}/${MY_P} + +src_prepare() { + epatch "${FILESDIR}/ocaml405.patch" +} + +ocamlnet_use_with() { + if use $1; then + echo "-with-$2" + else + echo "-without-$2" + fi +} + +ocamlnet_use_enable() { + if use $1; then + echo "-enable-$2" + else + echo "-disable-$2" + fi +} + +src_configure() { + ./configure \ + -bindir /usr/bin \ + -datadir /usr/share/${PN} \ + $(ocamlnet_use_enable ssl gnutls) \ + $(ocamlnet_use_enable gtk gtk2) \ + $(ocamlnet_use_enable kerberos gssapi) \ + $(ocamlnet_use_enable pcre pcre) \ + $(ocamlnet_use_enable tk tcl) \ + $(ocamlnet_use_enable zip zip) \ + $(ocamlnet_use_with httpd nethttpd) \ + || die "Error : econf failed!" +} + +src_compile() { + emake -j1 all + if use ocamlopt; then + emake -j1 opt + fi +} + +src_install() { + export STRIP_MASK="*/bin/*" + findlib_src_install +} diff --git a/dev-ml/ocamlnet/ocamlnet-4.1.3.ebuild b/dev-ml/ocamlnet/ocamlnet-4.1.3.ebuild new file mode 100644 index 000000000000..1460d03f5cc4 --- /dev/null +++ b/dev-ml/ocamlnet/ocamlnet-4.1.3.ebuild @@ -0,0 +1,77 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="5" + +inherit eutils findlib + +MY_P=${P/_beta/test} +DESCRIPTION="Modules for OCaml application-level Internet protocols" +HOMEPAGE="http://projects.camlcity.org/projects/ocamlnet.html" +SRC_URI="http://download.camlcity.org/download/${MY_P}.tar.gz" + +LICENSE="ZLIB GPL-2+" +SLOT="0/${PV}" +KEYWORDS="~amd64 ~ppc ~x86 ~x86-fbsd" +IUSE="gtk kerberos tk httpd +ocamlopt +pcre ssl zip" +RESTRICT="installsources" + +# the auth-dh compile flag has been disabled as well, since it depends on +# ocaml-cryptgps, which is not available. + +RDEPEND=">=dev-ml/findlib-1.0 + pcre? ( >=dev-ml/pcre-ocaml-5:= ) + >=dev-lang/ocaml-3.10.2:=[ocamlopt?] + tk? ( dev-ml/labltk:= ) + ssl? ( net-libs/gnutls:= ) + gtk? ( >=dev-ml/lablgtk-2:= ) + kerberos? ( virtual/krb5 ) + zip? ( dev-ml/camlzip:= ) + " +DEPEND="${RDEPEND} + virtual/pkgconfig +" + +S=${WORKDIR}/${MY_P} + +ocamlnet_use_with() { + if use $1; then + echo "-with-$2" + else + echo "-without-$2" + fi +} + +ocamlnet_use_enable() { + if use $1; then + echo "-enable-$2" + else + echo "-disable-$2" + fi +} + +src_configure() { + ./configure \ + -bindir /usr/bin \ + -datadir /usr/share/${PN} \ + $(ocamlnet_use_enable ssl gnutls) \ + $(ocamlnet_use_enable gtk gtk2) \ + $(ocamlnet_use_enable kerberos gssapi) \ + $(ocamlnet_use_enable pcre pcre) \ + $(ocamlnet_use_enable tk tcl) \ + $(ocamlnet_use_enable zip zip) \ + $(ocamlnet_use_with httpd nethttpd) \ + || die "Error : econf failed!" +} + +src_compile() { + emake -j1 all + if use ocamlopt; then + emake -j1 opt + fi +} + +src_install() { + export STRIP_MASK="*/bin/*" + findlib_src_install +} diff --git a/dev-ml/ocamlnet/ocamlnet-4.1.4.ebuild b/dev-ml/ocamlnet/ocamlnet-4.1.4.ebuild new file mode 100644 index 000000000000..1460d03f5cc4 --- /dev/null +++ b/dev-ml/ocamlnet/ocamlnet-4.1.4.ebuild @@ -0,0 +1,77 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="5" + +inherit eutils findlib + +MY_P=${P/_beta/test} +DESCRIPTION="Modules for OCaml application-level Internet protocols" +HOMEPAGE="http://projects.camlcity.org/projects/ocamlnet.html" +SRC_URI="http://download.camlcity.org/download/${MY_P}.tar.gz" + +LICENSE="ZLIB GPL-2+" +SLOT="0/${PV}" +KEYWORDS="~amd64 ~ppc ~x86 ~x86-fbsd" +IUSE="gtk kerberos tk httpd +ocamlopt +pcre ssl zip" +RESTRICT="installsources" + +# the auth-dh compile flag has been disabled as well, since it depends on +# ocaml-cryptgps, which is not available. + +RDEPEND=">=dev-ml/findlib-1.0 + pcre? ( >=dev-ml/pcre-ocaml-5:= ) + >=dev-lang/ocaml-3.10.2:=[ocamlopt?] + tk? ( dev-ml/labltk:= ) + ssl? ( net-libs/gnutls:= ) + gtk? ( >=dev-ml/lablgtk-2:= ) + kerberos? ( virtual/krb5 ) + zip? ( dev-ml/camlzip:= ) + " +DEPEND="${RDEPEND} + virtual/pkgconfig +" + +S=${WORKDIR}/${MY_P} + +ocamlnet_use_with() { + if use $1; then + echo "-with-$2" + else + echo "-without-$2" + fi +} + +ocamlnet_use_enable() { + if use $1; then + echo "-enable-$2" + else + echo "-disable-$2" + fi +} + +src_configure() { + ./configure \ + -bindir /usr/bin \ + -datadir /usr/share/${PN} \ + $(ocamlnet_use_enable ssl gnutls) \ + $(ocamlnet_use_enable gtk gtk2) \ + $(ocamlnet_use_enable kerberos gssapi) \ + $(ocamlnet_use_enable pcre pcre) \ + $(ocamlnet_use_enable tk tcl) \ + $(ocamlnet_use_enable zip zip) \ + $(ocamlnet_use_with httpd nethttpd) \ + || die "Error : econf failed!" +} + +src_compile() { + emake -j1 all + if use ocamlopt; then + emake -j1 opt + fi +} + +src_install() { + export STRIP_MASK="*/bin/*" + findlib_src_install +} |