This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug other/51375] New: different prefix for (s)libdir and bindir, gcc searches for as in wrong directories
- From: "pjodrr at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 01 Dec 2011 09:09:56 +0000
- Subject: [Bug other/51375] New: different prefix for (s)libdir and bindir, gcc searches for as in wrong directories
- Auto-submitted: auto-generated
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51375
Bug #: 51375
Summary: different prefix for (s)libdir and bindir, gcc
searches for as in wrong directories
Classification: Unclassified
Product: gcc
Version: 4.6.2
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: other
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: pjodrr@gmail.com
Hello,
I've setup the source directory to include symbolic links:
bfd -> ../../../binutils/S510-sparcv9/binutils-2.21.1/bfd/
binutils -> ../../../binutils/S510-sparcv9/binutils-2.21.1/binutils/
gas -> ../../../binutils/S510-sparcv9/binutils-2.21.1/gas/
gprof -> ../../../binutils/S510-sparcv9/binutils-2.21.1/gprof/
opcodes -> ../../../binutils/S510-sparcv9/binutils-2.21.1/opcodes/
please not especially that gas is included, so the bootstrap should
build and then also use it after installation.
when I run configure under Solaris 10 / Sparc with these options:
--prefix=%(prefix)s
-q --enable-languages=c,c++
--without-ppl
--without-cloog
--with-mpc=%(prefix)s
--with-mpfr=%(prefix)s
--with-gmp=%(prefix)s
--with-pkgversion="%(packager)s %(packager_version)s"
--with-bugurl=%(packager_bug_reports)s
--with-slibdir=/apps/prod/%(cc_prefix)s/lib
--libdir=/apps/prod/%(cc_prefix)s/lib
--bindir=%(prefix)s/bin
--libexecdir=%(prefix)s/libexec
--includedir=%(prefix)s/include
--datarootdir=%(prefix)s/share
--with-ld=/usr/ccs/bin/ld
--with-gnu-ld=no
I include all options for completeness, but it is important to
note that (s)libdir should be /apps/prod/gcc/4.6.2/lib while
all other directories should start with /apps/local/gcc/4.6.2.
%(prefix)s is /apps/local/gcc/4.6.2 and
%(cc_prefix)s is gcc/4.6.2
The bootstrap and installation works as expected,
but when I then call gcc to compile a simple program like this:
gcc -c -g -I/apps/local/gcc/4.6.2/include -I/apps/prod/gcc/4.6.2/include
conftest.c
I get errors:
/usr/ccs/bin/as: "/var/tmp//cc2wHEMg.s", line 10: error: quoted-string operand
required
/usr/ccs/bin/as: "/var/tmp//cc2wHEMg.s", line 10: error: statement syntax
/usr/ccs/bin/as: "/var/tmp//cc2wHEMg.s", line 11: error: unknown opcode ".loc"
/usr/ccs/bin/as: "/var/tmp//cc2wHEMg.s", line 11: error: statement syntax
...
please note that /usr/ccs/bin/as is reporting this error although gcc
should have used as from the gcc installation directory.
Indeed if I run the gcc command with truss I see where gcc is
searching for as:
922:
stat64("/apps/local/gcc/4.6.2/libexec/gcc/sparc-sun-solaris2.10/4.6.2/as",
0xFFBFE238) Err#2 ENOENT
922:
stat64("/apps/local/gcc/4.6.2/libexec/gcc/sparc-sun-solaris2.10/4.6.2/as",
0xFFBFE238) Err#2 ENOENT
922: stat64("/apps/local/gcc/4.6.2/libexec/gcc/sparc-sun-solaris2.10/as",
0xFFBFE238) Err#2 ENOENT
922: stat64("/apps/prod/gcc/4.6.2/lib/gcc/sparc-sun-solaris2.10/4.6.2/as",
0xFFBFE238) Err#2 ENOENT
922: stat64("/apps/prod/gcc/4.6.2/lib/gcc/sparc-sun-solaris2.10/as",
0xFFBFE238) Err#2 ENOENT
922:
stat64("/apps/prod/gcc/4.6.2/lib/gcc/sparc-sun-solaris2.10/4.6.2/../../../../../../../../sparc-sun-solaris2.10/bin/sparc-sun-solaris2.10/4.6.2/as",
0xFFBFE238) Err#2 ENOENT
922:
stat64("/apps/prod/gcc/4.6.2/lib/gcc/sparc-sun-solaris2.10/4.6.2/../../../../../../../../sparc-sun-solaris2.10/bin/as",
0xFFBFE238) Err#2 ENOENT
922: stat64("/usr/ccs/bin/sparc-sun-solaris2.10/4.6.2/as", 0xFFBFE238) Err#2
ENOENT
922: stat64("/usr/ccs/bin/as", 0xFFBFE238) = 0
but it does not look where it is actually installed, namely:
/apps/local/gcc/4.6.2/sparc-sun-solaris2.10/bin/as
this looks like a bug to me, or am I doing something wrong?
What can I do to make this work?
thanks,
Peter