X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Fsupport%2FMakefile.am;h=ab353b497beffabf3ce0a64275f6f1880f1cdc85;hb=3f59d7e2cc6a3f9a09631c804b49b6d28e05d857;hp=986bf0a43d64ca5b035dfd13a4f9edf33734ee2d;hpb=1fc0c01877f19d8194b6b22e61aa3db5fa2b1671;p=lyx.git diff --git a/src/support/Makefile.am b/src/support/Makefile.am index 986bf0a43d..ab353b497b 100644 --- a/src/support/Makefile.am +++ b/src/support/Makefile.am @@ -1,99 +1,182 @@ include $(top_srcdir)/config/common.am -SUBDIRS = . tests - CLEANFILES += $(BUILT_SOURCES) -EXTRA_DIST = package.C.in pch.h \ - os_cygwin.C os_unix.C os_win32.C os_win32.h +EXTRA_DIST = pch.h \ + os_cygwin.cpp os_unix.cpp os_win32.cpp os_win32.h + +noinst_LIBRARIES = liblyxsupport.a + +BUILT_SOURCES = $(PCH_FILE) + +######################### Qt stuff ############################# +# + +MOCHEADER = SystemcallPrivate.h -noinst_LTLIBRARIES = libsupport.la +MOCEDFILES = $(MOCHEADER:%.h=moc_%.cpp) -libsupport_la_LIBADD = $(LIBSHLWAPI) +CLEANFILES += $(MOCEDFILES) +BUILT_SOURCES += $(MOCEDFILES) -BUILT_SOURCES = $(PCH_FILE) package.C +moc_%.cpp: %.h + $(MOC4) -o $@ $< + +liblyxsupport_a_DEPENDENCIES = $(MOCEDFILES) + +# +################################################################## AM_CPPFLAGS += $(PCH_FLAGS) -I$(srcdir)/.. $(BOOST_INCLUDES) +AM_CPPFLAGS += $(QT4_CPPFLAGS) $(QT4_INCLUDES) -libsupport_la_SOURCES = \ +liblyxsupport_a_SOURCES = \ FileMonitor.h \ - FileMonitor.C \ + FileMonitor.cpp \ RandomAccessList.h \ - abort.C \ - chdir.C \ - convert.C \ + bind.h \ + convert.cpp \ convert.h \ - copy.C \ copied_ptr.h \ - cow_ptr.h \ - debugstream.h \ - docstring.C \ + debug.cpp \ + debug.h \ + docstream.cpp \ + docstream.h \ + docstring.cpp \ docstring.h \ + docstring_list.h \ environment.h \ - environment.C \ - filefilterlist.C \ - filefilterlist.h \ - filename.C \ - filename.h \ - filetools.C \ + environment.cpp \ + ExceptionMessage.h \ + FileName.cpp \ + FileName.h \ + FileNameList.h \ + filetools.cpp \ filetools.h \ - forkedcall.C \ - forkedcall.h \ - forkedcallqueue.C \ - forkedcallqueue.h \ - forkedcontr.C \ - forkedcontr.h \ - fs_extras.C \ - fs_extras.h \ - getcwd.C \ - kill.C \ + foreach.h \ + ForkedCalls.cpp \ + ForkedCalls.h \ + functional.h \ + gettext.cpp \ + gettext.h \ + gzstream.cpp \ + gzstream.h \ + kill.cpp \ + lassert.h \ + lassert.cpp \ limited_stack.h \ - lstrings.C \ + lstrings.cpp \ lstrings.h \ lyxalgo.h \ lyxlib.h \ - lyxmanip.h \ - lyxtime.C \ + lyxtime.cpp \ lyxtime.h \ - lyxsum.C \ - mkdir.C \ - os.C \ + mutex.h \ + mutex.cpp \ + Messages.cpp \ + Messages.h \ + numpunct_lyx_char_type.h \ + os.cpp \ os.h \ - path.C \ - path.h \ - package.C \ - package.h \ - rename.C \ - socktools.C \ + PathChanger.cpp \ + PathChanger.h \ + Package.cpp \ + Package.h \ + ProgressInterface.h \ + pmprof.h \ + qstring_helpers.cpp \ + qstring_helpers.h \ + regex.h \ + socktools.cpp \ socktools.h \ - std_istream.h \ - std_ostream.h \ - systemcall.C \ - systemcall.h \ - tempname.C \ + strfwd.h \ + Systemcall.cpp \ + Systemcall.h \ + SystemcallPrivate.h \ + shared_ptr.h \ + TempFile.cpp \ + TempFile.h \ textutils.h \ - translator.h \ + Translator.h \ + Timeout.cpp \ + Timeout.h \ types.h \ - userinfo.C \ + userinfo.cpp \ userinfo.h \ - unicode.C \ + unicode.cpp \ unicode.h \ - unlink.C - - -package.C: build_package - -# Solaris sed does not like spaces bewteen the ;-delimited commands -build_package: package.C.in - @rm -f tmp_package ;\ - sed "s,%LYX_DIR%,$(LYX_ABS_INSTALLED_DATADIR),;\ -s,%LOCALEDIR%,$(LYX_ABS_INSTALLED_LOCALEDIR),;\ -s,%TOP_SRCDIR%,$(LYX_ABS_TOP_SRCDIR),;\ -s,%PROGRAM_SUFFIX%,$(program_suffix)," \ - $(srcdir)/package.C.in > tmp_package ;\ - if cmp -s tmp_package package.C ; then \ - rm -f tmp_package ;\ - else \ - rm -f package.C ;\ - mv tmp_package package.C ;\ - fi + weighted_btree.h +if USE_INCLUDED_MYTHES +liblyxsupport_a_SOURCES += \ + mythes/mythes.cxx \ + mythes/mythes.hxx \ + mythes/license.readme +endif + +#if INSTALL_MACOSX +#liblyxsupport_a_SOURCES += \ +# AppleSpellChecker.h \ +# AppleSpellChecker.mm +#endif + +if INSTALL_MACOSX +liblyxsupport_a_SOURCES += \ + AppleSpeller.h \ + AppleSpeller.m \ + AppleScript.h \ + AppleScript.m \ + AppleScriptProxy.cpp \ + linkback/LinkBack.h \ + linkback/LinkBack.m \ + linkback/LinkBackProxy.h \ + linkback/LinkBackProxy.m \ + linkback/LinkBackServer.h \ + linkback/LinkBackServer.m +endif + +############################## Tests ################################## + +EXTRA_DIST += \ + tests/test_convert \ + tests/test_filetools \ + tests/test_lstrings \ + tests/regfiles/convert \ + tests/regfiles/filetools \ + tests/regfiles/lstrings + + +TESTS = \ + tests/test_convert \ + tests/test_filetools \ + tests/test_lstrings + +check_PROGRAMS = \ + check_convert \ + check_filetools \ + check_lstrings + +check_convert_LDADD = liblyxsupport.a $(LIBICONV) $(BOOST_LIBS) $(QT4_CORE_LIBS) $(LIBSHLWAPI) +check_convert_LDFLAGS = $(QT4_LDFLAGS) +check_convert_SOURCES = \ + tests/check_convert.cpp \ + tests/dummy_functions.cpp \ + tests/boost.cpp + +check_filetools_LDADD = liblyxsupport.a $(LIBICONV) $(BOOST_LIBS) $(QT4_CORE_LIBS) $(LIBSHLWAPI) +check_filetools_LDFLAGS = $(QT4_CORE_LDFLAGS) +check_filetools_SOURCES = \ + tests/check_filetools.cpp \ + tests/dummy_functions.cpp \ + tests/boost.cpp + +check_lstrings_LDADD = liblyxsupport.a $(LIBICONV) $(BOOST_LIBS) $(QT4_CORE_LIBS) $(LIBSHLWAPI) +check_lstrings_LDFLAGS = $(QT4_CORE_LDFLAGS) +check_lstrings_SOURCES = \ + tests/check_lstrings.cpp \ + tests/dummy_functions.cpp \ + tests/boost.cpp + +makeregfiles: ${check_PROGRAMS} + for all in ${check_PROGRAMS} ; do \ + ./$$all > ${srcdir}/tests/regfiles/$$all ; \ + done