pkgsrc/net/rtorrent/Makefile
tron eb65fab3a3 Improve GCC version handling:
1.) Set minimum required GCC version to 4.1.3 because that is what has
    been tested. Based on the bug-report it also seems that GCC 4.0.1
    doesn't work.
2.) GCC 4.1.3 (as distributed with NetBSD 5.*) works fine under
    NetBSD/macppc as reported by Matthias Kretschmer on IRCnet.
    So don't insist on GCC 4.2.1 for this platform. This fixes seems
    to fix the build as the GCC 4.4.6 package doesn't build for
    this platform.
2012-01-11 22:41:46 +00:00

60 lines
1.5 KiB
Makefile

# $NetBSD: Makefile,v 1.47 2012/01/11 22:41:46 tron Exp $
DISTNAME= rtorrent-0.8.9
PKGREVISION= 2
CATEGORIES= net
MASTER_SITES= ${HOMEPAGE:=downloads/}
OWNER= tron@NetBSD.org
HOMEPAGE= http://libtorrent.rakshasa.no/
COMMENT= Ncurses based torrent client with support for sessions
LICENSE= gnu-gpl-v2
PKG_DESTDIR_SUPPORT= user-destdir
USE_LANGUAGES= c c++
USE_LIBTOOL= yes
USE_NCURSES= yes # chgat
USE_TOOLS+= gmake pkg-config
GNU_CONFIGURE= yes
.include "../../mk/bsd.prefs.mk"
.if ${MACHINE_ARCH} == "alpha" || \
${MACHINE_ARCH} == "i386" || \
${MACHINE_ARCH} == "powerpc" || \
${MACHINE_ARCH} == "x86_64"
GCC_REQD+= 4.1.3
.else
GCC_REQD+= 4.2.1
.endif
.include "../../mk/pthread.buildlink3.mk"
LDFLAGS+= ${PTHREAD_LDFLAGS}
.include "options.mk"
.if !empty(OPSYS:M*BSD) || ${OPSYS} == "Darwin" || ${OPSYS} == "DragonFly"
MESSAGE_SRC= ${PKGDIR}/MESSAGE.BSD
.endif
# See http://libtorrent.rakshasa.no/ticket/77
.include "../../mk/compiler.mk"
.if !empty(CC_VERSION:Mgcc-4.0.*)
CXXFLAGS+= -fpermissive -fno-strength-reduce -fno-thread-jumps \
-fno-inline -fforce-addr
.endif
.if !empty(CC_VERSION:Mgcc-*) && !empty(MACHINE_ARCH:Mi?86)
CXXFLAGS+= -march=i486
.endif
INSTALLATION_DIRS= share/examples/rtorrent
post-install:
${INSTALL_DATA} ${WRKSRC}/doc/rtorrent.rc \
${DESTDIR}${PREFIX}/share/examples/rtorrent
.include "../../devel/ncurses/buildlink3.mk"
.include "../../net/libtorrent/buildlink3.mk"
.include "../../www/curl/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"