diff options
Diffstat (limited to 'dev-java/rxtx')
-rw-r--r-- | dev-java/rxtx/Manifest | 11 | ||||
-rw-r--r-- | dev-java/rxtx/files/lockfiled.xinetd | 13 | ||||
-rw-r--r-- | dev-java/rxtx/files/rxtx-2.1-7r2-lfd.diff | 14 | ||||
-rw-r--r-- | dev-java/rxtx/files/rxtx-2.1-7r2-nouts.diff | 90 | ||||
-rw-r--r-- | dev-java/rxtx/files/rxtx-2.2_pre2-add-ttyACM.patch | 10 | ||||
-rw-r--r-- | dev-java/rxtx/files/rxtx-2.2_pre2-limits.patch | 10 | ||||
-rw-r--r-- | dev-java/rxtx/metadata.xml | 11 | ||||
-rw-r--r-- | dev-java/rxtx/rxtx-2.2_pre2-r1.ebuild | 101 | ||||
-rw-r--r-- | dev-java/rxtx/rxtx-2.2_pre2.ebuild | 101 |
9 files changed, 361 insertions, 0 deletions
diff --git a/dev-java/rxtx/Manifest b/dev-java/rxtx/Manifest new file mode 100644 index 000000000000..f5149e37e9bb --- /dev/null +++ b/dev-java/rxtx/Manifest @@ -0,0 +1,11 @@ +AUX lockfiled.xinetd 202 SHA256 5016c083c1eee98483e16187b79e762db43b50b4177c7420196a91ed64bfe940 SHA512 5ad71db04f2cc44348572876079b9548a3aafb84aa53aa6f6d422468c54911cc149cae94743d86eaf7dc62a1cc1479b95893dfa0909367778f20e1ad72b99fea WHIRLPOOL c894b61844caa86d457b6d272be40f8ee937e0a93b8248d5a7d2854c3cb532e467dbcda7520644a3c24f663f4e1342fd9dc2066751e1adcd587eb951bf1c7ac9 +AUX rxtx-2.1-7r2-lfd.diff 497 SHA256 83bedeb80858fa7671c102cca3d8f95e59046a081f9da1213efafacd0371322b SHA512 fd06c021ad496036556f979e783864d6d88d1a0c039396eefacc569d66e6942b08b246970be640c73c0c2d209aa0c3247db61bdc19a99066789d4f4d0e4d390e WHIRLPOOL 7cdbf784881b0bb0ad8f763cd18e5ab28c2ffffd613c2c9f4442c74b70bf9dea792b46675e1e245e66ce4d2f7731b3e30c5a972569607a54a12c5d516eee14eb +AUX rxtx-2.1-7r2-nouts.diff 3583 SHA256 bdea39bd623d71ebffd0412476f7b9cd680c7e61ab546bda06dfa517bf175faf SHA512 c7c6c11785089d321ee9680f4b67c590fe0c3cc0f031196eb71831ef7f319867fb156912c0c934a751d5d9e97774d6c26cab5c710055e919e97bcf39a789787d WHIRLPOOL b1833639e1aa63ec3c27980db0dd51d57b307af715b8fdcb7632fdb22db4c7f94868bf351287a8b21000299edaef065add8636ab8ded9baa3ac276caa629ca4f +AUX rxtx-2.2_pre2-add-ttyACM.patch 328 SHA256 81263de05372827743ba3373dc43190494defebee390dd91a24ad4d68aaae699 SHA512 c81ae4e3f6fe09722709b6a9ae09fd3a300c9ef94641a3aa9f821b6fd4e4c28f15e9f672d2bfe6b51715f9e6b2caa5f637be20a76027cb31098062f60a0b0d0f WHIRLPOOL 6a7cac82b92b84bc07f7e95ac9c6b763382790eb0e30f1a866a31d4b7e50619582b037e5a58f9242031e5e52fd83c07c5833c8672e48b85c5b2ae2fe6e257bf6 +AUX rxtx-2.2_pre2-limits.patch 272 SHA256 1a0a0a21744ef3845f6aab19d24d6a31f3ca3e84654ae7cac4bca65f7c7d15a6 SHA512 0e4d5b8e622515c75613aeb8c5e4fc1786f1c05ef2619b65c4b1060776933172479957b9f9a15195c79f10c90a1802956eac32cd60939b9b0a15540901e62180 WHIRLPOOL a94f77f91d060e05cf222cb3e5c63dc6e97747c37afc5929e26e35950acd6d89937aae64c4c3975615a621a91cae84baf324794030c93a16f89c83570c5f7b1f +DIST rxtx-2.2pre2.zip 1491209 SHA256 3c30373e760f444def3650c76c5a00ae12fb1d860ec008750d084f4880495b03 SHA512 cd94bd08bc8b5689fc9a0e539f17645f530a3a280998e9838a2e4c8b3386f2b00a592ab41c07bd720eadf26fddb324bf80d8f7b9ecb35ea8507120c16048f514 WHIRLPOOL 0c2893c016ae99f918ca3605c83d18ec2b9ea0022628562a36859eaa20001ce6cfa15d7e77b80ee32e259f162ee1512b026a9965ec1402ae35ebed4b473796fc +EBUILD rxtx-2.2_pre2-r1.ebuild 2227 SHA256 120a2d718e31212f05c7a59c5889451363730d8f0555e92009eb65492838846b SHA512 4a97e69b8601c3ec5ced216f3236c5e564fe2edc91f813ac0a620bd602b07bbc15d471c6f10c3d05d4a6720e12d914d0236e228723ad74f607f7a46dec6e6c1d WHIRLPOOL 40c69246300593e8d15aaf181dbd9eeea364eac900de77ea2eef54ac0e2e15f37de7ed7b83ad4f18c5efda8413bd9b7d49fd20b1eda03f78fb841a2d2aa03926 +EBUILD rxtx-2.2_pre2.ebuild 2300 SHA256 eb3156f366668bee8670163a97c325a066d2b9b95827a0b7847c801c78bbd954 SHA512 04eea992fa9f8553ecd4fa8eef777db949996bfae176ed8f23e575034d334c1eff3ebb783452899edefbabae459ac04e5c59ca41fadb78ff530ce90d4191ed70 WHIRLPOOL 19ec78ec5bc531548273b97753847a052b9ecbc699c537ab9dc23d8e62549eb5dc44274f4327d1a36ba307e592ba131cfd3c82eb3b607f374f49e9e1c8cf5538 +MISC ChangeLog 3469 SHA256 3dfb6d1e399186ea1b85e8b5dd4ae2d0eb4cdb0fee4f4c0a1e89d12c3357dd43 SHA512 d4f1f9c6e88badd13e29780f6c602d7be1f4bcf3b05945ce13f8ab11ca7c6daf0dbc1da95ea8cc3d658893b7e792c3c4d805b380cc6b2fcfe66cbbd553f27cac WHIRLPOOL 6a734239805c0086242ce66acf0317a11a2e88bd7fe157a1a9915cf1c12a53e8ae8a58d22087982facafaf34ecce3610237e273ab34b9b681af0d5fcc320af86 +MISC ChangeLog-2015 3520 SHA256 d7968e045b80c0267ff3d1c06460b5525b1af7b279a38351f231b532d4c75375 SHA512 56862b254bcb5d5d465ab8871f111a30045d5299249a82b09a410ead095ac3e2bb32fcdc75740ec169c16f60ecb5a37df4f4da980415a9d9c51fe287a1ee65b1 WHIRLPOOL a57d555bc6b554f20e5d8ba7b4f78fe3579cdc9183e713a014d2ed6f3b1e5a32c5041b8ec3416eca3a501c33703d7abbc46afc10d6712988fcf705dd5327600f +MISC metadata.xml 333 SHA256 b69834e25b6815850f05fccd906a66aabc268f68ddbe0dad15e31c48b9716835 SHA512 fa687c6a61c8be4e5b80f14b9eb6ef7637f9de649e3c35dd81f81096c1bbafe67ee5979c551d958422fdbff1ebb08b43a1630d9cbdf283e56c4ea5aca1cd3ac7 WHIRLPOOL e167e62beb5ed8195b7b5aa7602794d630de426c34cd0daa21805e1b5de7c9744a12e5d75855cd5167018bf59e98130248b91f896846cb6495a471f42d3c1430 diff --git a/dev-java/rxtx/files/lockfiled.xinetd b/dev-java/rxtx/files/lockfiled.xinetd new file mode 100644 index 000000000000..8d6e95a5e444 --- /dev/null +++ b/dev-java/rxtx/files/lockfiled.xinetd @@ -0,0 +1,13 @@ +service lfd +{ + port = 50001 + bind = localhost + type = UNLISTED + flags = REUSE + socket_type = stream + wait = no + user = uucp + server = /usr/sbin/in.lfd + log_on_failure += USERID + disable = yes +} diff --git a/dev-java/rxtx/files/rxtx-2.1-7r2-lfd.diff b/dev-java/rxtx/files/rxtx-2.1-7r2-lfd.diff new file mode 100644 index 000000000000..496d732ae2fa --- /dev/null +++ b/dev-java/rxtx/files/rxtx-2.1-7r2-lfd.diff @@ -0,0 +1,14 @@ +--- src/lfd/lockdaemon.c.orig 2004-10-12 10:59:28.000000000 +0200 ++++ src/lfd/lockdaemon.c 2006-10-29 22:46:58.000000000 +0100 +@@ -248,9 +248,8 @@ + + if ( check_group_uucp() ) + { +- syslog( LOG_INFO, "check_lock_status: No permission to create lock file. +- +- please see: How can I use Lock Files with rxtx? in INSTALL\n" ); ++ syslog( LOG_INFO, "check_lock_status: No permission to create lock file.\n\n" ++ "please see: How can I use Lock Files with rxtx? in INSTALL\n" ); + return 1; + } + diff --git a/dev-java/rxtx/files/rxtx-2.1-7r2-nouts.diff b/dev-java/rxtx/files/rxtx-2.1-7r2-nouts.diff new file mode 100644 index 000000000000..fb05955c65f1 --- /dev/null +++ b/dev-java/rxtx/files/rxtx-2.1-7r2-nouts.diff @@ -0,0 +1,90 @@ +--- src/I2CImp.c.orig 2004-10-17 16:23:02.000000000 +0200 ++++ src/I2CImp.c 2006-10-26 21:25:32.000000000 +0200 +@@ -87,6 +87,7 @@ + if( !handler.sa_handler ) signal( SIGIO, SIG_IGN ); + #endif /* !__FreeBSD__ */ + #if defined(__linux__) ++#if 0 + /* Lets let people who upgraded kernels know they may have problems */ + if (uname (&name) == -1) + { +@@ -98,6 +99,7 @@ + fprintf(stderr, "\n\n\nRXTX WARNING: This library was compiled to run with OS release %s and you are currently running OS release %s. In some cases this can be a problem. Try recompiling RXTX if you notice strange behavior. If you just compiled RXTX make sure /usr/include/linux is a symbolic link to the include files that came with the kernel source and not an older copy.\n\n\npress enter to continue\n",UTS_RELEASE,name.release); + getchar(); + } ++#endif + #endif /* __linux__ */ + #endif /* WIN32 */ + } +--- src/RawImp.c.orig 2004-10-16 18:20:35.000000000 +0200 ++++ src/RawImp.c 2006-10-26 21:25:59.000000000 +0200 +@@ -231,6 +231,7 @@ + if( !handler.sa_handler ) signal( SIGIO, SIG_IGN ); + #endif /* !__FreeBSD__ */ + #if defined(__linux__) ++#if 0 + /* Lets let people who upgraded kernels know they may have problems */ + if (uname (&name) == -1) + { +@@ -242,6 +243,7 @@ + fprintf(stderr, "\n\n\nRXTX WARNING: This library was compiled to run with OS release %s and you are currently running OS release %s. In some cases this can be a problem. Try recompiling RXTX if you notice strange behavior. If you just compiled RXTX make sure /usr/include/linux is a symbolic link to the include files that came with the kernel source and not an older copy.\n\n\npress enter to continue\n",UTS_RELEASE,name.release); + getchar(); + } ++#endif + #endif /* __linux__ */ + #endif /* WIN32 */ + } +--- src/RS485Imp.c.orig 2004-10-16 18:20:35.000000000 +0200 ++++ src/RS485Imp.c 2006-10-26 21:26:23.000000000 +0200 +@@ -87,6 +87,7 @@ + if( !handler.sa_handler ) signal( SIGIO, SIG_IGN ); + #endif /* !__FreeBSD__ */ + #if defined(__linux__) ++#if 0 + /* Lets let people who upgraded kernels know they may have problems */ + if (uname (&name) == -1) + { +@@ -98,6 +99,7 @@ + fprintf(stderr, "\n\n\nRXTX WARNING: This library was compiled to run with OS release %s and you are currently running OS release %s. In some cases this can be a problem. Try recompiling RXTX if you notice strange behavior. If you just compiled RXTX make sure /usr/include/linux is a symbolic link to the include files that came with the kernel source and not an older copy.\n\n\npress enter to continue\n",UTS_RELEASE,name.release); + getchar(); + } ++#endif + #endif /* __linux__ */ + #endif /* WIN32 */ + } +--- src/SerialImp.c.orig 2006-01-29 23:19:04.000000000 +0100 ++++ src/SerialImp.c 2006-10-26 21:26:59.000000000 +0200 +@@ -280,6 +280,7 @@ + gettimeofday(&seloop, NULL); + #endif /* DEBUG_TIMING */ + #if defined(DEBUG) && defined(__linux__) ++#if 0 + /* Lets let people who upgraded kernels know they may have problems */ + if (uname (&name) == -1) + { +@@ -295,6 +296,7 @@ + getchar(); + } + LEAVE( "RXTXPort:Initialize" ); ++#endif + #endif /* DEBUG && __linux__ */ + } + +--- src/SerialImp.cpp.orig 2004-10-12 10:59:27.000000000 +0200 ++++ src/SerialImp.cpp 2006-10-26 21:27:44.000000000 +0200 +@@ -102,6 +102,7 @@ + if( !handler.sa_handler ) signal( SIGIO, SIG_IGN ); + #endif /* !__FreeBSD__ */ + #ifdef DEBUG ++#if 0 + /* Lets let people who upgraded kernels know they may have problems */ + if (uname (&name) == -1) + { +@@ -114,6 +115,7 @@ + name.release); + getchar(); + } ++#endif + #endif /* DEBUG */ + #endif /* __BEOS__ */ + #endif /* WIN32 */ diff --git a/dev-java/rxtx/files/rxtx-2.2_pre2-add-ttyACM.patch b/dev-java/rxtx/files/rxtx-2.2_pre2-add-ttyACM.patch new file mode 100644 index 000000000000..ac3a0a9dbee5 --- /dev/null +++ b/dev-java/rxtx/files/rxtx-2.2_pre2-add-ttyACM.patch @@ -0,0 +1,10 @@ +--- rxtx-2.2pre2/src/gnu/io/RXTXCommDriver.java.orig ++++ rxtx-2.2pre2/src/gnu/io/RXTXCommDriver.java +@@ -574,6 +574,7 @@ + if(osName.equals("Linux")) + { + String[] Temp = { ++ "ttyACM", // linux USB modems + "ttyS", // linux Serial Ports + "ttySA", // for the IPAQs + "ttyUSB", // for USB frobs diff --git a/dev-java/rxtx/files/rxtx-2.2_pre2-limits.patch b/dev-java/rxtx/files/rxtx-2.2_pre2-limits.patch new file mode 100644 index 000000000000..1e4ff4af57b7 --- /dev/null +++ b/dev-java/rxtx/files/rxtx-2.2_pre2-limits.patch @@ -0,0 +1,10 @@ +--- src/lfd/lockdaemon.c.orig 2007-04-26 06:26:07.000000000 +0100 ++++ src/lfd/lockdaemon.c 2016-02-17 20:41:09.137509089 +0000 +@@ -69,6 +69,7 @@ + #include <errno.h> + #include <signal.h> + #include <pwd.h> ++#include <limits.h> + + #define FHS + #define LOCKFILEPREFIX "LCK.." diff --git a/dev-java/rxtx/metadata.xml b/dev-java/rxtx/metadata.xml new file mode 100644 index 000000000000..fc99089425fa --- /dev/null +++ b/dev-java/rxtx/metadata.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>java@gentoo.org</email> + <name>Java</name> + </maintainer> + <use> + <flag name="lfd">Installs and uses LockFileServer daemon (lfd)</flag> + </use> +</pkgmetadata> diff --git a/dev-java/rxtx/rxtx-2.2_pre2-r1.ebuild b/dev-java/rxtx/rxtx-2.2_pre2-r1.ebuild new file mode 100644 index 000000000000..4a59306f198f --- /dev/null +++ b/dev-java/rxtx/rxtx-2.2_pre2-r1.ebuild @@ -0,0 +1,101 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 + +JAVA_PKG_IUSE="doc source" + +inherit toolchain-funcs versionator autotools java-pkg-2 + +MY_PV="$(delete_version_separator 2)" +MY_P="${PN}-${MY_PV}" + +DESCRIPTION="Native lib providing serial and parallel communication for Java" +HOMEPAGE="http://rxtx.qbang.org/" +SRC_URI="ftp://ftp.qbang.org/pub/rxtx/${MY_P}.zip" +LICENSE="LGPL-2.1+" +SLOT="2" +KEYWORDS="~amd64 ~x86" +IUSE="lfd" + +RDEPEND=">=virtual/jre-1.6 + lfd? ( sys-apps/xinetd )" + +DEPEND=">=virtual/jdk-1.6 + app-arch/unzip" + +S="${WORKDIR}/${MY_P}" + +src_prepare() { + sed -i -e "s:\(\$(JAVADOC)\):\1 -d api:g" Makefile.am || die + sed -i \ + -e "s:UTS_RELEASE::g" \ + -e "s:AM_CONFIG_HEADER:AC_CONFIG_HEADERS:g" \ + -e "s:-source ... -target ...:$(java-pkg_javac-args):g" \ + configure.in || die + + epatch \ + "${FILESDIR}/${PN}-2.1-7r2-lfd.diff" \ + "${FILESDIR}/${PN}-2.1-7r2-nouts.diff" \ + "${FILESDIR}/${P}-add-ttyACM.patch" \ + "${FILESDIR}/${P}-limits.patch" + + rm acinclude.m4 || die + eautoreconf +} + +src_configure() { + econf \ + $(use_enable lfd lockfile_server) +} + +src_compile() { + emake + + if use lfd ; then + # see INSTALL in src/ldf + $(tc-getCC) ${LDFLAGS} ${CFLAGS} src/lfd/lockdaemon.c -o src/lfd/in.lfd || die + fi + + if use doc ; then + emake docs + fi + + # Fix for src zip creation + if use source ; then + mkdir -p src_with_pkg/gnu || die + ln -s ../../src src_with_pkg/gnu/io || die + fi +} + +src_install() { + java-pkg_dojar RXTXcomm.jar + java-pkg_doso ${CHOST}/.libs/*.so + + dodoc AUTHORS ChangeLog INSTALL PORTING TODO SerialPortInstructions.txt + docinto html + dodoc RMISecurityManager.html + + if use lfd ; then + insinto /etc/xinetd.d + newins "${FILESDIR}/lockfiled.xinetd" lfd + dosbin src/lfd/in.lfd + dodoc src/lfd/LockFileServer.rfc + fi + + use doc && java-pkg_dojavadoc api + use source && java-pkg_dosrc src_with_pkg/gnu +} + +pkg_postinst() { + if use lfd ; then + elog "Don't forget to enable the LockFileServer" + elog "daemon (lfd) in /etc/xinetd.d/lfd" + else + elog "RXTX uses UUCP style device-locks. You should" + elog "add every user who needs to access serial ports" + elog "to the 'uucp' group:" + elog + elog " usermod -aG uucp <user>" + fi +} diff --git a/dev-java/rxtx/rxtx-2.2_pre2.ebuild b/dev-java/rxtx/rxtx-2.2_pre2.ebuild new file mode 100644 index 000000000000..906a1b6e0471 --- /dev/null +++ b/dev-java/rxtx/rxtx-2.2_pre2.ebuild @@ -0,0 +1,101 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="4" + +inherit toolchain-funcs versionator autotools java-pkg-2 + +MY_PV="$(delete_version_separator 2)" +MY_P="${PN}-${MY_PV}" + +DESCRIPTION="Native lib providing serial and parallel communication for Java" +HOMEPAGE="http://rxtx.qbang.org/" +SRC_URI="ftp://ftp.qbang.org/pub/rxtx/${MY_P}.zip" + +LICENSE="LGPL-2" +SLOT="2" +KEYWORDS="amd64 x86" +IUSE="doc source lfd" + +RDEPEND=">=virtual/jre-1.4" + +DEPEND=">=virtual/jdk-1.4 + app-arch/unzip + dev-java/ant-core + lfd? ( sys-apps/xinetd ) + source? ( app-arch/zip )" + +S="${WORKDIR}/${MY_P}" + +src_prepare() { + # some minor fixes + sed -i -e "s:UTS_RELEASE::g" configure.in || die + sed -i -e "s:|1.5\*:|1.5*|1.6*|1.7*:g" configure.in || die + sed -i -e "s:AM_CONFIG_HEADER:AC_CONFIG_HEADERS:g" configure.in || die + sed -i -e "s:\(\$(JAVADOC)\):\1 -d api:g" Makefile.am || die + + # some patches + epatch "${FILESDIR}/${PN}-2.1-7r2-lfd.diff" + epatch "${FILESDIR}/${PN}-2.1-7r2-nouts.diff" + epatch "${FILESDIR}/${P}-add-ttyACM.patch" + + # update autotools stuff + rm acinclude.m4 + eautoreconf + elibtoolize +} + +src_configure() { + econf \ + $(use_enable lfd lockfile_server) +} + +src_compile() { + emake + + if use lfd ; then + # see INSTALL in src/ldf + $(tc-getCC) ${LDFLAGS} ${CFLAGS} src/lfd/lockdaemon.c -o src/lfd/in.lfd || die "compiling lfd failed" + fi + + if use doc ; then + emake docs + fi + + #Fix for src zip creation + if use source ; then + mkdir -p src_with_pkg/gnu + ln -s ../../src src_with_pkg/gnu/io + fi +} + +src_install() { + java-pkg_dojar RXTXcomm.jar + java-pkg_doso ${CHOST}/.libs/*.so + + dodoc AUTHORS ChangeLog INSTALL PORTING TODO SerialPortInstructions.txt + dohtml RMISecurityManager.html + + if use lfd ; then + insinto /etc/xinetd.d + newins "${FILESDIR}/lockfiled.xinetd" lfd + dosbin src/lfd/in.lfd + dodoc src/lfd/LockFileServer.rfc + fi + + use doc && java-pkg_dojavadoc api + use source && java-pkg_dosrc src_with_pkg/gnu +} + +pkg_postinst() { + if use lfd ; then + elog "Don't forget to enable the LockFileServer" + elog "daemon (lfd) in /etc/xinetd.d/lfd" + else + elog "RXTX uses UUCP style device-locks. You should" + elog "add every user who needs to access serial ports" + elog "to the 'uucp' group:" + elog + elog " usermod -aG uucp <user>" + fi +} |