bda39c7e17ff5d2d8a27b8333375792f1e2a72bb
[pspp-builds.git] / src / Makefile.am
1 ## Process this file with automake to produce Makefile.in  -*- makefile -*-
2
3 # PSPP
4
5 # If you change this, you must also change the corresponding line in 
6 # config/Makefile.am
7 pkgsysconfdir = $(sysconfdir)/@PACKAGE@
8
9 bin_PROGRAMS = pspp
10
11
12
13 AM_CPPFLAGS = -I$(top_srcdir) -I$(top_srcdir)/src -I$(top_srcdir)/lib   \
14 -I$(top_srcdir)/intl 
15
16 AM_CFLAGS=
17
18 if cc_is_gcc
19 AM_CFLAGS+=-Wall -W -Wwrite-strings -Wstrict-prototypes \
20 -Wpointer-arith -Wno-sign-compare -Wmissing-prototypes \
21 -ansi 
22 endif
23
24 if unix
25 AM_CFLAGS+=-Dunix
26 endif
27
28 if msdos
29 AM_CFLAGS+=-D__MSDOS__
30 endif
31
32
33
34 CLEANFILES =  $(q_sources_c) version.c
35 DISTCLEANFILES = foo 
36 MAINTAINERCLEANFILES = Makefile.in
37 EXTRA_DIST = $(q_sources_q) q2c.c
38 ETAGS_ARGS = -l c $(q_sources_c)
39 SUFFIXES = .q
40
41 $(q_sources_c): q2c$(EXEEXT)
42 .q.c:
43         ./q2c $< $@
44
45 q_sources_c = correlations.c crosstabs.c examine.c file-handle.c        \
46 frequencies.c list.c means.c oneway.c set.c  t-test.c 
47
48 q_sources_q = correlations.q crosstabs.q examine.q file-handle.q        \
49 frequencies.q list.q means.q oneway.q set.q  t-test.q
50
51 if WITHCHARTS
52 chart_sources = barchart.c \
53         box-whisker.c \
54         cartesian.c \
55         plot-chart.c \
56         plot-hist.c \
57         piechart.c 
58 else
59 chart_sources = dummy-chart.c
60 endif
61
62 pspp_SOURCES = $(q_sources_c) $(chart_sources) \
63 aggregate.c algorithm.c algorithm.h     \
64 alloc.c alloc.h apply-dict.c ascii.c autorecode.c bitvector.h           \
65 case.c case.h casefile.c casefile.h chart.c  chart.h  \
66 cmdline.c cmdline.h command.c command.def               \
67 command.h compute.c copyleft.c copyleft.h count.c data-in.c data-in.h   \
68 data-list.c data-list.h data-out.c date.c debug-print.h descript.c      \
69 devind.c devind.h dfm-read.c dfm-read.h dfm-write.c dfm-write.h \
70 dictionary.c dictionary.h do-if.c do-ifP.h error.c \
71 error.h expr-evl.c expr-opt.c expr-prs.c expr.h exprP.h expr.def        \
72 factor_stats.c factor_stats.h file-handle.h     \
73 file-type.c filename.c filename.h flip.c font.h format.c format.def     \
74 format.h formats.c get.c getline.c getline.h glob.c glob.h              \
75 groff-font.c group.c group.h group_proc.h \
76 hash.c hash.h histogram.c histogram.h \
77 html.c htmlP.h include.c inpt-pgm.c lexer.c lexer.h levene.c levene.h \
78 linked-list.c linked-list.h log.h loop.c magic.c magic.h main.c main.h  \
79 matrix-data.c mis-val.c misc.c misc.h modify-vars.c                     \
80 moments.c moments.h numeric.c output.c output.h \
81 percentiles.c percentiles.h permissions.c \
82 pfm-read.c pfm-read.h   \
83 pfm-write.c pfm-write.h \
84 pool.c pool.h postscript.c print.c recode.c     \
85 rename-vars.c repeat.c repeat.h sample.c sel-if.c settings.h            \
86 sfm-read.c sfm-read.h sfm-write.c sfm-write.h sfmP.h som.c som.h        \
87 sort.c sort.h split-file.c str.c str.h subclist.c subclist.h \
88 sysfile-info.c tab.c tab.h temporary.c stat.h mkfile.c mkfile.h \
89 title.c  val.h val-labs.c value-labels.c value-labels.h         \
90 var-labs.c var.h vars-atr.c vars-prs.c vector.c version.h       \
91 vfm.c vfm.h vfmP.h weight.c 
92
93
94 pspp_LDADD = ../lib/julcal/libjulcal.a          \
95         ../lib/misc/libmisc.a                   \
96         @LIBINTL@
97
98 nodist_pspp_SOURCES = version.c
99
100 version.c:
101         echo "#include <config.h>" > version.c
102         echo "#include \"version.h\"" > version.c
103         echo "const char bare_version[] = \"@VERSION@\";" >> version.c
104         echo "const char version[] = \"GNU @PACKAGE@ @VERSION@\";" >> version.c
105         echo "const char stat_version[] = \"GNU @PACKAGE@ @VERSION@ \
106 (`date`).\";" >> version.c
107         echo "const char host_system[] = \"$(host_triplet)\";" >> version.c
108         echo "const char build_system[] = \"$(build_triplet)\";" >> version.c
109         echo "const char default_config_path[] =\
110 \"~/.pspp:$(pkgsysconfdir)\";" >> version.c
111         echo "const char include_path[] =\
112 \"./:~/.pspp/include:$(pkgdatadir)\";" >> version.c
113         echo "const char groff_font_path[] = \"~/.pspp/font:\" \\" >> version.c
114         echo "  \"$(pkgdatadir)/font:\" \\" >> version.c
115         echo "  \"/usr/local/lib/groff/font:\" \\" >> version.c
116         echo "  \"/usr/lib/groff/font:\" \\" >> version.c
117         echo "  \"/usr/local/share/groff/font:\" \\" >> version.c
118         echo "  \"/usr/share/groff/font\";" >> version.c
119         echo "const char locale_dir[] = \"$(datadir)/locale\";" >> version.c
120 \f
121
122 noinst_PROGRAMS = q2c
123 q2c_SOURCES = q2c.c