]> git.lyx.org Git - lyx.git/blob - src/support/Makefile.am
a21958e61afa810385f271d1305b88992fd99df6
[lyx.git] / src / support / Makefile.am
1 include $(top_srcdir)/config/common.am
2
3 noinst_LTLIBRARIES = libsupport.la
4
5 CLEANFILES += path_defines.C
6
7 INCLUDES = -I$(srcdir)/../ $(BOOST_INCLUDES)
8
9 EXTRA_DIST = path_defines.C.in os_unix.C os_win32.C os_os2.C
10
11 if USE_COMPRESSION
12 COMPRESSION = gzstream.C gzstream.h
13 endif
14
15 BUILT_SOURCES = path_defines.C
16
17 AM_CXXFLAGS = $(PCH_FLAGS)
18
19 libsupport_la_SOURCES = \
20         FileInfo.C \
21         FileInfo.h \
22         FileMonitor.h \
23         FileMonitor.C \
24         abort.C \
25         atoi.C \
26         chdir.C \
27         copy.C \
28         copied_ptr.h \
29         cow_ptr.h \
30         debugstream.h \
31         filename.C \
32         filename.h \
33         filetools.C \
34         filetools.h \
35         forkedcall.C \
36         forkedcall.h \
37         forkedcallqueue.C \
38         forkedcallqueue.h \
39         forkedcontr.C \
40         forkedcontr.h \
41         getcwd.C \
42         globbing.C \
43         globbing.h \
44         $(COMPRESSION) kill.C \
45         limited_stack.h \
46         lstrings.C \
47         lstrings.h \
48         lyxalgo.h \
49         lyxfunctional.h \
50         lyxlib.h \
51         lyxmanip.h \
52         lyxtime.C \
53         lyxtime.h \
54         lyxsum.C \
55         mkdir.C \
56         os.C \
57         os.h \
58         os2_defines.h \
59         os2_errortable.h \
60         path.C \
61         path.h \
62         path_defines.C \
63         path_defines.h \
64         putenv.C \
65         rename.C \
66         rmdir.C \
67         socktools.C \
68         socktools.h \
69         std_istream.h \
70         std_ostream.h \
71         systemcall.C \
72         systemcall.h \
73         tempname.C \
74         textutils.h \
75         tostr.h \
76         tostr.C \
77         translator.h \
78         types.h \
79         userinfo.C \
80         userinfo.h \
81         unlink.C
82
83
84 path_defines.C: build_path_defines
85
86 build_path_defines: path_defines.C.in
87         @rm -f tmp_path_defines ;\
88         ABS_SRCDIR=`cd $(top_srcdir) && pwd` ;\
89         ABS_BUILDDIR=`cd ../.. && pwd` ;\
90         sed "s,%LYX_DIR%,$(pkgdatadir), ;\
91                 s,%LOCALEDIR%,$(datadir)/locale, ;\
92                 s,%BUILDDIR%,$${ABS_BUILDDIR}, ;\
93                 s,%TOP_SRCDIR%,$${ABS_SRCDIR}," \
94                 $(srcdir)/path_defines.C.in > tmp_path_defines ;\
95         if cmp -s tmp_path_defines path_defines.C ; then \
96                 rm -f tmp_path_defines ;\
97         else \
98                 rm -f path_defines.C ;\
99                 mv tmp_path_defines path_defines.C ;\
100         fi