- Respect LOCALBASE/PREFIX
- Proper use of RCng PR: ports/88313 Submitted by: Gerhard Gonter <g.gonter@ieee.org> (maintainer)
This commit is contained in:
parent
62bec15494
commit
2382f6a564
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=147084
7 changed files with 67 additions and 24 deletions
|
@ -7,6 +7,7 @@
|
|||
|
||||
PORTNAME= cyrus-smlacapd
|
||||
PORTVERSION= 0.5
|
||||
PORTREVISION= 1
|
||||
CATEGORIES= databases mail
|
||||
MASTER_SITES= ftp://ftp.andrew.cmu.edu/pub/cyrus-mail/ \
|
||||
ftp://ftp.hanse.de/sites/transit/mirror/ftp.andrew.cmu.edu/pub/cyrus-mail/
|
||||
|
@ -23,12 +24,12 @@ CONFIGURE_ARGS= --with-cyrus-prefix=${PREFIX}/cyrus \
|
|||
--with-sasldir=${LOCALBASE}/lib
|
||||
|
||||
SUB_FILES= pkg-message
|
||||
PKGMESSAGE= ${WRKDIR}/pkg-message
|
||||
USE_RC_SUBR= cyrus_smlacapd_backend.sh
|
||||
|
||||
ACAPD_DOC= ${PREFIX}/share/doc/acapd
|
||||
|
||||
pre-configure:
|
||||
${REINPLACE_CMD} -e "s#sasl.h#sasl1/sasl.h#" ${WRKSRC}/configure
|
||||
${REINPLACE_CMD} -e "s|%%LOCALBASE%%|${LOCALBASE}|g" ${WRKSRC}/configure
|
||||
${REINPLACE_CMD} -e "s#<sasl.h>#<sasl1/sasl.h>#" \
|
||||
${WRKSRC}/actest/actest.c ${WRKSRC}/api/acap.c \
|
||||
${WRKSRC}/api/acap.h ${WRKSRC}/frontend/frontend.c \
|
||||
|
@ -40,9 +41,6 @@ pre-su-install:
|
|||
|
||||
post-install:
|
||||
${INSTALL} ${LOCALBASE}/lib/sml-nj/bin/.run/run.x86-freebsd ${PREFIX}/cyrus/bin
|
||||
${INSTALL_SCRIPT} ${FILESDIR}/cyrus_smlacapd_backend \
|
||||
${PREFIX}/etc/rc.d/cyrus_smlacapd_backend.sample
|
||||
|
||||
${MKDIR} ${ACAPD_DOC}
|
||||
${INSTALL_DATA} ${FILESDIR}/acapd.conf-sample ${ACAPD_DOC}
|
||||
.if !defined(NOPORTDOCS)
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# $FreeBSD: /tmp/pcvs/ports/databases/cyrus-smlacapd/files/Attic/cyrus_smlacapd_backend,v 1.1 2005-01-20 15:11:08 pav Exp $
|
||||
# $FreeBSD$
|
||||
#
|
||||
|
||||
# PROVIDE: cyrus_smlacapd_backend
|
||||
|
@ -11,14 +11,16 @@
|
|||
# Add the following line to /etc/rc.conf to enable cyrus_smlacapd_backend:
|
||||
# cyrus_smlacapd_backend_enable="YES"
|
||||
#
|
||||
. /etc/rc.subr
|
||||
prefix=%%PREFIX%%
|
||||
cyrus=${prefix}/cyrus
|
||||
. %%RC_SUBR$$
|
||||
|
||||
name="cyrus_smlacapd_backend"
|
||||
rcvar=`set_rcvar`
|
||||
|
||||
[ -z "$cyrus_smlacapd_backend_enable" ] && cyrus_smlacapd_backend_enable="NO"
|
||||
[ -z "$cyrus_smlacapd_backend_runtime" ] && cyrus_smlacapd_backend_runtime="/usr/local/cyrus/bin/run.x86-freebsd"
|
||||
[ -z "$cyrus_smlacapd_backend_heap" ] && cyrus_smlacapd_backend_heap="/usr/local/cyrus/bin/backend.x86-bsd"
|
||||
[ -z "$cyrus_smlacapd_backend_runtime" ] && cyrus_smlacapd_backend_runtime="${cyrus}/bin/run.x86-freebsd"
|
||||
[ -z "$cyrus_smlacapd_backend_heap" ] && cyrus_smlacapd_backend_heap="${cyrus}bin/backend.x86-bsd"
|
||||
|
||||
required_dirs="/var/acap /var/spool/acap"
|
||||
pidfile=/var/run/cyrus_smlacapd_backend.pid
|
||||
|
@ -34,7 +36,7 @@ cyrus_smlacapd_backend_precmd()
|
|||
if [ -e ${SOCKET} ]
|
||||
then
|
||||
rm ${SOCKET}
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
cyrus_smlacapd_backend_postcmd()
|
||||
|
@ -45,7 +47,7 @@ cyrus_smlacapd_backend_postcmd()
|
|||
if [ -n "$pid" ]
|
||||
then
|
||||
echo "$pid" > $pidfile
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
load_rc_config $name
|
|
@ -1,17 +1,19 @@
|
|||
--- actest/Makefile.in.orig Thu Apr 20 03:32:58 2000
|
||||
+++ actest/Makefile.in Tue May 11 03:54:34 2004
|
||||
@@ -37,7 +37,7 @@
|
||||
+++ actest/Makefile.in Tue Nov 1 01:38:36 2005
|
||||
@@ -37,16 +37,16 @@
|
||||
RANLIB = @RANLIB@
|
||||
|
||||
DEFS = @DEFS@ @LOCALDEFS@
|
||||
-CPPFLAGS = -I. -I$(srcdir) -I$(srcdir)/../lib
|
||||
+CPPFLAGS = -I/usr/local/include -I$(srcdir) -I$(srcdir)/../lib
|
||||
+CPPFLAGS = -I${PREFIX}/include -I$(srcdir) -I$(srcdir)/../lib
|
||||
DEPLIBS = ../lib/libcyrus.a @DEPLIBS@
|
||||
LIBS = @LIBS@ $(DEPLIBS) @LIB_SASL@
|
||||
|
||||
@@ -46,7 +46,7 @@
|
||||
CFLAGS = @CFLAGS@
|
||||
LDFLAGS = @LDFLAGS@ @CFLAGS@
|
||||
|
||||
prefix = /usr/local
|
||||
-prefix = /usr/local
|
||||
+prefix = ${PREFIX}
|
||||
exec_prefix = ${prefix}
|
||||
-cyrus_prefix = /usr/cyrus
|
||||
+cyrus_prefix = ${prefix}/cyrus
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
--- backend/Makefile.in.orig Wed Mar 8 22:51:42 2000
|
||||
+++ backend/Makefile.in Tue May 11 03:54:34 2004
|
||||
+++ backend/Makefile.in Tue Nov 1 01:40:19 2005
|
||||
@@ -48,7 +48,8 @@
|
||||
INSTALL = @INSTALL@
|
||||
|
||||
SML=@SMLNJ@
|
||||
-cyrus_prefix = /usr/cyrus
|
||||
+prefix = /usr/local
|
||||
+prefix = ${PREFIX}
|
||||
+cyrus_prefix = ${prefix}/cyrus
|
||||
|
||||
PROGS = backend
|
||||
|
|
40
databases/cyrus-smlacapd/files/patch-configure
Normal file
40
databases/cyrus-smlacapd/files/patch-configure
Normal file
|
@ -0,0 +1,40 @@
|
|||
--- configure.orig Tue Nov 1 08:56:54 2005
|
||||
+++ configure Tue Nov 1 09:00:45 2005
|
||||
@@ -1286,13 +1286,13 @@
|
||||
fi
|
||||
|
||||
echo "$ac_t""$andrew_runpath_switch" 1>&6
|
||||
-CPPFLAGS="-I/usr/local/include ${CPPFLAGS}"
|
||||
+CPPFLAGS="-I%%LOCALBASE%%/include ${CPPFLAGS}"
|
||||
|
||||
# this is CMU ADD LIBPATH
|
||||
if test "$andrew_runpath_switch" = "none" ; then
|
||||
- LDFLAGS="-L"/usr/local/lib" ${LDFLAGS}"
|
||||
+ LDFLAGS="-L"%%LOCALBASE%%/lib" ${LDFLAGS}"
|
||||
else
|
||||
- LDFLAGS="-L"/usr/local/lib" $andrew_runpath_switch"/usr/local/lib" ${LDFLAGS}"
|
||||
+ LDFLAGS="-L"%%LOCALBASE%%/lib" $andrew_runpath_switch"/usr/local/lib" ${LDFLAGS}"
|
||||
fi
|
||||
|
||||
|
||||
@@ -2779,16 +2779,16 @@
|
||||
LDFLAGS="${cmu_saved_LDFLAGS} -L${ac_cv_sasl_where_lib}"
|
||||
fi
|
||||
|
||||
- ac_safe=`echo "sasl.h" | sed 'y%./+-%__p_%'`
|
||||
-echo $ac_n "checking for sasl.h""... $ac_c" 1>&6
|
||||
-echo "configure:2785: checking for sasl.h" >&5
|
||||
+ ac_safe=`echo "sasl1/sasl.h" | sed 'y%./+-%__p_%'`
|
||||
+echo $ac_n "checking for sasl1/sasl.h""... $ac_c" 1>&6
|
||||
+echo "configure:2785: checking for sasl1/sasl.h" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2790 "configure"
|
||||
#include "confdefs.h"
|
||||
-#include <sasl.h>
|
||||
+#include <sasl1/sasl.h>
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:2795: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
|
@ -1,17 +1,19 @@
|
|||
--- frontend/Makefile.in.orig Fri Mar 3 06:05:00 2000
|
||||
+++ frontend/Makefile.in Tue May 11 03:54:34 2004
|
||||
@@ -37,7 +37,7 @@
|
||||
+++ frontend/Makefile.in Tue Nov 1 01:41:17 2005
|
||||
@@ -37,16 +37,16 @@
|
||||
RANLIB = @RANLIB@
|
||||
|
||||
DEFS = @DEFS@ @LOCALDEFS@
|
||||
-CPPFLAGS = -I. -I$(srcdir) -I$(srcdir)/../lib
|
||||
+CPPFLAGS = -I/usr/local/include -I$(srcdir) -I$(srcdir)/../lib
|
||||
+CPPFLAGS = -I${PREFIX}/include -I$(srcdir) -I$(srcdir)/../lib
|
||||
DEPLIBS = ../lib/libcyrus.a @DEPLIBS@
|
||||
LIBS = @LIBS@ $(DEPLIBS) @LIB_SASL@
|
||||
|
||||
@@ -46,7 +46,7 @@
|
||||
CFLAGS = @CFLAGS@
|
||||
LDFLAGS = @LDFLAGS@ @CFLAGS@
|
||||
|
||||
prefix = /usr/local
|
||||
-prefix = /usr/local
|
||||
+prefix = ${PREFIX}
|
||||
exec_prefix = ${prefix}
|
||||
-cyrus_prefix = /usr/cyrus
|
||||
+cyrus_prefix = ${prefix}/cyrus
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
etc/rc.d/cyrus_smlacapd_backend.sample
|
||||
cyrus/bin/frontend
|
||||
cyrus/bin/backend-acapd
|
||||
cyrus/bin/backend.x86-bsd
|
||||
|
|
Loading…
Reference in a new issue