Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 6 Dec 2012 02:33:13 +0900
From:      KATO Tsuguru <tkato432@yahoo.com>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/174171: sysutils/searchmonkey: Fix build with clang
Message-ID:  <20121206023313.7b2f76a767a44b20e340b96d@yahoo.com>
Resent-Message-ID: <201212051810.qB5IA4HZ033478@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         174171
>Category:       ports
>Synopsis:       sysutils/searchmonkey: Fix build with clang
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Wed Dec 05 18:10:04 UTC 2012
>Closed-Date:
>Last-Modified:
>Originator:     KATO Tsuguru
>Release:        FreeBSD 7.4-RELEASE-p11 i386
>Organization:
>Environment:
>Description:
- Fix build with clang
- Support CXXFLAGS properly
- Add LICENSE

New file:
files/patch-Utility.h

>How-To-Repeat:
>Fix:

diff -urN /usr/ports/sysutils/searchmonkey/Makefile sysutils/searchmonkey/Makefile
--- /usr/ports/sysutils/searchmonkey/Makefile	2012-11-08 07:54:41.000000000 +0900
+++ sysutils/searchmonkey/Makefile	2012-12-04 00:01:29.000000000 +0900
@@ -1,13 +1,9 @@
-# New ports collection makefile for:	searchmonkey
-# Date created:		26 August 2006
-# Whom:			Andrew Pantyukhin <infofarmer@FreeBSD.org>
-#
+# Created by: Andrew Pantyukhin <infofarmer@FreeBSD.org>
 # $FreeBSD: head/sysutils/searchmonkey/Makefile 300897 2012-07-14 14:29:18Z beat $
-#
 
 PORTNAME=	searchmonkey
 PORTVERSION=	2.0.0
-PORTREVISION=	1
+PORTREVISION=	2
 CATEGORIES=	sysutils
 MASTER_SITES=	SF/${PORTNAME}/Searchmonkey2/${PORTVERSION}%20%5Bstable%5D
 DISTNAME=	${PORTNAME}_v${PORTVERSION}
@@ -15,17 +11,20 @@
 MAINTAINER=	ports@FreeBSD.org
 COMMENT=	Search using regexes for file names and text
 
+LICENSE=	GPLv3 # (or later)
+
 USE_ZIP=	yes
+USE_DOS2UNIX=	*.cpp *.h
 USE_QT4=	corelib gui moc_build qmake_build rcc_build uic_build
 MAKE_JOBS_SAFE=	yes
 
 PLIST_FILES=	bin/${PORTNAME}
 
 do-configure:
-	@cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${QMAKE} ${PORTNAME}_2_0.pro \
-		-spec ${QMAKESPEC}
+	@(cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${QMAKE} ${PORTNAME}_2_0.pro \
+		${QMAKEFLAGS})
 
 do-install:
-	${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin
+	(cd ${WRKSRC} && ${INSTALL_PROGRAM} ${PORTNAME} ${PREFIX}/bin)
 
 .include <bsd.port.mk>
diff -urN /usr/ports/sysutils/searchmonkey/files/patch-Utility.h sysutils/searchmonkey/files/patch-Utility.h
--- /usr/ports/sysutils/searchmonkey/files/patch-Utility.h	1970-01-01 09:00:00.000000000 +0900
+++ sysutils/searchmonkey/files/patch-Utility.h	2012-10-17 06:43:21.000000000 +0900
@@ -0,0 +1,35 @@
+--- Utility.h.orig	2010-05-16 20:37:32.000000000 +0900
++++ Utility.h	2012-10-17 06:41:46.000000000 +0900
+@@ -92,16 +92,6 @@
+     CallEach(observers, searchable, &Subject::Register);
+     here the Subject is the type of Caller
+ */
+-template <typename CalleeContainer, typename Caller, typename Op>
+-void CallEach(const CalleeContainer& container, Caller& caller, Op op)
+-{
+-    for_each(container.begin(), container.end(), bind1st(mem_fun(op), caller));
+-}
+-template <typename T>
+-bool IsValueInRange(T value, T lowerBound, T upperBound)
+-{
+-    return LowerBoundFit(value, lowerBound) && UpperBoundFit(value, upperBound);
+-}
+ template <typename T>
+ bool BoundSpecified(T boundValue)
+ {
+@@ -129,5 +119,15 @@
+ 
+     return false;
+ }
++template <typename CalleeContainer, typename Caller, typename Op>
++void CallEach(const CalleeContainer& container, Caller& caller, Op op)
++{
++    for_each(container.begin(), container.end(), bind1st(mem_fun(op), caller));
++}
++template <typename T>
++bool IsValueInRange(T value, T lowerBound, T upperBound)
++{
++    return LowerBoundFit(value, lowerBound) && UpperBoundFit(value, upperBound);
++}
+ 
+ #endif
>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20121206023313.7b2f76a767a44b20e340b96d>