diff --git a/www/libproxy/Makefile b/www/libproxy/Makefile index f916f9e67236d..67f5d297eecbc 100644 --- a/www/libproxy/Makefile +++ b/www/libproxy/Makefile @@ -1,37 +1,24 @@ -# $NetBSD: Makefile,v 1.15 2012/11/27 11:26:23 drochner Exp $ -# +# $NetBSD: Makefile,v 1.16 2013/05/24 18:22:57 wiz Exp $ -DISTNAME= libproxy-0.3.1 -PKGREVISION= 2 +DISTNAME= libproxy-0.4.11 CATEGORIES= www gnome MASTER_SITES= http://libproxy.googlecode.com/files/ -EXTRACT_SUFX= .tar.bz2 MAINTAINER= pkgsrc-users@NetBSD.org HOMEPAGE= http://code.google.com/p/libproxy/ COMMENT= Library that provides automatic proxy configuration management LICENSE= gnu-lgpl-v2.1 -GNU_CONFIGURE= yes -CONFIGURE_ARGS+= --without-python -CONFIGURE_ENV+= PYTHON=${TRUE} +USE_CMAKE= yes USE_LIBTOOL= yes USE_TOOLS+= pkg-config gmake PY_PATCHPLIST= yes -CHECK_PORTABILITY_SKIP= test.d/* -USE_LANGUAGES= c99 +USE_LANGUAGES= c99 c++ LIBS.SunOS+= -lnsl -lsocket -PKGCONFIG_OVERRIDE+= libproxy-1.0.pc.in +PKGCONFIG_OVERRIDE+= bindings/csharp/libproxy-sharp-1.0.pc.cmake +PKGCONFIG_OVERRIDE+= libproxy/libproxy-1.0.pc.in -# 0.3.0 doesn't install the python bindings even when they -# are enabled, so comment out dependencies. -#BUILDLINK_API_DEPENDS.python26+= python26>=2.6.2nb4 - -post-extract: - ${RM} -rf ${WRKSRC}/test.d/.svn - -#.include "../../lang/python/extension.mk" .include "../../mk/dlopen.buildlink3.mk" .include "../../mk/pthread.buildlink3.mk" .include "../../mk/bsd.pkg.mk" diff --git a/www/libproxy/PLIST b/www/libproxy/PLIST index ecba308918330..ccff3e8d4f330 100644 --- a/www/libproxy/PLIST +++ b/www/libproxy/PLIST @@ -1,13 +1,8 @@ -@comment $NetBSD: PLIST,v 1.3 2009/12/15 11:00:11 wiz Exp $ +@comment $NetBSD: PLIST,v 1.4 2013/05/24 18:22:57 wiz Exp $ bin/proxy include/proxy.h -lib/libproxy.la -lib/libproxy/${PKGVERSION}/modules/config_direct.so -lib/libproxy/${PKGVERSION}/modules/config_envvar.so -lib/libproxy/${PKGVERSION}/modules/config_file.so -lib/libproxy/${PKGVERSION}/modules/config_wpad.so -lib/libproxy/${PKGVERSION}/modules/ignore_domain.so -lib/libproxy/${PKGVERSION}/modules/ignore_ip.so -lib/libproxy/${PKGVERSION}/modules/wpad_dns.so -lib/libproxy/${PKGVERSION}/modules/wpad_dnsdevolution.so +lib/libproxy.so +lib/libproxy.so.1 +lib/libproxy.so.1.0.0 lib/pkgconfig/libproxy-1.0.pc +share/cmake/Modules/Findlibproxy.cmake diff --git a/www/libproxy/buildlink3.mk b/www/libproxy/buildlink3.mk index 942b924ac44c2..9a851df43deac 100644 --- a/www/libproxy/buildlink3.mk +++ b/www/libproxy/buildlink3.mk @@ -1,4 +1,4 @@ -# $NetBSD: buildlink3.mk,v 1.4 2009/09/10 02:03:11 dsainty Exp $ +# $NetBSD: buildlink3.mk,v 1.5 2013/05/24 18:22:57 wiz Exp $ BUILDLINK_TREE+= libproxy @@ -6,6 +6,7 @@ BUILDLINK_TREE+= libproxy LIBPROXY_BUILDLINK3_MK:= BUILDLINK_API_DEPENDS.libproxy+= libproxy>=0.2.3 +BUILDLINK_ABI_DEPENDS.libproxy+= libproxy>=0.4.11 BUILDLINK_PKGSRCDIR.libproxy?= ../../www/libproxy .endif # LIBPROXY_BUILDLINK3_MK diff --git a/www/libproxy/distinfo b/www/libproxy/distinfo index abb53ad35828b..277a4f8ed69b1 100644 --- a/www/libproxy/distinfo +++ b/www/libproxy/distinfo @@ -1,9 +1,6 @@ -$NetBSD: distinfo,v 1.10 2012/11/28 12:20:38 drochner Exp $ +$NetBSD: distinfo,v 1.11 2013/05/24 18:22:57 wiz Exp $ -SHA1 (libproxy-0.3.1.tar.bz2) = 71338ede69b4ed2b32541f7cf5285c8828ad3a8d -RMD160 (libproxy-0.3.1.tar.bz2) = 565deed81f13752f61bbff531085ef1b2c5e13d0 -Size (libproxy-0.3.1.tar.bz2) = 315526 bytes -SHA1 (patch-CVE-2012-4505) = ad59e5196a334d909073170bf2e56f1feca3dccf -SHA1 (patch-aa) = 08baf8aeab5a1060cc5a6fa0435199892c7a0ab6 -SHA1 (patch-ab) = b2bd350d3af3274fa028612dbe6e2cb8ddd3e8bd -SHA1 (patch-ac) = 8bcc3543479490c92def6243ad74f8bf714cfeb2 +SHA1 (libproxy-0.4.11.tar.gz) = c037969434095bc65d29437e11a7c9e0293a5149 +RMD160 (libproxy-0.4.11.tar.gz) = 382110e088faf7a170ac838864d675204d886237 +Size (libproxy-0.4.11.tar.gz) = 93757 bytes +SHA1 (patch-libproxy_CMakeLists.txt) = b300954ce464a0854c46b5acd14bd8c78782d577 diff --git a/www/libproxy/patches/patch-CVE-2012-4505 b/www/libproxy/patches/patch-CVE-2012-4505 deleted file mode 100644 index b0adadae707a9..0000000000000 --- a/www/libproxy/patches/patch-CVE-2012-4505 +++ /dev/null @@ -1,35 +0,0 @@ -$NetBSD: patch-CVE-2012-4505,v 1.1 2012/11/23 16:41:01 drochner Exp $ - -see https://bugzilla.redhat.com/show_bug.cgi?id=864612 - ---- src/lib/pac.c.orig 2009-09-29 19:52:50.000000000 +0000 -+++ src/lib/pac.c -@@ -35,6 +35,9 @@ - - #define PAC_MIME_TYPE "application/x-ns-proxy-autoconfig" - -+// This is the maximum pac size (to avoid memory attacks) -+#define PAC_MAX_SIZE 102400 -+ - /** - * ProxyAutoConfig object. All fields are private. - */ -@@ -159,12 +162,15 @@ px_pac_reload(pxPAC *self) - } - - /* Get content */ -- if (!content_length || !correct_mime_type) goto error; -+ if (content_length == 0 || content_length > PAC_MAX_SIZE || !correct_mime_type) goto error; - px_free(line); line = NULL; - px_free(self->cache); - self->cache = px_malloc0(content_length+1); -- for (int recvd=0 ; recvd != content_length ; ) -- recvd += recv(sock, self->cache + recvd, content_length - recvd, 0); -+ for (int recvd=0 ; recvd != content_length ; ) { -+ int r = recv(sock, self->cache + recvd, content_length - recvd, 0); -+ if (r <= 0) goto error; -+ recvd += r; -+ } - } - else - { /* file:// url */ diff --git a/www/libproxy/patches/patch-aa b/www/libproxy/patches/patch-aa deleted file mode 100644 index 9b40329aa471c..0000000000000 --- a/www/libproxy/patches/patch-aa +++ /dev/null @@ -1,13 +0,0 @@ -$NetBSD: patch-aa,v 1.6 2010/08/17 13:10:22 seanb Exp $ - ---- src/lib/Makefile.am.orig 2009-08-14 19:00:32.000000000 +0000 -+++ src/lib/Makefile.am -@@ -11,7 +11,7 @@ libproxy_la_SOURCES = \ - url.c url.h - - libproxy_la_CFLAGS = -DMODULEDIR=\"@MODULEDIR@@DIR_SEPARATOR@\" -DSYSCONFDIR=\"@SYSCONFDIR@@DIR_SEPARATOR@\" -std=c99 -D_POSIX_C_SOURCE=200112L --libproxy_la_LDFLAGS = -lpthread -lm -no-undefined -+libproxy_la_LDFLAGS = ${PTHREAD_LDFLAGS} ${PTHREAD_LIBS} -lm -no-undefined - - include_HEADERS = proxy.h - diff --git a/www/libproxy/patches/patch-ab b/www/libproxy/patches/patch-ab deleted file mode 100644 index cc63143aad4a0..0000000000000 --- a/www/libproxy/patches/patch-ab +++ /dev/null @@ -1,13 +0,0 @@ -$NetBSD: patch-ab,v 1.3 2010/08/17 13:10:22 seanb Exp $ - ---- src/lib/Makefile.in.orig 2009-08-14 19:05:15.000000000 +0000 -+++ src/lib/Makefile.in -@@ -278,7 +278,7 @@ libproxy_la_SOURCES = \ - url.c url.h - - libproxy_la_CFLAGS = -DMODULEDIR=\"@MODULEDIR@@DIR_SEPARATOR@\" -DSYSCONFDIR=\"@SYSCONFDIR@@DIR_SEPARATOR@\" -std=c99 -D_POSIX_C_SOURCE=200112L --libproxy_la_LDFLAGS = -lpthread -lm -no-undefined -+libproxy_la_LDFLAGS = ${PTHREAD_LDFLAGS} ${PTHREAD_LIBS} -lm -no-undefined - include_HEADERS = proxy.h - all: all-am - diff --git a/www/libproxy/patches/patch-ac b/www/libproxy/patches/patch-ac deleted file mode 100644 index 9b795a0b9c32f..0000000000000 --- a/www/libproxy/patches/patch-ac +++ /dev/null @@ -1,20 +0,0 @@ -$NetBSD: patch-ac,v 1.4 2012/11/28 12:20:38 drochner Exp $ - -CVE-2012-5580 -see https://bugzilla.novell.com/show_bug.cgi?id=791086 - ---- src/bin/proxy.c.orig 2009-09-29 19:52:50.000000000 +0000 -+++ src/bin/proxy.c -@@ -89,11 +89,7 @@ print_proxies(char **proxies) - { - for (int j = 0; proxies[j] ; j++) - { -- printf(proxies[j]); -- if (proxies[j+1]) -- printf(" "); -- else -- printf("\n"); -+ printf("%s%s", proxies[j], proxies[j+1] ? " " : "\n"); - free(proxies[j]); - } - free(proxies); diff --git a/www/libproxy/patches/patch-libproxy_CMakeLists.txt b/www/libproxy/patches/patch-libproxy_CMakeLists.txt new file mode 100644 index 0000000000000..a4c0c28ba7c35 --- /dev/null +++ b/www/libproxy/patches/patch-libproxy_CMakeLists.txt @@ -0,0 +1,16 @@ +$NetBSD: patch-libproxy_CMakeLists.txt,v 1.1 2013/05/24 18:22:57 wiz Exp $ + +If this is defined, it doesn't compile on NetBSD due to +http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24012 +and missing ntohs() etc. + +--- libproxy/CMakeLists.txt.orig 2012-11-30 22:31:35.000000000 +0000 ++++ libproxy/CMakeLists.txt +@@ -6,7 +6,6 @@ set_project_version(0 4 11) + if (WIN32) + add_definitions(-D_CRT_SECURE_NO_WARNINGS=1) + else(WIN32) +- add_definitions(-D_POSIX_C_SOURCE=200112L) + set(CMAKE_CXX_FLAGS "-fvisibility=hidden ${CMAKE_CXX_FLAGS}") + endif(WIN32) +