1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-27 05:10:36 +00:00

Update to version 0.2.8

PR:		ports/163067
Submitted by:	toddnni <toddnni@gmail.com>
Approved by:	maintainer with slight improvement
This commit is contained in:
Pawel Pekala 2011-12-29 22:02:54 +00:00
parent e5fe56df10
commit f1327f8f77
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=288259
7 changed files with 37 additions and 46 deletions

View File

@ -6,36 +6,38 @@
#
PORTNAME= umurmur
PORTVERSION= 0.2.6
PORTREVISION= 1
PORTVERSION= 0.2.8
CATEGORIES= audio net
MASTER_SITES= ${MASTER_SITE_GOOGLE_CODE}
MAINTAINER= ayu@commun.jp
COMMENT= Minimalistic Murmur (Mumble server)
LIB_DEPENDS= config.10:${PORTSDIR}/devel/libconfig
LIB_DEPENDS= config.10:${PORTSDIR}/devel/libconfig \
protobuf-c.0:${PORTSDIR}/devel/protobuf-c
USE_GMAKE= yes
GNU_CONFIGURE= yes
USE_OPENSSL= yes
CONFIGURE_ARGS= --with-ssl=openssl
USE_RC_SUBR= umurmur
MAKE_ENV+= TARGET_ARCH=
CPPFLAGS+= -I${LOCALBASE}/include
LDFLAGS+= -L${LOCALBASE}/lib
.include <bsd.port.pre.mk>
do-build:
@(cd ${WRKSRC}/src; ${SETENV} ${MAKE_ENV} ${GMAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} all)
pre-su-install:
@PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
pre-install:
@${SED} -i '' -e 's|"/etc/|"${PREFIX}/etc/|' ${WRKSRC}/umurmur.conf.example
post-patch:
@${REINPLACE_CMD} -e 's|%%PREFIX%%|${PREFIX}|g' ${WRKSRC}/src/conf.h
@${REINPLACE_CMD} -e 's|%%PREFIX%%|${PREFIX}|g' ${WRKSRC}/src/conf.c
@${REINPLACE_CMD} \
-e 's|/etc/|${PREFIX}/etc/|g' ${WRKSRC}/umurmur.conf.example
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/src/umurmurd ${PREFIX}/sbin
post-install:
@${MKDIR} ${PREFIX}/etc/umurmur
@${INSTALL_DATA} ${WRKSRC}/umurmur.conf.example ${PREFIX}/etc/umurmur/umurmur.conf.sample
@if [ ! -f ${PREFIX}/etc/umurmur/umurmur.conf ]; then \

View File

@ -1,2 +1,2 @@
SHA256 (umurmur-0.2.6.tar.gz) = b1f237191ea1db7890be86bc3ebe562570901d8bd58bc53d9ecee0a3f4be38cb
SIZE (umurmur-0.2.6.tar.gz) = 86014
SHA256 (umurmur-0.2.8.tar.gz) = 62c43da2f07125977cf8024a0775ed697101816c3fa8f36345780901aaf08736
SIZE (umurmur-0.2.8.tar.gz) = 155357

View File

@ -1,15 +0,0 @@
--- src/Makefile.orig 2011-02-24 13:06:56.000000000 +0900
+++ src/Makefile 2011-02-24 13:07:54.000000000 +0900
@@ -25,9 +25,10 @@
# OpenSSL - usually installed at a standard place
# EXTRA_CFLAGS:=
# EXTRA_LDFLAGS:=-lcrypto -lssl
+EXTRA_LDFLAGS:=-lcrypto -lssl
-CFLAGS:=$(CFLAGS) -I. -Wall $(EXTRA_CFLAGS)
-LDFLAGS:=$(EXTRA_LDFLAGS) $(LDFLAGS) -lconfig
+CFLAGS:=$(CFLAGS) -I. -I/usr/local/include -Wall $(EXTRA_CFLAGS)
+LDFLAGS:=$(EXTRA_LDFLAGS) $(LDFLAGS) -L/usr/local/lib -lconfig
umurmurd:google/protobuf-c/libprotobuf_c.a $(OBJS)
$(CC) $(LDFLAGS) $(OBJS) $(SSL_LIB) google/protobuf-c/libprotobuf_c.a -o umurmurd

View File

@ -1,39 +1,30 @@
--- src/conf.c.orig 2011-02-24 13:16:42.000000000 +0900
+++ src/conf.c 2011-02-24 13:17:50.000000000 +0900
@@ -40,7 +40,7 @@
static config_t configuration;
-#define DEFAULT_CONFIG "/etc/umurmur.conf"
+#define DEFAULT_CONFIG "/usr/local/etc/umurmur/umurmur.conf"
#define DEFAULT_WELCOME "Welcome to uMurmur!"
#define DEFAULT_MAX_CLIENTS 10
#define DEFAULT_MAX_BANDWIDTH 48000
@@ -73,23 +73,23 @@
--- src/conf.c.old 2011-12-04 19:11:54.718388035 +0200
+++ src/conf.c 2011-12-04 19:13:08.845299535 +0200
@@ -87,23 +87,23 @@
case CERTIFICATE:
setting = config_lookup(&configuration, "certificate");
if (!setting)
- return "/etc/umurmur/certificate.crt";
+ return "/usr/local/etc/umurmur/certificate.crt";
+ return "%%PREFIX%%/etc/umurmur/certificate.crt";
else {
if ((strsetting = config_setting_get_string(setting)) != NULL)
return strsetting;
else
- return "/etc/umurmur/certificate.crt";
+ return "/usr/local/etc/umurmur/certificate.crt";
+ return "%%PREFIX%%/etc/umurmur/certificate.crt";
}
break;
case KEY:
setting = config_lookup(&configuration, "private_key");
if (!setting)
- return "/etc/umurmur/private_key.key";
+ return "/usr/local/etc/umurmur/private_key.key";
+ return "%%PREFIX%%/etc/umurmur/private_key.key";
else {
if ((strsetting = config_setting_get_string(setting)) != NULL)
return strsetting;
else
- return "/etc/umurmur/private_key.key";
+ return "/usr/local/etc/umurmur/private_key.key";
+ return "%%PREFIX%%/etc/umurmur/private_key.key";
}
break;
case PASSPHRASE:

View File

@ -0,0 +1,11 @@
--- src/conf.h.old 2011-12-04 19:11:49.751119971 +0200
+++ src/conf.h 2011-12-04 19:13:32.677786798 +0200
@@ -33,7 +33,7 @@
#include "messages.h"
-#define DEFAULT_CONFIG "/etc/umurmur.conf"
+#define DEFAULT_CONFIG "%%PREFIX%%/etc/umurmur/umurmur.conf"
typedef enum param {
CERTIFICATE,

View File

@ -11,6 +11,8 @@
#
# umurmur_enable (bool): Set to NO by default.
# Set it to YES to enable umurmur.
# umurmur_user (str): Set to "umurmur" by default.
# Set to change user account.
# umurmur_flags (str): Set to "" by default.
# Extra flags passed to start command.
#
@ -28,7 +30,7 @@ rcvar=${name}_enable
# pidfile
pidfile="/var/run/umurmur/umurmur.pid"
command="%%PREFIX%%/sbin/umurmurd"
command="%%PREFIX%%/bin/umurmurd"
command_args="-p ${pidfile}"
load_rc_config $name

View File

@ -3,5 +3,5 @@
@unexec if cmp -s %D/etc/umurmur/umurmur.conf.sample %D/etc/umurmur/umurmur.conf; then rm -f %D/etc/umurmur/umurmur.conf; fi
etc/umurmur/umurmur.conf.sample
@exec if [ ! -f %D/etc/umurmur/umurmur.conf ] ; then cp -p %D/%F %B/umurmur/umurmur.conf; fi
sbin/umurmurd
bin/umurmurd
@dirrmtry etc/umurmur