summaryrefslogtreecommitdiff
path: root/java/jboss4/files
diff options
context:
space:
mode:
authorPav Lucistnik <pav@FreeBSD.org>2007-07-29 19:44:05 +0000
committerPav Lucistnik <pav@FreeBSD.org>2007-07-29 19:44:05 +0000
commitd43eee908f23c5759f3d360d54967302618ac664 (patch)
tree3d70a1843159f4f3dc0a108a4805bd28c38863df /java/jboss4/files
parent- Upgrade to 0.7.5 (diff)
- Update to 4.2.0.GA2
PR: ports/113844 Submitted by: Jonathan Chen <jonc@chen.org.nz> (maintainer)
Notes
Notes: svn path=/head/; revision=196641
Diffstat (limited to 'java/jboss4/files')
-rw-r--r--java/jboss4/files/daemonctl.1.in (renamed from java/jboss4/files/daemonctl.1)0
-rw-r--r--java/jboss4/files/daemonctl.c.in (renamed from java/jboss4/files/daemonctl.c)2
-rw-r--r--java/jboss4/files/jboss4.in (renamed from java/jboss4/files/startup.sh)3
-rw-r--r--java/jboss4/files/patch-ant-build45
-rw-r--r--java/jboss4/files/pkg-deinstall.in35
-rw-r--r--java/jboss4/files/pkg-install.in46
-rw-r--r--java/jboss4/files/pkg-message.in (renamed from java/jboss4/files/pkg-message)0
7 files changed, 129 insertions, 2 deletions
diff --git a/java/jboss4/files/daemonctl.1 b/java/jboss4/files/daemonctl.1.in
index 30547f449ef9..30547f449ef9 100644
--- a/java/jboss4/files/daemonctl.1
+++ b/java/jboss4/files/daemonctl.1.in
diff --git a/java/jboss4/files/daemonctl.c b/java/jboss4/files/daemonctl.c.in
index d5f67318b7cf..7bcdc6b7f5e8 100644
--- a/java/jboss4/files/daemonctl.c
+++ b/java/jboss4/files/daemonctl.c.in
@@ -7,7 +7,7 @@
* Original by Ernst de Haan <znerd@freebsd.org>
* www/jakarta-tomcat4/files/daemonctl.c
*
- * $FreeBSD: /tmp/pcvs/ports/java/jboss4/files/Attic/daemonctl.c,v 1.3 2004-12-22 20:44:23 hq Exp $
+ * $FreeBSD$
*/
#include <assert.h>
diff --git a/java/jboss4/files/startup.sh b/java/jboss4/files/jboss4.in
index be7cff4ca2c7..4bcb6d3fd8a2 100644
--- a/java/jboss4/files/startup.sh
+++ b/java/jboss4/files/jboss4.in
@@ -2,11 +2,12 @@
#
# %%APP_TITLE%% startup script.
#
-# $FreeBSD: /tmp/pcvs/ports/java/jboss4/files/Attic/startup.sh,v 1.4 2006-06-13 17:43:14 glewis Exp $
+# $FreeBSD$
#
# PROVIDE: %%APP_SHORTNAME%%
# REQUIRE: NETWORKING SERVERS
+# KEYWORD: shutdown
# Add the following lines to /etc/rc.conf to enable %%APP_SHORTNAME%%:
# %%APP_SHORTNAME%%_enable (bool): Set to "NO" by default.
diff --git a/java/jboss4/files/patch-ant-build b/java/jboss4/files/patch-ant-build
new file mode 100644
index 000000000000..9098b48f6520
--- /dev/null
+++ b/java/jboss4/files/patch-ant-build
@@ -0,0 +1,45 @@
+$FreeBSD$
+
+These patches disables the ant version checks.
+
+diff -ruN /tmp/jboss-4.2.0.GA-src/tools/etc/buildmagic/build-common.xml ./tools/etc/buildmagic/build-common.xml
+--- /tmp/jboss-4.2.0.GA-src/tools/etc/buildmagic/build-common.xml Sat May 12 06:24:27 2007
++++ ./tools/etc/buildmagic/build-common.xml Tue Jun 19 13:56:11 2007
+@@ -9,10 +9,12 @@
+ -->
+
+ <condition property="buildmagic.ant.compatible">
++ <!--
+ <or>
+ <contains string="${ant.version}"
+ substring="Ant version ${buildmagic.ant16.baseversion}"/>
+ </or>
++ -->
+ </condition>
+
+ <fail unless="buildmagic.ant.compatible">
+diff -ruN /tmp/jboss-4.2.0.GA-src/tools/etc/buildmagic/buildmagic.ent ./tools/etc/buildmagic/buildmagic.ent
+--- /tmp/jboss-4.2.0.GA-src/tools/etc/buildmagic/buildmagic.ent Sat May 12 06:24:27 2007
++++ ./tools/etc/buildmagic/buildmagic.ent Tue Jun 19 14:03:55 2007
+@@ -11,19 +11,8 @@
+ <property name="buildmagic.ant15.baseversion" value="1.5"/>
+ <property name="buildmagic.ant16.baseversion" value="1.6"/>
+
+- <!--
+- | Add new conditions for other supported Ant versions when they
+- | become avaialble.
+- -->
+-
+- <condition property="buildmagic.ant.compatible">
+- <or>
+- <contains string="${ant.version}"
+- substring="Ant version ${buildmagic.ant15.baseversion}"/>
+- <contains string="${ant.version}"
+- substring="Ant version ${buildmagic.ant16.baseversion}"/>
+- </or>
+- </condition>
++ <!-- disable ant checks -->
++ <property name="buildmagic.ant.compatible" value="forced"/>
+
+ <fail unless="buildmagic.ant.compatible">
+
diff --git a/java/jboss4/files/pkg-deinstall.in b/java/jboss4/files/pkg-deinstall.in
new file mode 100644
index 000000000000..72f7b922c69f
--- /dev/null
+++ b/java/jboss4/files/pkg-deinstall.in
@@ -0,0 +1,35 @@
+#!/bin/sh
+#
+# This script does the following.
+#
+# * Checks if the JBoss PID file exists. If it does, it kills the
+# JBoss process and removes the PID file.
+#
+# $FreeBSD$
+#
+
+# Make sure we're in the right stage of the process
+if [ "$2" = "DEINSTALL" ]; then
+
+ # Kill JBoss if it is still running
+ PID_FILE=/var/run/jboss.pid
+ if [ -s ${PID_FILE} ]; then
+ PID=`cat ${PID_FILE}`
+ echo -n ">> Killing JBoss Server process (${PID})..."
+ /bin/kill ${PID} > /dev/null 2> /dev/null
+ if [ $? -eq 0 ]; then
+ echo " [ DONE ]"
+ else
+ echo " [ FAILED ]"
+ fi
+ echo -n ">> Removing PID file (${PID_FILE})..."
+ rm ${PID_FILE} > /dev/null 2> /dev/null
+ if [ $? -eq 0 ]; then
+ echo " [ DONE ]"
+ else
+ echo " [ FAILED ]"
+ fi
+ fi
+fi
+
+exit 0
diff --git a/java/jboss4/files/pkg-install.in b/java/jboss4/files/pkg-install.in
new file mode 100644
index 000000000000..687ec3fc1f9e
--- /dev/null
+++ b/java/jboss4/files/pkg-install.in
@@ -0,0 +1,46 @@
+#!/bin/sh
+#
+# Checks if the 'www' user and group exist. If they don't, then
+# an attempt is made to create both.
+#
+# $FreeBSD$
+#
+
+# Make sure we're called during the 'make install' process
+if [ "$2" != "PRE-INSTALL" ]; then
+ exit 0
+fi
+
+# Set some constants
+USER=www
+GROUP=${USER}
+UID=80
+GID=${UID}
+
+# See if the group already exists
+if ! pw groupshow "${GROUP}" 2>/dev/null 1>&2; then
+
+ # If not, try to create it
+ if pw groupadd ${GROUP} -g ${GID}; then
+ echo "Added group \"${GROUP}\"."
+ else
+ echo "Adding group \"${GROUP}\" failed..."
+ exit 1
+ fi
+fi
+
+# See if the user already exists
+if ! pw usershow "${USER}" 2>/dev/null 1>&2; then
+
+ # If not, try to create it
+ if pw useradd ${USER} -u ${UID} -g ${GROUP} -h - \
+ -s "/sbin/nologin" -d "/nonexistent" \
+ -c "World Wide Web Owner"; \
+ then
+ echo "Added user \"${USER}\"."
+ else
+ echo "Adding user \"${USER}\" failed..."
+ exit 1
+ fi
+fi
+exit 0
diff --git a/java/jboss4/files/pkg-message b/java/jboss4/files/pkg-message.in
index e48411f3028c..e48411f3028c 100644
--- a/java/jboss4/files/pkg-message
+++ b/java/jboss4/files/pkg-message.in