tech-pkg archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: pkgsrc C compiler
On 2020-06-30 05:11, Hauke Fath wrote:
Hi,
after bootstrapping pkgsrc on !NetBSD, I have in the past installed a
binary gcc package and continued to build with that, just to find later
that it could not be updated from source.
OTOH, switching back from the pkgsrc gcc to the native compiler tends
to result in funky build errors, and appears to require a fresh
bootstrap & installation.
Is there any official word on how to fare with native vs. pkgsrc gcc?
Cheerio.
Hauke
I don't think there's anything official, but we discussed this to death
a few years ago. Handling GCC dependencies is the main issue and they
change frequently. I'm currently using the setup below on NetBSD 8 to
utilize pkgsrc gcc8 in a local unprivileged tree bootstrapped by
auto-pkgsrc-setup (http://netbsd.org/~bacon/). I use the same kind of
setup on CentOS.
I run pkg_chk periodically and haven't had any major problems with upgrades.
JB
# Example /home/bacon/Pkgsrc/pkg/etc/mk.conf file produced by
bootstrap-pkgsrc
# Wed Feb 12 08:28:58 CST 2020
.ifdef BSD_PKG_MK # begin pkgsrc settings
ABI= 64
UNPRIVILEGED= yes
PKG_DBDIR= /home/bacon/Pkgsrc/pkg/pkgdb
LOCALBASE= /home/bacon/Pkgsrc/pkg
VARBASE= /home/bacon/Pkgsrc/pkg/var
PKG_TOOLS_BIN= /home/bacon/Pkgsrc/pkg/sbin
PKGINFODIR= info
PKGMANDIR= man
ALLOW_VULNERABLE_PACKAGES= yes
PKGSRCDIR= /home/bacon/Pkgsrc/pkgsrc
.endif # end pkgsrc settings
.ifdef BSD_PKG_MK # Begin auto-pkgsrc-setup customizations
# X11_TYPE= modular
PREFER_NATIVE= no
PREFER_PKGSRC= yes
PKGSRC_FORTRAN= gfortran
PKG_DEVELOPER= yes
NETBSD_LOGIN_NAME= bacon
FETCH_USING= ftp
SKIP_LICENSE_CHECK= yes
PKG_OPTIONS.libfetch= inet6 openssl
MAKE_JOBS= 1
.if \
empty(PKGPATH:Marchivers/bsdtar) && \
empty(PKGPATH:Marchivers/bzip2) && \
empty(PKGPATH:Marchivers/pax) && \
empty(PKGPATH:Marchivers/xz) && \
empty(PKGPATH:Mconverters/help2man) && \
empty(PKGPATH:Mconverters/libiconv) && \
empty(PKGPATH:Mconverters/p5-Unicode-EastAsianWidth) && \
empty(PKGPATH:Mdatabases/db4) && \
empty(PKGPATH:Mdevel/autoconf) && \
empty(PKGPATH:Mdevel/binutils) && \
empty(PKGPATH:Mdevel/gettext-lib) && \
empty(PKGPATH:Mdevel/gettext-tools) && \
empty(PKGPATH:Mdevel/gmake) && \
empty(PKGPATH:Mdevel/gmp) && \
empty(PKGPATH:Mdevel/gtexinfo) && \
empty(PKGPATH:Mdevel/libffi) && \
empty(PKGPATH:Mdevel/makedepend) && \
empty(PKGPATH:Mdevel/pkgconf) && \
empty(PKGPATH:Mdevel/libtool-base) && \
empty(PKGPATH:Mdevel/m4) && \
empty(PKGPATH:Mdevel/ncurses) && \
empty(PKGPATH:Mdevel/nbpatch) && \
empty(PKGPATH:Mdevel/p5-CPAN-Meta) && \
empty(PKGPATH:Mdevel/p5-Module-Build) && \
empty(PKGPATH:Mdevel/p5-Perl4-CoreLibs) && \
empty(PKGPATH:Mdevel/p5-Scalar-List-Utils) && \
empty(PKGPATH:Mdevel/p5-gettext) && \
empty(PKGPATH:Mdevel/p5-inc-latest) && \
empty(PKGPATH:Mdevel/readline) && \
empty(PKGPATH:Mdevel/zlib) && \
empty(PKGPATH:Mlang/gcc5) && \
empty(PKGPATH:Mlang/gcc5-libs) && \
empty(PKGPATH:Mlang/perl5) && \
empty(PKGPATH:Mlang/python27) && \
empty(PKGPATH:Mmath/cloog) && \
empty(PKGPATH:Mmath/isl) && \
empty(PKGPATH:Mmath/mpcomplex) && \
empty(PKGPATH:Mmath/mpfr) && \
empty(PKGPATH:Mmisc/p5-Locale-libintl) && \
empty(PKGPATH:Mnet/libfetch) && \
empty(PKGPATH:Mpkgtools/cwrappers) && \
empty(PKGPATH:Mpkgtools/digest) && \
empty(PKGPATH:Mpkgtools/pkg_install) && \
empty(PKGPATH:Mpkgtools/pkg_install-info) && \
empty(PKGPATH:Mpkgtools/pkgin) && \
empty(PKGPATH:Msecurity/mozilla-rootcerts) && \
empty(PKGPATH:Msecurity/openssl) && \
empty(PKGPATH:Msysutils/checkperms) && \
empty(PKGPATH:Mtextproc/gsed) && \
empty(PKGPATH:Mtextproc/p5-Text-Unidecode) && \
empty(PKGPATH:Mx11/xorgproto)
GCC_REQD+=8
.endif # GCC_REQD
# Keep this in sync with pbulk-setup
.if exists(/etc/redhat-release) && !empty(PKGPATH:Mlang/gcc*)
# RHEL systems may have an outdated "as" that cannot translate instructions
# from current GCC code generators, so force pkgsrc binutils.
CONFIGURE_ARGS+= --with-gnu-as --with-as=${PREFIX}/bin/gas
CONFIGURE_ARGS+= --with-gnu-ld --with-ld=${PREFIX}/bin/gld
BUILDLINK_DEPMETHOD.binutils= full
. include "../../devel/binutils/buildlink3.mk"
# pkgsrc gcc packages don't install libgcc_s on some platforms, to
# avoid problems when mixing compiler versions. This breaks our use
# of pkgsrc gcc on EL.
PKG_DEFAULT_OPTIONS+= always-libgcc
.endif
.endif # Pkgsrc customizations
Home |
Main Index |
Thread Index |
Old Index