|
1 | 1 | # -*-makefile-*- |
2 | | -# $PostgreSQL: pgsql/src/Makefile.global.in,v 1.206 2004/12/1617:48:29 momjian Exp $ |
| 2 | +# $PostgreSQL: pgsql/src/Makefile.global.in,v 1.207 2004/12/1618:13:07 momjian Exp $ |
3 | 3 |
|
4 | 4 | #------------------------------------------------------------------------------ |
5 | 5 | # All PostgreSQL makefiles include this file and use the variables it sets, |
@@ -308,11 +308,17 @@ endif |
308 | 308 |
|
309 | 309 | libpq = -L$(libpq_builddir) -lpq |
310 | 310 |
|
| 311 | +# If doing static linking, shared library dependency can't be |
| 312 | +# used so we specify pthread libs for every usage of libpq |
| 313 | +ifeq ($(enable_shared), no) |
| 314 | +libpq +=$(PTHREAD_LIBS) |
| 315 | +else |
311 | 316 | # AIX libraries do not remember their required libs so we have to force |
312 | 317 | # thread dependent libraires in the link |
313 | 318 | ifeq ($(PORTNAME), aix) |
314 | 319 | libpq +=$(PTHREAD_LIBS) |
315 | 320 | endif |
| 321 | +endif |
316 | 322 |
|
317 | 323 | submake-libpq: |
318 | 324 | $(MAKE) -C$(libpq_builddir) all |
|