summaryrefslogtreecommitdiff
path: root/devel/binutils/Makefile
blob: 1d974a3b85d0d42399e16eebc35e04fc405404ed (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# $NetBSD: Makefile,v 1.24 2005/01/21 20:53:09 tv Exp $

DISTNAME=	binutils-2.15
PKGNAME=	binutils-2.15.0.0
CATEGORIES=	devel
MASTER_SITES=	${MASTER_SITE_GNU:=binutils/}

MAINTAINER=	tech-pkg@NetBSD.org
HOMEPAGE=	http://www.gnu.org/directory/binutils.html
COMMENT=	GNU binary utilities

CONFLICTS=	avr-binutils<2.13.2.1nb1

NOT_FOR_PLATFORM=	Interix-*-*

USE_BUILDLINK3=		yes
USE_PKGLOCALEDIR=	yes

USE_MAKEINFO=		yes
TEXINFO_REQD=		4.0
MAKEFLAGS+=		TEXINFO_LOCALE=no

GNU_CONFIGURE=		yes
CONFIGURE_ARGS+=	--with-lib-path='/lib:/usr/lib'
BINUTILS_PREFIX=	${PREFIX}/${MACHINE_GNU_PLATFORM}

PLIST_SRC=	${PKGDIR}/PLIST.common
PLIST_SRC+=	${WRKDIR}/PLIST_DYNAMIC
PLIST_SRC+=	${PKGDIR}/PLIST.common_end

INFO_FILES=	as.info bfd.info binutils.info ld.info

# gprof (XXX: and others?) cannot be built on all platforms
#
.include "../../mk/bsd.prefs.mk"
.if ${OPSYS} == "IRIX"
PLIST_SUBST+=	NO_GPROF="@comment "
.else
PLIST_SUBST+=	NO_GPROF=""
INFO_FILES+=	gprof.info
.endif

# Prevent the need to run texi2pod.pl and pod2man hence
# the need for perl as build dependency.
#
post-configure:
.for _file_ in ld/ldver.texi ld/ld.1 gas/doc/gasver.texi gas/doc/as.1
	if [ -f ${WRKSRC}/${_file_} ]; then				\
		${TOUCH} ${WRKSRC}/${_file_};				\
	fi
.endfor

post-install:
	${FIND} ${BINUTILS_PREFIX}/lib/ldscripts -type f -print		\
		| ${SORT} -r						\
		| ${SED} 's;${PREFIX}/;;g'				\
		> ${WRKDIR}/PLIST_DYNAMIC

.include "../../mk/bsd.pkg.mk"