]> git.lyx.org Git - lyx.git/blob - src/support/Makefile.am
2e7f13293d1ab0942c4d709d02cd025fda078fff
[lyx.git] / src / support / Makefile.am
1 include $(top_srcdir)/config/common.am
2
3 CLEANFILES += $(BUILT_SOURCES)
4
5 EXTRA_DIST = pch.h \
6         os_cygwin.cpp os_unix.cpp os_win32.cpp os_win32.h
7
8 noinst_LTLIBRARIES = liblyxsupport.la
9
10 liblyxsupport_la_LIBADD = $(LIBSHLWAPI) $(QT4_CORE_LIB) $(BOOST_SIGNALS)
11 liblyxsupport_la_LDFLAGS = $(QT4_CORE_LDFLAGS)
12
13 BUILT_SOURCES = $(PCH_FILE)
14
15 #########################  Qt stuff  #############################
16 #
17
18 CLEANFILES += $(MOCEDFILES)
19 BUILT_SOURCES += $(MOCEDFILES)
20
21 MOCEDFILES = $(MOCHEADER:%.h=%_moc.cpp)
22
23 %_moc.cpp: %.h
24         $(MOC4) -o $@ $<
25
26 MOCHEADER =
27
28 liblyxsupport_la_DEPENDENCIES = $(MOCEDFILES)
29
30 #
31 ##################################################################
32
33 AM_CPPFLAGS += $(PCH_FLAGS) -I$(srcdir)/.. $(BOOST_INCLUDES)
34 AM_CPPFLAGS += $(QT4_CPPFLAGS) $(QT4_CORE_INCLUDES) -I$(srcdir)/minizip
35
36 # force the use of C++ compiler for minizip/*.c files, because
37 # gcc can not go through the included boost files.
38 liblyxsupport_la_CFLAGS = -x c++
39
40 liblyxsupport_la_SOURCES = \
41         FileMonitor.h \
42         FileMonitor.cpp \
43         RandomAccessList.h \
44         abort.cpp \
45         convert.cpp \
46         convert.h \
47         copied_ptr.h \
48         debug.cpp \
49         debug.h \
50         docstream.cpp \
51         docstream.h \
52         docstring.cpp \
53         docstring.h \
54         environment.h \
55         environment.cpp \
56         ExceptionMessage.h \
57         FileFilterList.cpp \
58         FileFilterList.h \
59         FileName.cpp \
60         FileName.h \
61         filetools.cpp \
62         filetools.h \
63         ForkedCalls.cpp \
64         ForkedCalls.h \
65         gettext.cpp \
66         gettext.h \
67         getcwd.cpp \
68         gzstream.cpp \
69         gzstream.h \
70         kill.cpp \
71         limited_stack.h \
72         lstrings.cpp \
73         lstrings.h \
74         lyxalgo.h \
75         lyxlib.h \
76         lyxtime.cpp \
77         lyxtime.h \
78         lyxsum.cpp \
79         Messages.cpp \
80         Messages.h \
81         os.cpp \
82         os.h \
83         Path.cpp \
84         Path.h \
85         Package.cpp \
86         Package.h \
87         qstring_helpers.h \
88         socktools.cpp \
89         socktools.h \
90         strfwd.h \
91         Systemcall.cpp \
92         Systemcall.h \
93         SignalSlot.cpp \
94         SignalSlot.h \
95         SignalSlotPrivate.h \
96         tempname.cpp \
97         textutils.h \
98         Translator.h \
99         Timeout.cpp \
100         Timeout.h \
101         types.h \
102         userinfo.cpp \
103         userinfo.h \
104         unicode.cpp \
105         unicode.h \
106         minizip/crypt.h \
107         minizip/ioapi.c \
108         minizip/ioapi.h \
109         minizip/iowin32.c \
110         minizip/iowin32.h \
111         minizip/unzip.c \
112         minizip/unzip.h \
113         minizip/zip.c \
114         minizip/zip.h \
115         minizip/zipunzip.cpp
116
117 ############################## Tests ##################################
118
119 EXTRA_DIST += \
120         tests/test_convert \
121         tests/test_filetools \
122         tests/test_lstrings \
123         tests/regfiles/convert \
124         tests/regfiles/filetools \
125         tests/regfiles/lstrings
126
127
128 TESTS = \
129         test_convert \
130         test_filetools \
131         test_lstrings
132
133 check_PROGRAMS = \
134         check_convert \
135         check_filetools \
136         check_lstrings
137
138 check_convert_LDADD = ../debug.o convert.o docstring.o lstrings.o unicode.o \
139         $(BOOST_LIBS) $(QT4_CORE_LIB)
140 check_convert_LDFLAGS = $(QT4_CORE_LDFLAGS)
141 check_convert_SOURCES = \
142         tests/check_convert.cpp \
143         tests/boost.cpp
144
145 check_filetools_LDADD = ../debug.o libsupport.la $(BOOST_LIBS)
146 check_filetools_SOURCES = \
147         tests/check_filetools.cpp \
148         tests/boost.cpp
149
150 check_lstrings_LDADD = ../debug.o lstrings.o convert.o docstring.o unicode.o \
151         $(QT4_CORE_LIB)
152 check_lstrings_LDFLAGS = $(QT4_CORE_LDFLAGS)
153 check_lstrings_SOURCES = \
154         tests/check_lstrings.cpp \
155         tests/boost.cpp
156
157 makeregfiles: ${check_PROGRAMS}
158         for all in ${check_PROGRAMS} ; do \
159                 ./$$all > ${srcdir}/regfiles/$$all ; \
160         done