]> git.lyx.org Git - lyx.git/blob - src/support/Makefile.am
08f1c7180d7fa3a508b1815f4d6d0f61dbf9ab50
[lyx.git] / src / support / Makefile.am
1 include $(top_srcdir)/config/common.am
2
3 EXTRA_DIST = os_cygwin.cpp os_unix.cpp os_win32.cpp os_win32.h \
4         CMakeLists.txt tests/CMakeLists.txt tests/supporttest.cmake
5
6 noinst_LIBRARIES = liblyxsupport.a
7
8
9 #########################  Qt stuff  #############################
10 #
11
12 MOCHEADER = \
13         ConsoleApplicationPrivate.h \
14         SystemcallPrivate.h
15
16 MOCEDFILES = $(MOCHEADER:%.h=moc_%.cpp)
17
18 CLEANFILES = $(MOCEDFILES)
19 BUILT_SOURCES = $(MOCEDFILES)
20
21 moc_%.cpp: %.h
22         $(QT_MOC) -o $@ $<
23
24 liblyxsupport_a_DEPENDENCIES = $(MOCEDFILES)
25
26 #
27 ##################################################################
28
29 AM_CPPFLAGS += -I$(srcdir)/.. \
30         $(BOOST_INCLUDES) $(ICONV_INCLUDES) $(ZLIB_INCLUDES) \
31         $(QT_CPPFLAGS) $(QT_INCLUDES)
32
33 liblyxsupport_a_SOURCES = \
34         FileMonitor.h \
35         FileMonitor.cpp \
36         RandomAccessList.h \
37         bind.h \
38         Changer.h \
39         ConsoleApplication.cpp \
40         ConsoleApplication.h \
41         ConsoleApplicationPrivate.h \
42         convert.cpp \
43         convert.h \
44         copied_ptr.h \
45         debug.cpp \
46         debug.h \
47         docstream.cpp \
48         docstream.h \
49         docstring.cpp \
50         docstring.h \
51         docstring_list.h \
52         environment.h \
53         environment.cpp \
54         ExceptionMessage.h \
55         FileName.cpp \
56         FileName.h \
57         FileNameList.h \
58         filetools.cpp \
59         filetools.h \
60         ForkedCalls.cpp \
61         ForkedCalls.h \
62         functional.h \
63         gettext.cpp \
64         gettext.h \
65         gzstream.cpp \
66         gzstream.h \
67         kill.cpp \
68         lassert.h \
69         lassert.cpp \
70         limited_stack.h \
71         lstrings.cpp \
72         lstrings.h \
73         lyxalgo.h \
74         lyxlib.h \
75         lyxtime.cpp \
76         lyxtime.h \
77         mutex.h \
78         mutex.cpp \
79         Messages.cpp \
80         Messages.h \
81         numpunct_lyx_char_type.h \
82         os.cpp \
83         os.h \
84         PathChanger.cpp \
85         PathChanger.h \
86         Package.cpp \
87         Package.h \
88         ProgressInterface.h \
89         pmprof.h \
90         qstring_helpers.cpp \
91         qstring_helpers.h \
92         regex.h \
93         RefChanger.h \
94         socktools.cpp \
95         socktools.h \
96         strfwd.h \
97         Systemcall.cpp \
98         Systemcall.h \
99         SystemcallPrivate.h \
100         TempFile.cpp \
101         TempFile.h \
102         textutils.h \
103         Translator.h \
104         Timeout.cpp \
105         Timeout.h \
106         trivstring.cpp \
107         trivstring.h \
108         types.h \
109         unique_ptr.h \
110         userinfo.cpp \
111         userinfo.h \
112         unicode.cpp \
113         unicode.h \
114         weighted_btree.h
115 if USE_INCLUDED_MYTHES
116 liblyxsupport_a_SOURCES += \
117         mythes/mythes.cxx \
118         mythes/mythes.hxx \
119         mythes/license.readme
120 endif
121
122 #if INSTALL_MACOSX
123 #liblyxsupport_a_SOURCES += \
124 #       AppleSpellChecker.h \
125 #       AppleSpellChecker.mm
126 #endif
127
128 if INSTALL_MACOSX
129 liblyxsupport_a_SOURCES += \
130         AppleSpeller.h \
131         AppleSpeller.m \
132         AppleScript.h \
133         AppleScript.m \
134         AppleScriptProxy.cpp \
135         linkback/LinkBack.h \
136         linkback/LinkBack.m \
137         linkback/LinkBackProxy.h \
138         linkback/LinkBackProxy.m \
139         linkback/LinkBackServer.h \
140         linkback/LinkBackServer.m
141 endif
142
143 ############################## Tests ##################################
144
145 EXTRA_DIST += \
146         tests/test_convert \
147         tests/test_filetools \
148         tests/test_lstrings \
149         tests/test_trivstring \
150         tests/regfiles/convert \
151         tests/regfiles/filetools \
152         tests/regfiles/lstrings \
153         tests/regfiles/trivstring
154
155
156 TESTS = \
157         tests/test_convert \
158         tests/test_filetools \
159         tests/test_lstrings \
160         tests/test_trivstring
161
162 check_PROGRAMS = \
163         check_convert \
164         check_filetools \
165         check_lstrings \
166         check_trivstring
167
168 if INSTALL_MACOSX
169 ADD_FRAMEWORKS = -framework QtCore -framework AppKit -framework ApplicationServices
170 endif
171
172 check_convert_LDADD = liblyxsupport.a $(LIBICONV) $(BOOST_LIBS) $(QT_CORE_LIBS) $(LIBSHLWAPI) @LIBS@
173 check_convert_LDFLAGS = $(QT_CORE_LDFLAGS) $(ADD_FRAMEWORKS)
174 check_convert_SOURCES = \
175         tests/check_convert.cpp \
176         tests/dummy_functions.cpp \
177         tests/boost.cpp
178
179 check_filetools_LDADD = liblyxsupport.a $(LIBICONV) $(BOOST_LIBS) $(QT_CORE_LIBS) $(LIBSHLWAPI) @LIBS@
180 check_filetools_LDFLAGS = $(QT_CORE_LDFLAGS) $(ADD_FRAMEWORKS)
181 check_filetools_SOURCES = \
182         tests/check_filetools.cpp \
183         tests/dummy_functions.cpp \
184         tests/boost.cpp
185
186 check_lstrings_LDADD = liblyxsupport.a $(LIBICONV) $(BOOST_LIBS) $(QT_CORE_LIBS) $(LIBSHLWAPI) @LIBS@
187 check_lstrings_LDFLAGS = $(QT_CORE_LDFLAGS) $(ADD_FRAMEWORKS)
188 check_lstrings_SOURCES = \
189         tests/check_lstrings.cpp \
190         tests/dummy_functions.cpp \
191         tests/boost.cpp
192
193 check_trivstring_LDADD = liblyxsupport.a $(LIBICONV) $(BOOST_LIBS) $(QT_CORE_LIBS) $(LIBSHLWAPI) @LIBS@
194 check_trivstring_LDFLAGS = $(QT_CORE_LDFLAGS) $(ADD_FRAMEWORKS)
195 check_trivstring_SOURCES = \
196         tests/check_trivstring.cpp \
197         tests/dummy_functions.cpp \
198         tests/boost.cpp
199
200 makeregfiles: ${check_PROGRAMS}
201         for all in ${check_PROGRAMS} ; do \
202                 ./$$all > ${srcdir}/tests/regfiles/$$all ; \
203         done