1 # $NetBSD: Makefile,v 1.13 2013/04/18 07:58:33 sbd Exp $
4 .
include "../../lang/${GCC_PKGNAME}/version.mk"
6 DISTNAME
= gcc-
${GCC47_DIST_VERSION}
7 PKGNAME
= ${GCC_PKGNAME}-libs-
${GCC47_DIST_VERSION}
8 ## The PKGREVISION of this package needs to be at least 1 more than the
9 ## PKGREVISION of the lang/gcc47 package so that with the dependence pattern
10 ## '{gcc47,gcc47-libs}>=4.7.*' pkg_all will choose gcc47-libs over gcc47.
16 MAINTAINER
= sbd@NetBSD.org
17 HOMEPAGE
= http
://gcc.gnu.org
/
18 COMMENT
= The GNU Compiler Collection
(GCC
) support shared libraries
19 LICENSE
= gnu-gpl-v2 AND gnu-gpl-v3 AND gnu-lgpl-v2 AND gnu-lgpl-v3
25 ## Depend on exactly ${GCC47_DIST_VERSION}.
26 BUILD_DEPENDS
+= ${GCC_PKGNAME}-${GCC47_DIST_VERSION}{,nb
[0-9]*}:..
/..
/lang
/gcc47
28 .
include "../../mk/bsd.prefs.mk"
30 FIND_PREFIX
:= GCC_PKG_PREFIX
=${GCC_PKGNAME}-${GCC47_DIST_VERSION}*
31 .
include "../../mk/find-prefix.mk"
33 GCC_SUBPREFIX
= ${GCC_PKGNAME}
34 GCC_PREFIX
= ${GCC_PKG_PREFIX}/${GCC_SUBPREFIX}
35 GCC_TARGET_MACHINE?
= ${MACHINE_GNU_PLATFORM}
36 BUILD_DEFS
+= GCC_TARGET_MACHINE
38 .
include "../../mk/bsd.prefs.mk"
39 .if
${_OPSYS_SHLIB_TYPE} == "dylib"
45 LIBRARY_FILES
= ${WRKDIR}/lib_files
47 GENERATE_PLIST
+= ${SED} -e
's,^,${GCC_SUBPREFIX}/${GCC_TARGET_MACHINE}/,' \
49 GENERATE_PLIST
+= ${GREP} -q
'lib/' ${LIBRARY_FILES} || \
50 ${ECHO} '@pkgdir ${GCC_SUBPREFIX}/${GCC_TARGET_MACHINE}/lib' ;
53 ${PKG_INFO} -qL
'${GCC_PKGNAME}-${GCC47_DIST_VERSION}*' | \
54 ${SED} -n
-e
's,^${GCC_PREFIX}/,,' -e
'/libexec\//d' \
55 -e
'/libgij/d;/libgcj/d;/libjvm/d' \
56 -e
'/lib.*\.${SHLIB_EXT}/p' >${LIBRARY_FILES}
58 do-install
: ${LIBRARY_FILES}
59 ${TEST} -d
${DESTDIR}${GCC_PREFIX}/${GCC_TARGET_MACHINE}/lib || \
60 ${MKDIR} ${DESTDIR}${GCC_PREFIX}/${GCC_TARGET_MACHINE}/lib
62 ${PAX} -rw
${DESTDIR}${GCC_PREFIX}/${GCC_TARGET_MACHINE} <${LIBRARY_FILES}
64 .
include "../../mk/dlopen.buildlink3.mk"
65 .
include "../../mk/pthread.buildlink3.mk"
66 .
include "../../mk/bsd.pkg.mk"