2020-09-24 22:29:13 +03:00
|
|
|
subdir = .
|
|
|
|
top_builddir = .
|
|
|
|
include src/Makefile.global
|
|
|
|
|
|
|
|
ifeq ($(LIBPQ_LIBRARY_TYPE), static)
|
|
|
|
LIBPQ_INSTALL_LIBS = install-stlib
|
|
|
|
endif
|
|
|
|
|
2021-04-20 07:19:44 +07:00
|
|
|
ifeq ($(LIBPQ_LIBRARY_TYPE), shared)
|
2023-06-01 04:55:03 +02:00
|
|
|
ifeq ($(LIBPQ_USING_MINGW), yes)
|
2021-04-20 07:19:44 +07:00
|
|
|
# The import library name is the same as the static library name
|
|
|
|
EXTRA_TARGET = install-lib-static
|
|
|
|
endif
|
|
|
|
endif
|
|
|
|
|
2020-09-24 22:29:13 +03:00
|
|
|
.PHONY: all
|
|
|
|
all:
|
2023-06-01 04:55:03 +02:00
|
|
|
$(MAKE) -C src/include
|
|
|
|
$(MAKE) -C src/common
|
|
|
|
$(MAKE) -C src/port
|
|
|
|
$(MAKE) -C src/interfaces/libpq all-$(LIBPQ_LIBRARY_TYPE)-lib
|
|
|
|
$(MAKE) -C src/interfaces/ecpg/include
|
|
|
|
$(MAKE) -C src/interfaces/ecpg/pgtypeslib
|
|
|
|
$(MAKE) -C src/interfaces/ecpg/ecpglib
|
|
|
|
$(MAKE) -C src/interfaces/ecpg/compatlib
|
|
|
|
ifeq ($(LIBPQ_ENABLE_TOOLS), yes)
|
|
|
|
$(MAKE) -C src/interfaces/ecpg/preproc
|
|
|
|
$(MAKE) -C src/fe_utils
|
|
|
|
$(MAKE) -C src/bin
|
|
|
|
else
|
|
|
|
$(MAKE) -C src/bin/pg_config
|
|
|
|
endif
|
2020-09-24 22:29:13 +03:00
|
|
|
|
|
|
|
.PHONY: install-stlib
|
|
|
|
install-stlib:
|
2023-06-01 04:55:03 +02:00
|
|
|
$(MAKE) -C src/common install -o all
|
2020-09-24 22:29:13 +03:00
|
|
|
rm -f '$(DESTDIR)$(libdir)/libpgcommon_shlib.a'
|
2023-06-01 04:55:03 +02:00
|
|
|
$(MAKE) -C src/port install -o all
|
2020-09-24 22:29:13 +03:00
|
|
|
rm -f '$(DESTDIR)$(libdir)/libpgport_shlib.a'
|
|
|
|
|
|
|
|
.PHONY: install
|
|
|
|
install: $(LIBPQ_INSTALL_LIBS)
|
2023-06-01 04:55:03 +02:00
|
|
|
$(MAKE) -C src/include install
|
|
|
|
$(MAKE) -C src/interfaces/libpq $(EXTRA_TARGET) install-lib-$(LIBPQ_LIBRARY_TYPE) install-lib-pc install -o all -o install-lib
|
|
|
|
$(MAKE) -C src/interfaces/ecpg/include install
|
|
|
|
$(MAKE) -C src/interfaces/ecpg/pgtypeslib install
|
|
|
|
$(MAKE) -C src/interfaces/ecpg/ecpglib install
|
|
|
|
$(MAKE) -C src/interfaces/ecpg/compatlib install
|
|
|
|
ifeq ($(LIBPQ_ENABLE_TOOLS), yes)
|
|
|
|
$(MAKE) -C src/interfaces/ecpg/preproc install
|
|
|
|
$(MAKE) -C src/bin install
|
|
|
|
else
|
|
|
|
$(MAKE) -C src/bin/pg_config install
|
|
|
|
endif
|