File: CMakeLists.txt

package info (click to toggle)
dictconv 0.2-7
  • links: PTS
  • area: main
  • in suites: bullseye, buster, jessie, jessie-kfreebsd, lenny, sid, squeeze, stretch, wheezy
  • size: 1,536 kB
  • ctags: 434
  • sloc: sh: 8,876; cpp: 1,979; makefile: 10
file content (28 lines) | stat: -rw-r--r-- 858 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
FIND_PACKAGE(ZLIB)

FIND_PATH(XML2_INCLUDE_DIR libxml/xmlreader.h
  /usr/local/include/libxml2
  /usr/include/libxml2
)

SET(XML2_NAMES xml2)
FIND_LIBRARY(XML2_LIBRARY
  NAMES ${XML2_NAMES}
  PATHS /usr/lib /usr/local/lib
)

IF (XML2_INCLUDE_DIR AND XML2_LIBRARY)
   SET(XML2_FOUND TRUE)
    SET( XML2_LIBRARIES ${XML2_LIBRARY} )
ELSE (XML2_INCLUDE_DIR AND XML2_LIBRARY)
   SET(XML2_FOUND FALSE)
   SET( XML2_LIBRARIES )
ENDIF (XML2_INCLUDE_DIR AND XML2_LIBRARY)

INCLUDE_DIRECTORIES(${ZLIB_INCLUDE_DIR} ${XML2_INCLUDE_DIR})

add_executable(dictconv dictconv.cpp babylon.cpp babylonreader.cpp dictdbuilder.cpp freedictreader.cpp plaintextdictbuilder.cpp sdict.cpp sdictreader.cpp stardict.cpp stardictreader.cpp stardictbuilder.cpp)
TARGET_LINK_LIBRARIES(dictconv ${ZLIB_LIBRARIES} ${XML2_LIBRARY})

INSTALL(TARGETS dictconv
        RUNTIME DESTINATION bin)