pkgsrc-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[pkgsrc/trunk]: pkgsrc/lang/gcc7-libs gcc7-libs: Add package.
details: https://anonhg.NetBSD.org/pkgsrc/rev/88df7037358a
branches: trunk
changeset: 380744:88df7037358a
user: jperkin <jperkin%pkgsrc.org@localhost>
date: Mon May 21 10:05:58 2018 +0000
description:
gcc7-libs: Add package.
This provides the same functionality as the other gcc*-libs packages.
diffstat:
lang/gcc7-libs/DESCR | 7 ++++
lang/gcc7-libs/Makefile | 65 ++++++++++++++++++++++++++++++++++++++++++++
lang/gcc7-libs/buildlink3.mk | 46 +++++++++++++++++++++++++++++++
3 files changed, 118 insertions(+), 0 deletions(-)
diffs (130 lines):
diff -r 3f237d15908b -r 88df7037358a lang/gcc7-libs/DESCR
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/lang/gcc7-libs/DESCR Mon May 21 10:05:58 2018 +0000
@@ -0,0 +1,7 @@
+The GNU Compiler Collection (GCC) includes front ends for C, C++, Objective-C,
+Fortran, and Go, as well as libraries for these languages (libstdc++,
+libgfortran, ...).
+
+This packages provides GCC support libraries in a specific location and allows
+packages to depend on just the libraries rather than having to pull in the full
+GCC package.
diff -r 3f237d15908b -r 88df7037358a lang/gcc7-libs/Makefile
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/lang/gcc7-libs/Makefile Mon May 21 10:05:58 2018 +0000
@@ -0,0 +1,65 @@
+# $NetBSD: Makefile,v 1.1 2018/05/21 10:05:58 jperkin Exp $
+
+GCC_PKGNAME= gcc7
+.include "../../lang/${GCC_PKGNAME}/version.mk"
+
+DISTNAME= gcc-${GCC7_DIST_VERSION}
+PKGNAME= ${GCC_PKGNAME}-libs-${GCC7_DIST_VERSION}
+
+## The PKGREVISION of this package needs to be at least 1 more than the
+## PKGREVISION of the lang/gcc7 package so that with the dependence pattern
+## '{gcc7,gcc7-libs}>=7.3.*' pkg_add will choose gcc7-libs over gcc7.
+PKGREVISION= 2
+
+CATEGORIES= lang
+MASTER_SITES= # empty
+DISTFILES= # empty
+
+MAINTAINER= pkgsrc-users%NetBSD.org@localhost
+HOMEPAGE= http://gcc.gnu.org/
+COMMENT= The GNU Compiler Collection (GCC) support shared libraries
+LICENSE= gnu-gpl-v2 AND gnu-gpl-v3 AND gnu-lgpl-v2 AND gnu-lgpl-v3
+
+USE_TOOLS+= pax
+
+NO_BUILD= yes
+CHECK_SHLIBS= no
+
+## Depend on exactly ${GCC7_DIST_VERSION}.
+BUILD_DEPENDS+= ${GCC_PKGNAME}-${GCC7_DIST_VERSION}{,nb[0-9]*}:../../lang/gcc7
+
+.include "../../mk/bsd.prefs.mk"
+
+LIBGCC_SUBPREFIX= ${GCC_PKGNAME}
+LIBGCC_PREFIX= ${LOCALBASE}/${LIBGCC_SUBPREFIX}
+GCC_TARGET_MACHINE?= ${MACHINE_GNU_PLATFORM}
+BUILD_DEFS+= GCC_TARGET_MACHINE
+
+.if ${SHLIB_TYPE} == "dylib"
+SHLIB_EXT= dylib
+.else
+SHLIB_EXT= so
+.endif
+
+LIBRARY_FILES= ${WRKDIR}/lib_files
+
+GENERATE_PLIST+= ${SED} -e 's,^,${LIBGCC_SUBPREFIX}/${GCC_TARGET_MACHINE}/,' \
+ ${LIBRARY_FILES};
+GENERATE_PLIST+= ${GREP} -q 'lib/' ${LIBRARY_FILES} || \
+ ${ECHO} '@pkgdir ${LIBGCC_SUBPREFIX}/${GCC_TARGET_MACHINE}/lib' ;
+
+${LIBRARY_FILES}:
+ ${PKG_INFO} -qL '${GCC_PKGNAME}-${GCC7_DIST_VERSION}*' | \
+ ${SED} -n -e's,^${LIBGCC_PREFIX}/,,' -e'/libexec\//d' \
+ -e'/libgij/d;/libgcj/d;/libjvm/d' \
+ -e'/lib.*\.${SHLIB_EXT}/p' >${LIBRARY_FILES}
+
+do-install: ${LIBRARY_FILES}
+ ${TEST} -d ${DESTDIR}${LIBGCC_PREFIX}/${GCC_TARGET_MACHINE}/lib || \
+ ${MKDIR} ${DESTDIR}${LIBGCC_PREFIX}/${GCC_TARGET_MACHINE}/lib
+ cd ${LIBGCC_PREFIX} && \
+ ${PAX} -rw ${DESTDIR}${LIBGCC_PREFIX}/${GCC_TARGET_MACHINE} <${LIBRARY_FILES}
+
+.include "../../mk/dlopen.buildlink3.mk"
+.include "../../mk/pthread.buildlink3.mk"
+.include "../../mk/bsd.pkg.mk"
diff -r 3f237d15908b -r 88df7037358a lang/gcc7-libs/buildlink3.mk
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/lang/gcc7-libs/buildlink3.mk Mon May 21 10:05:58 2018 +0000
@@ -0,0 +1,46 @@
+# $NetBSD: buildlink3.mk,v 1.1 2018/05/21 10:05:58 jperkin Exp $
+
+BUILDLINK_TREE+= gcc7-libs
+
+.if !defined(GCC7_LIBS_BUILDLINK3_MK)
+GCC7_LIBS_BUILDLINK3_MK:=
+
+.if !empty(USE_PKGSRC_GCC_RUNTIME:M[Yy][Ee][Ss])
+BUILDLINK_API_DEPENDS.gcc7-libs+= gcc7-libs>=7.3.0
+.else
+BUILDLINK_API_DEPENDS.gcc7-libs+= {gcc7,gcc7-libs}>=7.3.0
+.endif
+BUILDLINK_PKGSRCDIR.gcc7-libs= ../../lang/gcc7-libs
+BUILDLINK_DEPMETHOD.gcc7-libs?= full
+
+BUILDLINK_PASSTHRU_DIRS+= ${BUILDLINK_PREFIX.gcc7-libs}/gcc7
+
+BUILDLINK_FILES.gcc7-libs= #empty
+BUILDLINK_AUTO_VARS.gcc7-libs= no
+
+.if !empty(USE_PKGSRC_GCC_RUNTIME:M[Yy][Ee][Ss])
+# Use custom specs file to ensure we link against pkgsrc libraries.
+SPECS_LIBGCC= ${WRAPPER_DIR}/specs.libgcc
+WRAPPER_TARGETS+= ${SPECS_LIBGCC}
+
+LIBGCC_SUBPREFIX= gcc7
+LIBGCC_PREFIX= ${BUILDLINK_PREFIX.gcc7-libs}/${LIBGCC_SUBPREFIX}
+GCC_TARGET_MACHINE?= ${MACHINE_GNU_PLATFORM}
+
+${SPECS_LIBGCC}:
+ @${ECHO} "*link_libgcc:" >${SPECS_LIBGCC}
+ @${ECHO} "%D ${LINKER_RPATH_FLAG}${LIBGCC_PREFIX}/${GCC_TARGET_MACHINE}/lib/%M" >>${SPECS_LIBGCC}
+
+_WRAP_EXTRA_ARGS.CC+= -specs=${SPECS_LIBGCC}
+_WRAP_EXTRA_ARGS.CXX+= -specs=${SPECS_LIBGCC}
+_WRAP_EXTRA_ARGS.FC+= -specs=${SPECS_LIBGCC}
+CWRAPPERS_APPEND.cc+= -specs=${SPECS_LIBGCC}
+CWRAPPERS_APPEND.cxx+= -specs=${SPECS_LIBGCC}
+CWRAPPERS_APPEND.f77+= -specs=${SPECS_LIBGCC}
+.endif
+
+.include "../../mk/dlopen.buildlink3.mk"
+.include "../../mk/pthread.buildlink3.mk"
+.endif # GCC7_LIBS_BUILDLINK3_MK
+
+BUILDLINK_TREE+= -gcc7-libs
Home |
Main Index |
Thread Index |
Old Index