~ubuntu-branches/debian/sid/postgresql-9.3/sid

« back to all changes in this revision

Viewing changes to src/makefiles/Makefile.aix

  • Committer: Package Import Robot
  • Author(s): Martin Pitt
  • Date: 2013-05-08 05:39:52 UTC
  • Revision ID: package-import@ubuntu.com-20130508053952-1j7uilp7mjtrvq8q
Tags: upstream-9.3~beta1
ImportĀ upstreamĀ versionĀ 9.3~beta1

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# MAKE_EXPORTS is required for svr4 loaders that want a file of
 
2
# symbol names to tell them what to export/import.
 
3
MAKE_EXPORTS= true
 
4
 
 
5
RANLIB= touch
 
6
AROPT = crs
 
7
 
 
8
# -blibpath must contain ALL directories where we should look for libraries
 
9
libpath := $(shell echo $(subst -L,:,$(filter -L/%,$(LDFLAGS))) | sed -e's/ //g'):/usr/lib:/lib
 
10
 
 
11
ifeq ($(host_os), aix3.2.5)
 
12
        rpath = -L'$(rpathdir)'
 
13
else
 
14
        rpath = -Wl,-blibpath:'$(rpathdir)$(libpath)'
 
15
endif
 
16
 
 
17
DLSUFFIX = .so
 
18
ifeq ($(host_os), aix3.2.5)
 
19
ifneq ($(GCC), yes)
 
20
        LDFLAGS_SL += -e _nostart -H512 -bM:SRE
 
21
endif
 
22
else
 
23
        LDFLAGS_SL += -Wl,-bnoentry -Wl,-H512 -Wl,-bM:SRE
 
24
endif
 
25
 
 
26
 
 
27
POSTGRES_IMP= postgres.imp
 
28
 
 
29
ifdef PGXS
 
30
BE_DLLLIBS= -Wl,-bI:$(pkglibdir)/$(POSTGRES_IMP)
 
31
else
 
32
BE_DLLLIBS= -Wl,-bI:$(top_builddir)/src/backend/$(POSTGRES_IMP)
 
33
endif
 
34
 
 
35
MKLDEXPORT_DIR=src/backend/port/aix
 
36
MKLDEXPORT=$(top_srcdir)/$(MKLDEXPORT_DIR)/mkldexport.sh
 
37
 
 
38
%.exp: %.o
 
39
        $(MKLDEXPORT) $^ >$@
 
40
 
 
41
# Rule for building a shared library from a single .o file
 
42
%$(DLSUFFIX): %.o %.exp
 
43
        $(CC) $(CFLAGS) $(LDFLAGS) $(LDFLAGS_SL) -o $@ $*.o -Wl,-bE:$*.exp $(BE_DLLLIBS)