Skip to content

Commit 51d6c0f

Browse files
committed
Merge branch 'ab/deprecate-R-for-dynpath'
The way of specifying the path to find dynamic libraries at runtime has been simplified. The old default to pass -R/path/to/dir has been replaced with the new default to pass -Wl,-rpath,/path/to/dir, which is the more recent GCC uses. Those who need to build with an old GCC can still use "CC_LD_DYNPATH=-R" * ab/deprecate-R-for-dynpath: Makefile: remove the NO_R_TO_GCC_LINKER flag
2 parents 2a983b2 + 0f50c8e commit 51d6c0f

File tree

1 file changed

+1
-14
lines changed

1 file changed

+1
-14
lines changed

Makefile

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -265,10 +265,6 @@ all::
265265
#
266266
# Define NO_DEFLATE_BOUND if your zlib does not have deflateBound.
267267
#
268-
# Define NO_R_TO_GCC_LINKER if your gcc does not like "-R/path/lib"
269-
# that tells runtime paths to dynamic libraries;
270-
# "-Wl,-rpath=/path/lib" is used instead.
271-
#
272268
# Define NO_NORETURN if using buggy versions of gcc 4.6+ and profile feedback,
273269
# as the compiler can crash (http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49299)
274270
#
@@ -1158,6 +1154,7 @@ endif
11581154
# which'll override these defaults.
11591155
CFLAGS = -g -O2 -Wall
11601156
LDFLAGS =
1157+
CC_LD_DYNPATH = -Wl,-rpath,
11611158
BASIC_CFLAGS = -I.
11621159
BASIC_LDFLAGS =
11631160

@@ -1288,16 +1285,6 @@ ifeq ($(uname_S),Darwin)
12881285
PTHREAD_LIBS =
12891286
endif
12901287

1291-
ifndef CC_LD_DYNPATH
1292-
ifdef NO_R_TO_GCC_LINKER
1293-
# Some gcc does not accept and pass -R to the linker to specify
1294-
# the runtime dynamic library path.
1295-
CC_LD_DYNPATH = -Wl,-rpath,
1296-
else
1297-
CC_LD_DYNPATH = -R
1298-
endif
1299-
endif
1300-
13011288
ifdef NO_LIBGEN_H
13021289
COMPAT_CFLAGS += -DNO_LIBGEN_H
13031290
COMPAT_OBJS += compat/basename.o

0 commit comments

Comments
 (0)