forked from orafce/orafce
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
69 lines (52 loc) · 2.04 KB
/
Makefile
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
69
MODULE_big = orafce
OBJS= parse_keyword.o convert.o file.o datefce.o magic.o others.o plvstr.o plvdate.o shmmc.o plvsubst.o utility.o plvlex.o alert.o pipe.o sqlparse.o putline.o assert.o plunit.o random.o aggregate.o orafce.o varchar2.o nvarchar2.o charpad.o charlen.o replace_empty_string.o
EXTENSION = orafce
DATA = orafce--3.14.sql orafce--3.2--3.3.sql orafce--3.3--3.4.sql orafce--3.4--3.5.sql orafce--3.5--3.6.sql orafce--3.6--3.7.sql orafce--3.7--3.8.sql orafce--3.8--3.9.sql orafce--3.9--3.10.sql orafce--3.10--3.11.sql orafce--3.11--3.12.sql orafce--3.12--3.13.sql orafce--3.13--3.14.sql
DOCS = README.asciidoc COPYRIGHT.orafce INSTALL.orafce
PG_CONFIG ?= pg_config
# make "all" the default target
all:
REGRESS = orafce orafce2 dbms_output dbms_utility files varchar2 nvarchar2 aggregates nlssort dbms_random
#REGRESS_OPTS = --load-language=plpgsql --schedule=parallel_schedule --encoding=utf8
REGRESS_OPTS = --schedule=parallel_schedule --encoding=utf8
#override CFLAGS += -Wextra -Wimplicit-fallthrough=0
ifdef NO_PGXS
subdir = contrib/$(MODULE_big)
top_builddir = ../..
include $(top_builddir)/src/Makefile.global
include $(top_srcdir)/contrib/contrib-global.mk
else
PG_CONFIG = pg_config
PGXS := $(shell $(PG_CONFIG) --pgxs)
include $(PGXS)
endif
ifeq ($(enable_nls), yes)
SHLIB_LINK += $(filter -lintl,$(LIBS))
endif
# remove dependency to libxml2 and libxslt
LIBS := $(filter-out -lxml2, $(LIBS))
LIBS := $(filter-out -lxslt, $(LIBS))
plvlex.o: sqlparse.o
sqlparse.o: $(srcdir)/sqlscan.c
$(srcdir)/sqlparse.h: $(srcdir)/sqlparse.c ;
$(srcdir)/sqlparse.c: sqlparse.y
ifdef BISON
$(BISON) -d $(BISONFLAGS) -o $@ $<
else
ifdef YACC
$(YACC) -d $(YFLAGS) -p cube_yy $<
mv -f y.tab.c sqlparse.c
mv -f y.tab.h sqlparse.h
else
bison -d $(BISONFLAGS) -o $@ $<
endif
endif
$(srcdir)/sqlscan.c: sqlscan.l
ifdef FLEX
$(FLEX) $(FLEXFLAGS) -o'$@' $<
else
flex $(FLEXFLAGS) -o'$@' $<
endif
distprep: $(srcdir)/sqlparse.c $(srcdir)/sqlscan.c
maintainer-clean:
rm -f $(srcdir)/sqlparse.c $(srcdir)/sqlscan.c $(srcdir)/sqlparse.h $(srcdir)/y.tab.c $(srcdir)/y.tab.h