-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile.andre_mikulec
68 lines (51 loc) · 1.52 KB
/
Makefile.andre_mikulec
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
# contrib/plr/Makefile
# pl/r
$(info )
$(info Your R_HOME environment variable should be set. It is R_HOME="$(R_HOME)")
$(info Your R_ARCH environment variable may be set. It is R_ARCH="$(R_ARCH)")
$(info )
r_libdir1x = ${R_HOME}/bin${R_ARCH}
r_libdir2x = ${R_HOME}/bin${R_ARCH}
r_includespec = -I${R_HOME}/include
MODULE_big = plr
SRCS += plr.c pg_conversion.c pg_backend_support.c pg_userfuncs.c pg_rsupport.c
OBJS := $(SRCS:.c=.o) $(WIN32RES)
EXTENSION = plr
DATA = plr--8.4.1.sql plr--8.4--8.4.1.sql plr--unpackaged--8.4.1.sql
### DATA_built = plr.sql
PGFILEDESC = "PL/R - R Procedural Language for PostgreSQL"
REGRESS = plr
EXTRA_CLEAN = doc/html/* doc/plr-US.aux doc/plr-*.log doc/plr-*.out doc/plr-*.pdf doc/plr-*.tex-pdf
SHLIB_LINK += -L$(r_libdir1x) -L$(r_libdir2x) -lR
# pl/r
PG_CPPFLAGS += $(r_includespec)
DOCS = README.md
ifdef USE_PGXS
ifndef PG_CONFIG
PG_CONFIG := pg_config
endif
PGXS := $(shell $(PG_CONFIG) --pgxs)
include $(PGXS)
else
subdir = contrib/plr
top_builddir = ../..
include $(top_builddir)/src/Makefile.global
include $(top_srcdir)/contrib/contrib-global.mk
endif
# ifeq ($(PORTNAME), darwin)
# DYSUFFIX = dylib
# DLPREFIX = libR
# else
# ifeq ($(PORTNAME), win32)
# DLPREFIX = R
# else
# DLPREFIX = libR
# endif
# endif
DLSUFFIX = .dll
# pl/r
# gcc 6.2 DEEP DEBUGGING
override CFLAGS += -O
override CPPFLAGS := -I"$(srcdir)" -I"$(r_includespec)" $(CPPFLAGS)
override CPPFLAGS += -DDLSUFFIX=\"$(DLSUFFIX)\"
# -Xlinker --verbose -Q