|
1 | 1 | # -*-makefile-*-
|
2 |
| -# $PostgreSQL: pgsql/src/Makefile.global.in,v 1.227 2006/09/09 03:15:40 tgl Exp $ |
| 2 | +# $PostgreSQL: pgsql/src/Makefile.global.in,v 1.228 2006/09/10 22:07:02 tgl Exp $ |
3 | 3 |
|
4 | 4 | #------------------------------------------------------------------------------
|
5 | 5 | # All PostgreSQL makefiles include this file and use the variables it sets,
|
@@ -336,23 +336,24 @@ libpq_srcdir = $(top_srcdir)/src/interfaces/libpq
|
336 | 336 | libpq_builddir = $(top_builddir)/src/interfaces/libpq
|
337 | 337 | endif
|
338 | 338 |
|
339 |
| -# This is for use for libraries linking to libpq. Because libpqport |
340 |
| -# isn't created with the same link flags as libpq, it can't be used. |
341 |
| -libpq = -L$(libpq_builddir) -lpq |
| 339 | +# This macro is for use by libraries linking to libpq. (Because libpgport |
| 340 | +# isn't created with the same link flags as libpq, it can't be used.) |
| 341 | +libpq := -L$(libpq_builddir) -lpq |
342 | 342 |
|
343 |
| -# If doing static linking, shared library dependency can't be |
344 |
| -# used so we specify pthread libs for every usage of libpq |
| 343 | +# If doing static linking, shared library dependency info isn't available, |
| 344 | +# so add in the libraries that libpq depends on. |
345 | 345 | ifeq ($(enable_shared), no)
|
346 |
| -libpq += $(PTHREAD_LIBS) |
| 346 | +libpq += $(filter -lintl -lssl -lcrypto -lkrb5 -lcrypt, $(LIBS)) $(PTHREAD_LIBS) |
347 | 347 | else
|
348 |
| -# AIX libraries do not remember their required libs so we have to force |
349 |
| -# thread dependent libraires in the link |
| 348 | +# On AIX even shared libraries do not remember their required libs, |
| 349 | +# so again add in what libpq depends on. |
350 | 350 | ifeq ($(PORTNAME), aix)
|
351 |
| -libpq += $(PTHREAD_LIBS) |
| 351 | +libpq += $(filter -lintl -lssl -lcrypto -lkrb5 -lcrypt, $(LIBS)) $(PTHREAD_LIBS) |
352 | 352 | endif
|
353 | 353 | endif
|
354 | 354 |
|
355 |
| -# Force clients to pull symbols from the non-shared library libpgport |
| 355 | +# This macro is for use by client executables (not libraries) that use libpq. |
| 356 | +# We force clients to pull symbols from the non-shared library libpgport |
356 | 357 | # rather than pulling some libpgport symbols from libpq just because
|
357 | 358 | # libpq uses those functions too. This makes applications less
|
358 | 359 | # dependent on changes in libpq's usage of pgport. To do this we link to
|
|
0 commit comments