aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--net-p2p/libbt/Makefile16
-rw-r--r--net-p2p/libbt/distinfo4
-rw-r--r--net-p2p/libbt/files/patch-include::bterror.h18
-rw-r--r--net-p2p/libbt/files/patch-src::Makefile.in19
-rw-r--r--net-p2p/libbt/files/patch-src::bitset.c12
-rw-r--r--net-p2p/libbt/files/patch-src::bterror.c13
-rw-r--r--net-p2p/libbt/files/patch-src::peer.c17
-rw-r--r--net-p2p/libbt/files/patch-src::stream.c16
-rw-r--r--net-p2p/libbt/pkg-plist3
-rw-r--r--net/libbt/Makefile16
-rw-r--r--net/libbt/distinfo4
-rw-r--r--net/libbt/files/patch-include::bterror.h18
-rw-r--r--net/libbt/files/patch-src::Makefile.in19
-rw-r--r--net/libbt/files/patch-src::bitset.c12
-rw-r--r--net/libbt/files/patch-src::bterror.c13
-rw-r--r--net/libbt/files/patch-src::peer.c17
-rw-r--r--net/libbt/files/patch-src::stream.c16
-rw-r--r--net/libbt/pkg-plist3
18 files changed, 34 insertions, 202 deletions
diff --git a/net-p2p/libbt/Makefile b/net-p2p/libbt/Makefile
index 714673129079..e96c46a3a32d 100644
--- a/net-p2p/libbt/Makefile
+++ b/net-p2p/libbt/Makefile
@@ -6,11 +6,11 @@
#
PORTNAME= libbt
-PORTVERSION= 0.02
+PORTVERSION= 0.03
CATEGORIES= net devel
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= ${PORTNAME}
-EXTRACT_SUFX= .tgz
+DISTNAME= ${PORTNAME}.${PORTVERSION}
MAINTAINER= flz@xbsd.org
COMMENT= C library implementing the core BitTorrent protocol
@@ -21,13 +21,21 @@ LIB_DEPENDS= uuid.1:${PORTSDIR}/sysutils/e2fsprogs \
WRKSRC= ${WRKDIR}/${PORTNAME}
GNU_CONFIGURE= yes
+USE_GMAKE= yes
+USE_REINPLACE= yes
-CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \
- LDFLAGS="-L${LOCALBASE}/lib"
+CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" LDFLAGS="-L${LOCALBASE}/lib"
+
+post-patch:
+ @${REINPLACE_CMD} -e 's|\(makedepend --\)|\1 \@CPPFLAGS\@|' ${WRKSRC}/src/Makefile.in
+ @${REINPLACE_CMD} -e 's|\(CFLAGS:=\)|\1\@CFLAGS\@|' ${WRKSRC}/src/Makefile.in
do-install:
${INSTALL_DATA} ${WRKSRC}/src/libbt.a ${PREFIX}/lib
${MKDIR} ${PREFIX}/include/libbt
+.for i in btcheck btget btlist
+ ${INSTALL_PROGRAM} ${WRKSRC}/src/${i} ${PREFIX}/bin
+.endfor
.for i in benc.h bitset.h bterror.h bts.h context.h peer.h random.h segmenter.h strbuf.h stream.h types.h util.h
${INSTALL_DATA} ${WRKSRC}/include/${i} ${PREFIX}/include/libbt
.endfor
diff --git a/net-p2p/libbt/distinfo b/net-p2p/libbt/distinfo
index a7f9cb54c38d..d29cc2dd343f 100644
--- a/net-p2p/libbt/distinfo
+++ b/net-p2p/libbt/distinfo
@@ -1,2 +1,2 @@
-MD5 (libbt-0.02.tgz) = a954666cb53b7a35f1793b531a6430bd
-SIZE (libbt-0.02.tgz) = 333463
+MD5 (libbt.0.03.tar.gz) = 8c2ff3afcef27441fc398105ef241a6e
+SIZE (libbt.0.03.tar.gz) = 395161
diff --git a/net-p2p/libbt/files/patch-include::bterror.h b/net-p2p/libbt/files/patch-include::bterror.h
deleted file mode 100644
index 1c63711ede3d..000000000000
--- a/net-p2p/libbt/files/patch-include::bterror.h
+++ /dev/null
@@ -1,18 +0,0 @@
---- include/bterror.h.old Thu Feb 26 17:38:32 2004
-+++ include/bterror.h Thu Feb 26 17:38:53 2004
-@@ -15,15 +15,6 @@
- BTERR_LAST
- };
-
--#ifdef BTERROR_BODY
--char *bterror_string[] = {
-- "Bad protocol ID on peer connection",
-- "Unrecognized Flags in peer protocol handshake",
-- "Peer hash value doesn't match my hash value",
-- "Peer disconnected after repeated errors"
--};
--#else
- extern char *bterror_string[];
--#endif
-
- #endif
diff --git a/net-p2p/libbt/files/patch-src::Makefile.in b/net-p2p/libbt/files/patch-src::Makefile.in
deleted file mode 100644
index 388c14074f76..000000000000
--- a/net-p2p/libbt/files/patch-src::Makefile.in
+++ /dev/null
@@ -1,19 +0,0 @@
---- src/Makefile.in.old Thu Feb 26 18:27:14 2004
-+++ src/Makefile.in Thu Feb 26 18:28:04 2004
-@@ -1,8 +1,8 @@
--OBJS=benc.o bts.o types.o random.o strbuf.o stream.o peer.o segmenter.o util.o bitset.o context.o
--CFLAGS=-Wall -g -I../include
-+OBJS=bterror.o benc.o bts.o types.o random.o strbuf.o stream.o peer.o segmenter.o util.o bitset.o context.o
-+CFLAGS=@CFLAGS@ -Wall -I../include -I${PREFIX}/include
- LIBS=@LIBS@ `curl-config --libs`
-
--all: btlist btget btcheck
-+all: libbt.a
- btcheck: btcheck.c libbt.a
- gcc ${CFLAGS} btcheck.c ${LIBS} -lbt -L. -o btcheck
-
-@@ -20,3 +20,4 @@
-
- libbt.a: ${OBJS}
- ar rc $@ ${OBJS}
-+ ranlib libbt.a
diff --git a/net-p2p/libbt/files/patch-src::bitset.c b/net-p2p/libbt/files/patch-src::bitset.c
deleted file mode 100644
index 3b616150dcd6..000000000000
--- a/net-p2p/libbt/files/patch-src::bitset.c
+++ /dev/null
@@ -1,12 +0,0 @@
---- src/bitset.c.old Thu Feb 26 15:21:52 2004
-+++ src/bitset.c Thu Feb 26 15:22:14 2004
-@@ -1,8 +1,6 @@
- #include "config.h"
-
--#if HAVE_MALLOC_H
--#include <malloc.h>
--#endif
-+#include <stdlib.h>
- #include <assert.h>
- #include <stdio.h>
- #include "bitset.h"
diff --git a/net-p2p/libbt/files/patch-src::bterror.c b/net-p2p/libbt/files/patch-src::bterror.c
deleted file mode 100644
index bf255821bb74..000000000000
--- a/net-p2p/libbt/files/patch-src::bterror.c
+++ /dev/null
@@ -1,13 +0,0 @@
---- src/bterror.c.old Thu Feb 26 17:39:15 2004
-+++ src/bterror.c Thu Feb 26 17:39:54 2004
-@@ -1,3 +1,9 @@
- /* bterror.c */
--#define BTERROR_BODY
- #include "bterror.h"
-+
-+char *bterror_string[] = {
-+ "Bad protocol ID on peer connection",
-+ "Unrecognized Flags in peer protocol handshake",
-+ "Peer hash value doesn't match my hash value",
-+ "Peer disconnected after repeated errors"
-+};
diff --git a/net-p2p/libbt/files/patch-src::peer.c b/net-p2p/libbt/files/patch-src::peer.c
deleted file mode 100644
index 207e4fde9d7e..000000000000
--- a/net-p2p/libbt/files/patch-src::peer.c
+++ /dev/null
@@ -1,17 +0,0 @@
---- src/peer.c.old Thu Feb 26 17:34:55 2004
-+++ src/peer.c Thu Feb 26 17:35:21 2004
-@@ -1,5 +1,6 @@
- #include "config.h"
-
-+#include <sys/types.h>
- #if WIN32
- // #include <winsock2.h>
- #else
-@@ -13,7 +14,6 @@
- #include <fcntl.h>
- #endif
- #endif
--#include <sys/types.h>
- #include <string.h>
- #include <errno.h>
- #include <time.h>
diff --git a/net-p2p/libbt/files/patch-src::stream.c b/net-p2p/libbt/files/patch-src::stream.c
deleted file mode 100644
index 7397921d7a43..000000000000
--- a/net-p2p/libbt/files/patch-src::stream.c
+++ /dev/null
@@ -1,16 +0,0 @@
---- src/stream.c.old Thu Feb 26 17:34:48 2004
-+++ src/stream.c Thu Feb 26 17:35:11 2004
-@@ -1,4 +1,5 @@
- #include "config.h"
-+#include <sys/types.h>
- #include <errno.h>
- #include <string.h>
- #include <stdarg.h>
-@@ -14,7 +15,6 @@
- #include <unistd.h>
- #endif
- #endif
--#include <sys/types.h>
- #include "bterror.h"
- #include "stream.h"
- #undef DEBUG_STREAM
diff --git a/net-p2p/libbt/pkg-plist b/net-p2p/libbt/pkg-plist
index 5ed8658814e4..87f044a64f99 100644
--- a/net-p2p/libbt/pkg-plist
+++ b/net-p2p/libbt/pkg-plist
@@ -1,3 +1,6 @@
+bin/btcheck
+bin/btget
+bin/btlist
include/libbt/benc.h
include/libbt/bitset.h
include/libbt/bterror.h
diff --git a/net/libbt/Makefile b/net/libbt/Makefile
index 714673129079..e96c46a3a32d 100644
--- a/net/libbt/Makefile
+++ b/net/libbt/Makefile
@@ -6,11 +6,11 @@
#
PORTNAME= libbt
-PORTVERSION= 0.02
+PORTVERSION= 0.03
CATEGORIES= net devel
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= ${PORTNAME}
-EXTRACT_SUFX= .tgz
+DISTNAME= ${PORTNAME}.${PORTVERSION}
MAINTAINER= flz@xbsd.org
COMMENT= C library implementing the core BitTorrent protocol
@@ -21,13 +21,21 @@ LIB_DEPENDS= uuid.1:${PORTSDIR}/sysutils/e2fsprogs \
WRKSRC= ${WRKDIR}/${PORTNAME}
GNU_CONFIGURE= yes
+USE_GMAKE= yes
+USE_REINPLACE= yes
-CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \
- LDFLAGS="-L${LOCALBASE}/lib"
+CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" LDFLAGS="-L${LOCALBASE}/lib"
+
+post-patch:
+ @${REINPLACE_CMD} -e 's|\(makedepend --\)|\1 \@CPPFLAGS\@|' ${WRKSRC}/src/Makefile.in
+ @${REINPLACE_CMD} -e 's|\(CFLAGS:=\)|\1\@CFLAGS\@|' ${WRKSRC}/src/Makefile.in
do-install:
${INSTALL_DATA} ${WRKSRC}/src/libbt.a ${PREFIX}/lib
${MKDIR} ${PREFIX}/include/libbt
+.for i in btcheck btget btlist
+ ${INSTALL_PROGRAM} ${WRKSRC}/src/${i} ${PREFIX}/bin
+.endfor
.for i in benc.h bitset.h bterror.h bts.h context.h peer.h random.h segmenter.h strbuf.h stream.h types.h util.h
${INSTALL_DATA} ${WRKSRC}/include/${i} ${PREFIX}/include/libbt
.endfor
diff --git a/net/libbt/distinfo b/net/libbt/distinfo
index a7f9cb54c38d..d29cc2dd343f 100644
--- a/net/libbt/distinfo
+++ b/net/libbt/distinfo
@@ -1,2 +1,2 @@
-MD5 (libbt-0.02.tgz) = a954666cb53b7a35f1793b531a6430bd
-SIZE (libbt-0.02.tgz) = 333463
+MD5 (libbt.0.03.tar.gz) = 8c2ff3afcef27441fc398105ef241a6e
+SIZE (libbt.0.03.tar.gz) = 395161
diff --git a/net/libbt/files/patch-include::bterror.h b/net/libbt/files/patch-include::bterror.h
deleted file mode 100644
index 1c63711ede3d..000000000000
--- a/net/libbt/files/patch-include::bterror.h
+++ /dev/null
@@ -1,18 +0,0 @@
---- include/bterror.h.old Thu Feb 26 17:38:32 2004
-+++ include/bterror.h Thu Feb 26 17:38:53 2004
-@@ -15,15 +15,6 @@
- BTERR_LAST
- };
-
--#ifdef BTERROR_BODY
--char *bterror_string[] = {
-- "Bad protocol ID on peer connection",
-- "Unrecognized Flags in peer protocol handshake",
-- "Peer hash value doesn't match my hash value",
-- "Peer disconnected after repeated errors"
--};
--#else
- extern char *bterror_string[];
--#endif
-
- #endif
diff --git a/net/libbt/files/patch-src::Makefile.in b/net/libbt/files/patch-src::Makefile.in
deleted file mode 100644
index 388c14074f76..000000000000
--- a/net/libbt/files/patch-src::Makefile.in
+++ /dev/null
@@ -1,19 +0,0 @@
---- src/Makefile.in.old Thu Feb 26 18:27:14 2004
-+++ src/Makefile.in Thu Feb 26 18:28:04 2004
-@@ -1,8 +1,8 @@
--OBJS=benc.o bts.o types.o random.o strbuf.o stream.o peer.o segmenter.o util.o bitset.o context.o
--CFLAGS=-Wall -g -I../include
-+OBJS=bterror.o benc.o bts.o types.o random.o strbuf.o stream.o peer.o segmenter.o util.o bitset.o context.o
-+CFLAGS=@CFLAGS@ -Wall -I../include -I${PREFIX}/include
- LIBS=@LIBS@ `curl-config --libs`
-
--all: btlist btget btcheck
-+all: libbt.a
- btcheck: btcheck.c libbt.a
- gcc ${CFLAGS} btcheck.c ${LIBS} -lbt -L. -o btcheck
-
-@@ -20,3 +20,4 @@
-
- libbt.a: ${OBJS}
- ar rc $@ ${OBJS}
-+ ranlib libbt.a
diff --git a/net/libbt/files/patch-src::bitset.c b/net/libbt/files/patch-src::bitset.c
deleted file mode 100644
index 3b616150dcd6..000000000000
--- a/net/libbt/files/patch-src::bitset.c
+++ /dev/null
@@ -1,12 +0,0 @@
---- src/bitset.c.old Thu Feb 26 15:21:52 2004
-+++ src/bitset.c Thu Feb 26 15:22:14 2004
-@@ -1,8 +1,6 @@
- #include "config.h"
-
--#if HAVE_MALLOC_H
--#include <malloc.h>
--#endif
-+#include <stdlib.h>
- #include <assert.h>
- #include <stdio.h>
- #include "bitset.h"
diff --git a/net/libbt/files/patch-src::bterror.c b/net/libbt/files/patch-src::bterror.c
deleted file mode 100644
index bf255821bb74..000000000000
--- a/net/libbt/files/patch-src::bterror.c
+++ /dev/null
@@ -1,13 +0,0 @@
---- src/bterror.c.old Thu Feb 26 17:39:15 2004
-+++ src/bterror.c Thu Feb 26 17:39:54 2004
-@@ -1,3 +1,9 @@
- /* bterror.c */
--#define BTERROR_BODY
- #include "bterror.h"
-+
-+char *bterror_string[] = {
-+ "Bad protocol ID on peer connection",
-+ "Unrecognized Flags in peer protocol handshake",
-+ "Peer hash value doesn't match my hash value",
-+ "Peer disconnected after repeated errors"
-+};
diff --git a/net/libbt/files/patch-src::peer.c b/net/libbt/files/patch-src::peer.c
deleted file mode 100644
index 207e4fde9d7e..000000000000
--- a/net/libbt/files/patch-src::peer.c
+++ /dev/null
@@ -1,17 +0,0 @@
---- src/peer.c.old Thu Feb 26 17:34:55 2004
-+++ src/peer.c Thu Feb 26 17:35:21 2004
-@@ -1,5 +1,6 @@
- #include "config.h"
-
-+#include <sys/types.h>
- #if WIN32
- // #include <winsock2.h>
- #else
-@@ -13,7 +14,6 @@
- #include <fcntl.h>
- #endif
- #endif
--#include <sys/types.h>
- #include <string.h>
- #include <errno.h>
- #include <time.h>
diff --git a/net/libbt/files/patch-src::stream.c b/net/libbt/files/patch-src::stream.c
deleted file mode 100644
index 7397921d7a43..000000000000
--- a/net/libbt/files/patch-src::stream.c
+++ /dev/null
@@ -1,16 +0,0 @@
---- src/stream.c.old Thu Feb 26 17:34:48 2004
-+++ src/stream.c Thu Feb 26 17:35:11 2004
-@@ -1,4 +1,5 @@
- #include "config.h"
-+#include <sys/types.h>
- #include <errno.h>
- #include <string.h>
- #include <stdarg.h>
-@@ -14,7 +15,6 @@
- #include <unistd.h>
- #endif
- #endif
--#include <sys/types.h>
- #include "bterror.h"
- #include "stream.h"
- #undef DEBUG_STREAM
diff --git a/net/libbt/pkg-plist b/net/libbt/pkg-plist
index 5ed8658814e4..87f044a64f99 100644
--- a/net/libbt/pkg-plist
+++ b/net/libbt/pkg-plist
@@ -1,3 +1,6 @@
+bin/btcheck
+bin/btget
+bin/btlist
include/libbt/benc.h
include/libbt/bitset.h
include/libbt/bterror.h