From owner-svn-ports-head@FreeBSD.ORG Thu Nov 6 19:32:45 2014 Return-Path: Delivered-To: svn-ports-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id CC539FA3; Thu, 6 Nov 2014 19:32:45 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B7A9ECE3; Thu, 6 Nov 2014 19:32:45 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.9/8.14.9) with ESMTP id sA6JWjpj027536; Thu, 6 Nov 2014 19:32:45 GMT (envelope-from marino@FreeBSD.org) Received: (from marino@localhost) by svn.freebsd.org (8.14.9/8.14.9/Submit) id sA6JWim6027531; Thu, 6 Nov 2014 19:32:44 GMT (envelope-from marino@FreeBSD.org) Message-Id: <201411061932.sA6JWim6027531@svn.freebsd.org> X-Authentication-Warning: svn.freebsd.org: marino set sender to marino@FreeBSD.org using -f From: John Marino Date: Thu, 6 Nov 2014 19:32:44 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r372231 - in head/net-mgmt/ccnet: . files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Nov 2014 19:32:46 -0000 Author: marino Date: Thu Nov 6 19:32:44 2014 New Revision: 372231 URL: https://svnweb.freebsd.org/changeset/ports/372231 QAT: https://qat.redports.org/buildarchive/r372231/ Log: net-mgmt/ccnet: Fix post-install and support other BSDs PR: 194853 Submitted by: maintainer (Jingfeng Yan) Modified: head/net-mgmt/ccnet/Makefile head/net-mgmt/ccnet/files/patch-lib_utils.c head/net-mgmt/ccnet/files/patch-net_common_getgateway.c Modified: head/net-mgmt/ccnet/Makefile ============================================================================== --- head/net-mgmt/ccnet/Makefile Thu Nov 6 19:19:31 2014 (r372230) +++ head/net-mgmt/ccnet/Makefile Thu Nov 6 19:32:44 2014 (r372231) @@ -2,6 +2,7 @@ PORTNAME= ccnet PORTVERSION= 3.1.4 +PORTREVISION= 1 CATEGORIES= net-mgmt devel MAINTAINER= yan_jingfeng@yahoo.com @@ -39,12 +40,11 @@ WITH_OPENSSL_PORT= yes USE_OPENSSL= yes WWWDIR= ${PREFIX}/www/haiwen/seafile-server +SEABIN= ${STAGEDIR}${WWWDIR}/seafile/bin post-install: - @${MKDIR} -m 0755 ${STAGEDIR}${WWWDIR}/seafile/bin - ${INSTALL} -m 0755 ${STAGEDIR}${PREFIX}/bin/ccnet-init \ - ${STAGEDIR}${WWWDIR}/seafile/bin/ccnet-init - ${INSTALL} -m 0755 ${STAGEDIR}${PREFIX}/bin/ccnet-server \ - ${STAGEDIR}${WWWDIR}/seafile/bin/ccnet-server + @${MKDIR} ${SEABIN} + ${LN} ${STAGEDIR}${PREFIX}/bin/ccnet-init ${SEABIN} + ${LN} ${STAGEDIR}${PREFIX}/bin/ccnet-server ${SEABIN} .include Modified: head/net-mgmt/ccnet/files/patch-lib_utils.c ============================================================================== --- head/net-mgmt/ccnet/files/patch-lib_utils.c Thu Nov 6 19:19:31 2014 (r372230) +++ head/net-mgmt/ccnet/files/patch-lib_utils.c Thu Nov 6 19:32:44 2014 (r372231) @@ -16,7 +16,7 @@ #endif /* ifdef WIN32 */ -#ifdef __linux__ -+#if defined(__linux__) || defined(__FreeBSD__) ++#if defined(__linux__) || defined(__FreeBSD__) || defined(__DragonFly__) || defined(__NetBSD__) || defined(__OpenBSD__) /* read the link of /proc/123/exe and compare with `process_name' */ static int find_process_in_dirent(struct dirent *dir, const char *process_name) @@ -26,7 +26,7 @@ +#if defined(__linux__) if (sprintf (path, "/proc/%s/exe", dir->d_name) < 0) { +#endif -+#if defined(__FreeBSD__) ++#if defined(__FreeBSD__) || defined(__DragonFly__) || defined(__NetBSD__) || defined(__OpenBSD__) + if (sprintf (path, "/proc/%s/file", dir->d_name) < 0) { +#endif return -1; @@ -38,7 +38,7 @@ +/* + * Finally, we should not enforce to use /proc -+#ifdef __FreeBSD__ ++#if defined(__FreeBSD__) || defined(__DragonFly__) || defined(__NetBSD__) || defined(__OpenBSD__) +gboolean process_is_running (const char *process_name) +{ + //TODO Modified: head/net-mgmt/ccnet/files/patch-net_common_getgateway.c ============================================================================== --- head/net-mgmt/ccnet/files/patch-net_common_getgateway.c Thu Nov 6 19:19:31 2014 (r372230) +++ head/net-mgmt/ccnet/files/patch-net_common_getgateway.c Thu Nov 6 19:32:44 2014 (r372231) @@ -5,7 +5,7 @@ #endif -#ifdef BSD -+#ifdef __FreeBSD__ ++#if defined(__FreeBSD__) || defined(__DragonFly__) || defined(__NetBSD__) || defined(__OpenBSD__) #undef USE_PROC_NET_ROUTE #define USE_SOCKET_ROUTE #undef USE_SYSCTL_NET_ROUTE