aboutsummaryrefslogtreecommitdiff
path: root/devel/p5-Java
diff options
context:
space:
mode:
authorAaron Dalton <aaron@FreeBSD.org>2006-06-02 23:40:27 +0000
committerAaron Dalton <aaron@FreeBSD.org>2006-06-02 23:40:27 +0000
commitf2b7c59aa2a2aafc226eecc3cf7c1d66c34d1909 (patch)
tree3029b696aa3ebbde8ae92097da04ffe4f4c0889e /devel/p5-Java
parentd1d963b937ed5f7ba8f4f3cb90fe3048aa56600c (diff)
downloadports-f2b7c59aa2a2aafc226eecc3cf7c1d66c34d1909.tar.gz
ports-f2b7c59aa2a2aafc226eecc3cf7c1d66c34d1909.zip
Notes
Diffstat (limited to 'devel/p5-Java')
-rw-r--r--devel/p5-Java/Makefile32
-rw-r--r--devel/p5-Java/distinfo3
-rw-r--r--devel/p5-Java/files/javaserver.sh.in51
-rw-r--r--devel/p5-Java/files/patch-MANIFEST10
-rw-r--r--devel/p5-Java/files/patch-Makefile.PL10
-rw-r--r--devel/p5-Java/pkg-descr4
-rw-r--r--devel/p5-Java/pkg-plist7
7 files changed, 117 insertions, 0 deletions
diff --git a/devel/p5-Java/Makefile b/devel/p5-Java/Makefile
new file mode 100644
index 000000000000..fcfa4e85612b
--- /dev/null
+++ b/devel/p5-Java/Makefile
@@ -0,0 +1,32 @@
+# New ports collection makefile for: Java
+# Date Created: 27 January 2006
+# Whom: Simun Mikecin <numisemis@yahoo.com>
+#
+# $FreeBSD$
+#
+
+PORTNAME= Java
+PORTVERSION= 4.7
+CATEGORIES= devel java
+MASTER_SITES= ${MASTER_SITE_PERL_CPAN}
+MASTER_SITE_SUBDIR=Java
+PKGNAMEPREFIX= p5-
+
+MAINTAINER= numisemis@yahoo.com
+COMMENT= Perl extension for accessing a JVM remotely or locally
+
+USE_RC_SUBR= javaserver.sh
+PERL_CONFIGURE= YES
+USE_JAVA= yes
+JAVA_VERSION= 1.1+
+
+MAN3= Java.3 JavaArray.3
+
+post-patch:
+ ${RM} ${WRKSRC}/java_server_install.pl
+
+post-install:
+ ${MKDIR} ${PREFIX}/share/p5-Java
+ ${INSTALL_DATA} ${WRKSRC}/JavaServer.jar ${PREFIX}/share/p5-Java
+
+.include <bsd.port.mk>
diff --git a/devel/p5-Java/distinfo b/devel/p5-Java/distinfo
new file mode 100644
index 000000000000..d83304eed796
--- /dev/null
+++ b/devel/p5-Java/distinfo
@@ -0,0 +1,3 @@
+MD5 (Java-4.7.tar.gz) = 5ff244b864455b9f004f627b29bc6a4e
+SHA256 (Java-4.7.tar.gz) = 39986f7daf28bec4ac467ffb143f526c2f7e3b855b8f2994fd51b50fe85fc5cd
+SIZE (Java-4.7.tar.gz) = 69671
diff --git a/devel/p5-Java/files/javaserver.sh.in b/devel/p5-Java/files/javaserver.sh.in
new file mode 100644
index 000000000000..5157c42acf38
--- /dev/null
+++ b/devel/p5-Java/files/javaserver.sh.in
@@ -0,0 +1,51 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+
+# PROVIDE: javaserver
+# REQUIRE: NETWORKING SERVERS
+# BEFORE: DAEMON
+# KEYWORD: FreeBSD shutdown
+
+#
+# Add the following lines to /etc/rc.conf to enable javaserver:
+# javaserver_enable (bool): Set to "NO" by default.
+# Set it to "YES" to enable apache22
+# javaserver_classpath (str): Set to "" by default.
+# Define your classpath here.
+# javaserver_user (str): Set to "nobody" by default.
+# Define owner of the javaserver process.
+
+. %%RC_SUBR%%
+
+name="javaserver"
+rcvar=`set_rcvar`
+
+load_rc_config $name
+
+start_cmd="${name}_start"
+stop_cmd="${name}_stop"
+pidfile="/var/run/${name}.pid"
+classpath="%%PREFIX%%"/share/p5-Java/JavaServer.jar
+
+[ -z "$javaserver_classpath" ] || classpath="${javaserver_classpath}":$classpath
+[ -z "$javaserver_enable" ] && javaserver_enable="NO"
+[ -z "$javaserver_user" ] && javaserver_user="nobody"
+
+javaserver_start()
+{
+ su -m ${javaserver_user} -c "nohup %%PREFIX%%/bin/java -cp ${classpath} com.zzo.javaserver.JavaServer >/dev/null & ; echo \$! " | tail -1 > ${pidfile}
+}
+
+javaserver_stop()
+{
+ if [ -f ${pidfile} ]; then
+ rc_pid=`cat ${pidfile}`
+ kill -TERM $rc_pid
+ wait_for_pids $rc_pid
+ rm ${pidfile}
+ fi
+}
+
+run_rc_command "$1"
diff --git a/devel/p5-Java/files/patch-MANIFEST b/devel/p5-Java/files/patch-MANIFEST
new file mode 100644
index 000000000000..72dceb82d9e8
--- /dev/null
+++ b/devel/p5-Java/files/patch-MANIFEST
@@ -0,0 +1,10 @@
+--- MANIFEST.orig Sat Jan 28 13:53:39 2006
++++ MANIFEST Sat Jan 28 13:53:39 2006
+@@ -6,7 +6,6 @@
+ Makefile.PL
+ README
+ TODO
+-java_server_install.pl
+ test.pl
+ examples/array.pl
+ examples/byte.pl
diff --git a/devel/p5-Java/files/patch-Makefile.PL b/devel/p5-Java/files/patch-Makefile.PL
new file mode 100644
index 000000000000..7309f8c853f0
--- /dev/null
+++ b/devel/p5-Java/files/patch-Makefile.PL
@@ -0,0 +1,10 @@
+--- Makefile.PL.orig Mon Nov 17 23:08:07 2003
++++ Makefile.PL Fri Jan 27 21:25:46 2006
+@@ -5,7 +5,4 @@
+ 'NAME' => 'Java',
+ 'VERSION_FROM' => 'Java.pm', # finds $VERSION
+ 'PREREQ_PM' => {}, # e.g., Module::Name => 1.1
+- 'PPM_INSTALL_EXEC' => 'perl',
+- 'PPM_INSTALL_SCRIPT'=> 'java_server_install.pl',
+- 'EXE_FILES' => ['java_server_install.pl'],
+ );
diff --git a/devel/p5-Java/pkg-descr b/devel/p5-Java/pkg-descr
new file mode 100644
index 000000000000..0709d398e912
--- /dev/null
+++ b/devel/p5-Java/pkg-descr
@@ -0,0 +1,4 @@
+Perl extension for accessing a JVM remotely or locally
+
+- Simun Mikecin
+numisemis@yahoo.com
diff --git a/devel/p5-Java/pkg-plist b/devel/p5-Java/pkg-plist
new file mode 100644
index 000000000000..a57edf135768
--- /dev/null
+++ b/devel/p5-Java/pkg-plist
@@ -0,0 +1,7 @@
+%%SITE_PERL%%/Java.pm
+%%SITE_PERL%%/JavaArray.pm
+%%SITE_PERL%%/%%PERL_ARCH%%/auto/Java/.packlist
+@exec mkdir -p %/share/p5-Java
+share/p5-Java/JavaServer.jar
+@dirrm share/p5-Java
+@dirrmtry %%SITE_PERL%%/%%PERL_ARCH%%/auto/Java