pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

GCC_REQD not working (pkgsrc issue?) on NetBSD 6_Stable



Apparently putting GCC_REQD+=4.7 (or 4.8) in a pkgsrc package Makefile is
supposed cause builds to use a particular version of gcc.

This does not appear to work for me...

Can anyone give me some pointers (things to try/investigate) to make this
work?

the original chain is below, but I seem to be stuck on an unrelated
problem so am starting a different subject...
------ Makefile excerpt -------
# $NetBSD: Makefile,v 1.66 2013/10/29 19:05:23 drochner Exp $

.include "../../print/poppler/Makefile.common"

COMMENT=                PDF rendering library
MAINTAINER=             reed%reedmedia.net@localhost

GCC_REQD=               4.8
USE_TOOLS+=             gmake gcc

------

# make show-var VARNAME=GCC_REQD
4.8
------

but build scripts still use gcc builtin
# gcc --version
gcc (NetBSD nb2 20110806) 4.5.3


---------------------------- Original Message ----------------------------
Subject: Re: poppler-0.54.0 Build Failure on NetBSD 6_Stable (gcc version
issue?)
From:    "J. Lewis Muir" <jlmuir%imca-cat.org@localhost>
Date:    Mon, May 22, 2017 5:35 pm
To:      yancm%sdf.org@localhost
Cc:      pkgsrc-users%netbsd.org@localhost
--------------------------------------------------------------------------

On 05/22, yancm%sdf.org@localhost wrote:
> > On Fri, May 19, 2017 at 02:48:57PM -0000, yancm%sdf.org@localhost wrote:
> >> > On Fri, May 19, 2017 at 02:23:57PM -0000, yancm%sdf.org@localhost wrote:
> [...]
> >> >> cc1plus: error: unrecognized command line option "-std=c++11"
> >> [...]
> >> > Add a line to Makefile
> >> > GCC_REQD+=4.7
> >>
> >> This had no effect? Sorry, but I'm not too familiar with pkgsrc
> >> hacking...
> >> do I need to do something more than just add this line in Makefile in
> >> poplar?
> >
> > I think you will need to 'make clean -C /path/to/pkgsrc/*/poppler/' for
> > it to take effect
>
> putting GCC_REQD+=4.7 in the poppler Makefile did absolutely nothing for
> my build. Cleaning had no effect.
>
> I then attempted to build gcc48 manually, it installs in /usr/pkg/gcc48
> which I added to my path, but still the build script picks up only the
> base gcc, not the pkgsrc one...I'm still stuck.

Since a goal of pkgsrc is reproducible builds, it ignores your path
and lots of other things too when building, so adding that to your
path won't work.  This isolation functionality is known as the wrapper
framework [1].  You need to get pkgsrc to understand the compiler
requirement you're trying to specify for the poppler package which is
what coypu@ was suggesting with the GCC_REQD variable.  Why that's not
working for you, though, I don't know.

Lewis




Home | Main Index | Thread Index | Old Index