build: don't -L/usr/pkg/lib

You might have to update the compiler-rt package! See UPDATING.

	. the purpose of this -L was solely to find compiler-rt, which contains
	  runtime support code for clang-compiled binaries
	. this also makes all other packaged libraries visible, however
	. it is cleaner to isolate the base system from packages, and so
	  compiler-rt puts itself in /usr/pkg/compiler-rt/lib/ too, which the
	  base system henceforth uses exclusively
	. e.g. this solves a link failure when libfetch is installed as a
	  package
	. the new compiler-rt package also puts itself in /usr/pkg/lib for 'old'
	  systems; that is harmless. The benefit of 'new' systems is that the other
	  packages are hidden.
This commit is contained in:
Ben Gras 2012-03-06 17:57:34 +01:00
parent a63151d3f8
commit a5190194a0
3 changed files with 8 additions and 2 deletions

View file

@ -1,3 +1,9 @@
20120306:
The base system only looks in /usr/pkg/compiler-rt/lib now, so
-L/usr/pkg/lib is gone.
Please make sure you have the latest compiler-rt package
installed.
20120214:
Compiling everything with clang (previous entry) depends on a
relatively new clang package. Please make sure you have at

View file

@ -26,7 +26,7 @@ DPADD+= ${LIBMINLIB}
.if ${CC} == "gcc"
LDADD+= -lgcc -lsys -lgcc -lminc
.elif ${CC} == "clang"
LDADD+= -L/usr/pkg/lib -L/usr/pkg/compiler-rt/lib -lCompilerRT-Generic -lsys -lCompilerRT-Generic -lminc
LDADD+= -L/usr/pkg/compiler-rt/lib -lCompilerRT-Generic -lsys -lCompilerRT-Generic -lminc
DPADD+= ${LIBC}
.endif

View file

@ -4,7 +4,7 @@
.if ${CC} == "gcc"
LDADD+= -nodefaultlibs -lgcc -lsys -lgcc -lminc
.elif ${CC} == "clang"
LDADD+= -nodefaultlibs -L/usr/pkg/lib -L/usr/pkg/compiler-rt/lib -lCompilerRT-Generic -lsys -lCompilerRT-Generic -lminc
LDADD+= -nodefaultlibs -L/usr/pkg/compiler-rt/lib -lCompilerRT-Generic -lsys -lCompilerRT-Generic -lminc
.endif
.include <bsd.prog.mk>