1 # Your C compilier and flags
5 top_srcdir = @top_srcdir@
8 exec_prefix = @exec_prefix@
9 installroot = @installroot@
13 confdir = @sysconfdir@
15 datarootdir = @datarootdir@
21 build_targets = @buildtargets@
22 install_targets = @installtargets@
23 CHARSETPATH=${datadir}/catdoc
24 # Flags to pass to your C compilier
25 # remove -O2 on HP/UX 9. It is known to cause problems
26 FLAGS=-I. @CFLAGS@ @DEFS@ -DCATDOC_VERSION=\"@PACKAGE_VERSION@\" -DCHARSETPATH=\"${CHARSETPATH}\"
28 #Compile-time configuration of catdoc itself. Edit according to taste
30 #Directory, where all system-wide stuff resides
31 DATA_DIR=$(datadir)/catdoc
32 #directory, where catdoc binary would be placed
33 #directory where to put man page
35 #System-wide configuration file
36 SYSTEMRC=$(confdir)/catdocrc
38 #Per-user configration file (in user's home directory
41 # path where to search for charsets. may be colon-separated list of dirs
43 # Extension for map of special character
46 # Extension for map of substitutes (chars which are missing from target
50 # Target charset - one used on your system console or xterm
51 TARGET_CHARSET=@targetcharset@
53 # Source charset - one which your Word files are usially in unless they
55 SOURCE_CHARSET=@sourcecharset@
57 # Character which would be printed instead of ones, not found in charset
61 # END OF COMPILE-TIME CONFIGURATION
63 DEFINES=-DSYSTEMRC=\"$(SYSTEMRC)\" -DUSERRC=\"$(USERRC)\"
65 CFLAGS=$(FLAGS) $(DEFINES) @DEFS@
67 COMMONOBJ=charsets.o substmap.o fileutil.o confutil.o numutils.o ole.o
69 OBJ=catdoc.o reader.o writer.o analyze.o rtfread.o $(COMMONOBJ)
71 OBJXLS=xls2csv.o sheet.o xlsparse.o $(COMMONOBJ)
73 OBJPPT=catppt.o pptparse.o $(COMMONOBJ)
75 # $(CC) -c $(CFLAGS) $*
78 $(CC) -o catdoc $(OBJ) $(LDFLAGS)
80 $(CC) -o xls2csv $(OBJXLS) -lm $(LDFLAGS)
83 $(CC) -o catppt $(OBJPPT) -lm $(LDFLAGS)
85 install: @installtargets@
86 install-catdoc:catdoc xls2csv catppt
87 ../mkinstalldirs $(installroot)$(bindir)
88 $(INSTALL) -m 755 catdoc $(installroot)$(bindir)/catdoc
89 $(INSTALL) -m 755 xls2csv $(installroot)$(bindir)/xls2csv
90 $(INSTALL) -m 755 catppt $(installroot)$(bindir)/catppt
91 install-wordview: wordview
92 ../mkinstalldirs $(installroot)$(bindir)
93 $(INSTALL) -m 755 wordview $(installroot)$(bindir)/wordview
94 wordview: wordview.tcl
95 echo "#! $(WISH)" >wordview
96 echo set charset_lib "\"$(CHARSETPATH)\"">>wordview
97 cat wordview.tcl >>wordview
99 strftime.o: ../compat/strftime.c
100 $(CC) -c $(FLAGS) -o $@ $*
102 rm -f *.o catdoc wordview xls2csv catppt