Subject: Re: pkgsrc compilation failure on redhat linux 7.2
To: None <email@example.com>
From: Jan Schaumann <firstname.lastname@example.org>
Date: 12/18/2002 13:30:24
Niilo Kajander <email@example.com> wrote:
> On OpenBSD/i386 it worked fine, some packages got built nicely but
> converters/libiconv didn't.
> cc -I. -I. -I.. -I./.. -O1 -march=pentiumpro
> -DHAVE_CONFIG_H -DLIBDIR=\"/usr/pkg/lib\" -c ./localcharset.c -fPIC
> -DPIC -o .libs/localcharset.o ./localcharset.c: In function
> `get_charset_aliases': ./localcharset.c:115: syntax error before `/'
> *** Error code 1
This looks like the same error I'm getting on Irix. As far as I can
tell, it's got to do with buildlink2's substitution of
In /usr/pkgsrc/converters/work/.buildlink/bin/.logic-trans you probably
-DLIBDIR=\"/usr/pkg/lib\") arg="-DLIBDIR=\\\"/usr/pkg/lib\\\"" ;; #1
-DLIBDIR=\\/usr/pkg/lib\\) arg="-DLIBDIR=\\\/usr/pkg/lib\\\" ;; #1
Note that the first one is correct, while the second one is a false
duplicate (I believe), leading to the above error.
If you add 'set -x' to your /usr/pkg/bin/libtool and to
/usr/pkgsrc/mk/buildlink2/wrapper.sh you will get a lot of debugging
output that shows how where and when the paramter is substituted. Maybe
that can help to track down the problem. You may also want to set
PKG_DEBUG_LEVEL=2 in /etc/mk.conf. (It generates a lot of
debugging output, you probably want to redirect all output (stdout and
stderr) to a log file.)
A common mistake that people make when trying to design something completely
foolproof is to underestimate the ingenuity of complete fools.