aboutsummaryrefslogtreecommitdiff
path: root/textproc/libtranslate
diff options
context:
space:
mode:
authorMikhail Teterin <mi@FreeBSD.org>2011-09-29 18:10:20 +0000
committerMikhail Teterin <mi@FreeBSD.org>2011-09-29 18:10:20 +0000
commitec966285b67b260ee2b64d4417e2698e4f114af6 (patch)
tree91dbf3190e3981b28eed47d497b12343dfa6ad62 /textproc/libtranslate
parent3b7a495b670d009fb56bcd03e596c4c95a425ca6 (diff)
downloadports-ec966285b67b260ee2b64d4417e2698e4f114af6.tar.gz
ports-ec966285b67b260ee2b64d4417e2698e4f114af6.zip
Unbreak, when libsoup is needed, by switching to libsoup24. Use 4
year-old patch for that purpose, that's available on MASTER_SITE. While at it, apply some other patches sitting at the same location. Some others were already present in our own files/ -- add the link to the originals in those cases. Turn on MAKE_JOBS_SAFE. Bump PORTREVISION. The port needs a loving maintainer: services.xml file, for example, is rather outdated: the self-testing included breaks for most online translation services (for others the translation-results are slightly different from those recorded at 2005).
Notes
Notes: svn path=/head/; revision=282621
Diffstat (limited to 'textproc/libtranslate')
-rw-r--r--textproc/libtranslate/Makefile29
-rw-r--r--textproc/libtranslate/distinfo6
-rw-r--r--textproc/libtranslate/files/patch-src_modules_translate-generic-service.c6
-rw-r--r--textproc/libtranslate/files/patch-src_translate-session.c6
4 files changed, 37 insertions, 10 deletions
diff --git a/textproc/libtranslate/Makefile b/textproc/libtranslate/Makefile
index 5ac1745ab7c2..e3777685f66c 100644
--- a/textproc/libtranslate/Makefile
+++ b/textproc/libtranslate/Makefile
@@ -7,10 +7,16 @@
PORTNAME= libtranslate
PORTVERSION= 0.99
-PORTREVISION= 5
+PORTREVISION= 6
CATEGORIES= textproc
MASTER_SITES= ${MASTER_SITE_SAVANNAH}
MASTER_SITE_SUBDIR= ${PORTNAME}
+DISTFILES= ${PORTNAME}-${PORTVERSION}${EXTRACT_SUFX} # May append to this
+
+PATCHFILES= libtranslate-0.99-services.diff libtranslate-0.99-postmarker.diff
+PATCH_SITES= ${MASTER_SITES}
+PATCH_SITE_SUBDIR= ${MASTER_SITE_SUBDIR}
+PATCH_DIST_STRIP= -p1
MAINTAINER= ports@FreeBSD.org
COMMENT= A natural language translation library
@@ -22,12 +28,17 @@ USE_LDCONFIG= yes
CPPFLAGS+= -I${LOCALBASE}/include
LDFLAGS+= -L${LOCALBASE}/lib
CONFIGURE_ARGS= --with-html-dir=${PREFIX}/share/doc
+MAKE_JOBS_SAFE= yes
OPTIONS= GENERIC "generic module" on \
TALKFILTERS "talkfilters module" on
MAN1= translate.1
+post-patch::
+ @${REINPLACE_CMD} -e 's|echo aout|echo elf|' \
+ -e 's|libsoup-2.2|libsoup-2.4|g' ${WRKSRC}/configure
+
.include <bsd.port.pre.mk>
.if defined(WITHOUT_GENERIC)
@@ -36,11 +47,16 @@ PLIST_SUB+= GENERIC="@comment "
.else
PLIST_SUB+= GENERIC=""
USE_GNOME+= libxml2
-LIB_DEPENDS+= soup-2.2:${PORTSDIR}/devel/libsoup22
+LIB_DEPENDS+= soup-2.4:${PORTSDIR}/devel/libsoup
MAN5+= services.xml.5
-
-DEPRECATED= Depends on devel/libsoup22, which is FORBIDDEN
-EXPIRATION_DATE= 2011-10-14
+CPPFLAGS+= -DHAVE_LIBSOUP24
+DISTFILES+= libtranslate-0.99-libsoup24.diff
+EXTRACT_ONLY= ${DISTFILES:M*tar.*}
+# This patching needs to happen AFTER the stock patches were applied:
+post-patch::
+ ${SED} s,SOUP_MESSAGE_RESPONSE_,trans_SOUP_MESSAGE_RESPONSE_,g \
+ ${DISTDIR}/libtranslate-0.99-libsoup24.diff \
+ | ${PATCH} -d ${WRKSRC} -p1
.endif
.if defined(WITHOUT_TALKFILTERS)
@@ -51,7 +67,4 @@ PLIST_SUB+= TALKFILTERS=""
LIB_DEPENDS+= talkfilters:${PORTSDIR}/misc/talkfilters
.endif
-post-patch:
- @${REINPLACE_CMD} -e 's|echo aout|echo elf|' ${WRKSRC}/configure
-
.include <bsd.port.post.mk>
diff --git a/textproc/libtranslate/distinfo b/textproc/libtranslate/distinfo
index 148525edfdd1..5fc6b71447d5 100644
--- a/textproc/libtranslate/distinfo
+++ b/textproc/libtranslate/distinfo
@@ -1,2 +1,8 @@
SHA256 (libtranslate-0.99.tar.gz) = 4b2becb139e51663022d9531c430ebcc81d8b26edc73f6ddc05707ff9950eb34
SIZE (libtranslate-0.99.tar.gz) = 532516
+SHA256 (libtranslate-0.99-libsoup24.diff) = 60a42eda01ca3aa99e773525b99332e6fa122298607a1176c6a493ef462f7992
+SIZE (libtranslate-0.99-libsoup24.diff) = 18354
+SHA256 (libtranslate-0.99-services.diff) = 2777704812ca0c51900a2f50c3e8987cd3124d1712c3450c74b2f1452b67c4a9
+SIZE (libtranslate-0.99-services.diff) = 8744
+SHA256 (libtranslate-0.99-postmarker.diff) = ba3439f5ea952e8f2c24b00df215e18f6177cd99da99ffce10f62a9b29e09664
+SIZE (libtranslate-0.99-postmarker.diff) = 485
diff --git a/textproc/libtranslate/files/patch-src_modules_translate-generic-service.c b/textproc/libtranslate/files/patch-src_modules_translate-generic-service.c
index 1626f25ff71f..54f5eaeba0d0 100644
--- a/textproc/libtranslate/files/patch-src_modules_translate-generic-service.c
+++ b/textproc/libtranslate/files/patch-src_modules_translate-generic-service.c
@@ -1,4 +1,8 @@
---- src/modules/translate-generic-service.c.orig Mon Apr 11 23:08:47 2005
+Copied from
+
+ http://nongnu.askapache.com/libtranslate/libtranslate-0.99-charsetparse.diff
+
+--- src/modules/translate-generic-service.c Mon Apr 11 23:08:47 2005
+++ src/modules/translate-generic-service.c Mon Apr 11 23:15:54 2005
@@ -484,7 +484,7 @@
diff --git a/textproc/libtranslate/files/patch-src_translate-session.c b/textproc/libtranslate/files/patch-src_translate-session.c
index 4011dcd7d5c1..587a64d0584c 100644
--- a/textproc/libtranslate/files/patch-src_translate-session.c
+++ b/textproc/libtranslate/files/patch-src_translate-session.c
@@ -1,4 +1,8 @@
---- src/translate-session.c.orig Mon Apr 11 22:44:53 2005
+Copied from:
+
+ http://nongnu.askapache.com/libtranslate/libtranslate-0.99-condfix.diff
+
+--- src/translate-session.c Mon Apr 11 22:44:53 2005
+++ src/translate-session.c Mon Apr 11 22:51:48 2005
@@ -703,7 +703,14 @@
GError *tmp_err = NULL;