]> git.lyx.org Git - lyx.git/blob - src/support/Makefile.am
934d10051d20b0242d026b4a38c5322671ff0230
[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         mkdir.cpp \
82         os.cpp \
83         os.h \
84         Path.cpp \
85         Path.h \
86         Package.cpp \
87         Package.h \
88         qstring_helpers.h \
89         socktools.cpp \
90         socktools.h \
91         strfwd.h \
92         Systemcall.cpp \
93         Systemcall.h \
94         SignalSlot.cpp \
95         SignalSlot.h \
96         SignalSlotPrivate.h \
97         tempname.cpp \
98         textutils.h \
99         Translator.h \
100         Timeout.cpp \
101         Timeout.h \
102         types.h \
103         userinfo.cpp \
104         userinfo.h \
105         unicode.cpp \
106         unicode.h \
107         minizip/crypt.h \
108         minizip/ioapi.c \
109         minizip/ioapi.h \
110         minizip/iowin32.c \
111         minizip/iowin32.h \
112         minizip/unzip.c \
113         minizip/unzip.h \
114         minizip/zip.c \
115         minizip/zip.h \
116         minizip/zipunzip.cpp
117
118 ############################## Tests ##################################
119
120 EXTRA_DIST += \
121         tests/test_convert \
122         tests/test_filetools \
123         tests/test_lstrings \
124         tests/regfiles/convert \
125         tests/regfiles/filetools \
126         tests/regfiles/lstrings
127
128
129 TESTS = \
130         test_convert \
131         test_filetools \
132         test_lstrings
133
134 check_PROGRAMS = \
135         check_convert \
136         check_filetools \
137         check_lstrings
138
139 check_convert_LDADD = ../debug.o convert.o docstring.o lstrings.o unicode.o \
140         $(BOOST_LIBS) $(QT4_CORE_LIB)
141 check_convert_LDFLAGS = $(QT4_CORE_LDFLAGS)
142 check_convert_SOURCES = \
143         tests/check_convert.cpp \
144         tests/boost.cpp
145
146 check_filetools_LDADD = ../debug.o libsupport.la $(BOOST_LIBS)
147 check_filetools_SOURCES = \
148         tests/check_filetools.cpp \
149         tests/boost.cpp
150
151 check_lstrings_LDADD = ../debug.o lstrings.o convert.o docstring.o unicode.o \
152         $(QT4_CORE_LIB)
153 check_lstrings_LDFLAGS = $(QT4_CORE_LDFLAGS)
154 check_lstrings_SOURCES = \
155         tests/check_lstrings.cpp \
156         tests/boost.cpp
157
158 makeregfiles: ${check_PROGRAMS}
159         for all in ${check_PROGRAMS} ; do \
160                 ./$$all > ${srcdir}/regfiles/$$all ; \
161         done