Rename tools, make them installable
This commit is contained in:
parent
238e7a2bb9
commit
c77d994dc4
|
@ -285,14 +285,17 @@ endif ()
|
||||||
target_link_libraries (${PROJECT_NAME} ${project_libraries})
|
target_link_libraries (${PROJECT_NAME} ${project_libraries})
|
||||||
|
|
||||||
# Tools
|
# Tools
|
||||||
set (tools tabfile add-pronunciation query-tool transform)
|
set (tools tdv-tabfile tdv-add-pronunciation tdv-query-tool tdv-transform)
|
||||||
foreach (tool ${tools})
|
foreach (tool ${tools})
|
||||||
add_executable (${tool} EXCLUDE_FROM_ALL
|
add_executable (${tool} EXCLUDE_FROM_ALL
|
||||||
src/${tool}.c ${project_common_sources})
|
src/${tool}.c ${project_common_sources})
|
||||||
target_link_libraries (${tool} ${project_common_libraries})
|
target_link_libraries (${tool} ${project_common_libraries})
|
||||||
endforeach ()
|
endforeach ()
|
||||||
|
|
||||||
add_custom_target (tools DEPENDS ${tools})
|
option (WITH_TOOLS "Build and install some StarDict tools" ${UNIX})
|
||||||
|
if (WITH_TOOLS)
|
||||||
|
add_custom_target (tools ALL DEPENDS ${tools})
|
||||||
|
endif ()
|
||||||
|
|
||||||
# Example dictionaries
|
# Example dictionaries
|
||||||
file (GLOB dicts_scripts "${PROJECT_SOURCE_DIR}/dicts/*.*")
|
file (GLOB dicts_scripts "${PROJECT_SOURCE_DIR}/dicts/*.*")
|
||||||
|
@ -315,6 +318,9 @@ if (NOT WIN32)
|
||||||
install (TARGETS ${PROJECT_NAME} DESTINATION ${CMAKE_INSTALL_BINDIR})
|
install (TARGETS ${PROJECT_NAME} DESTINATION ${CMAKE_INSTALL_BINDIR})
|
||||||
install (FILES LICENSE DESTINATION ${CMAKE_INSTALL_DOCDIR})
|
install (FILES LICENSE DESTINATION ${CMAKE_INSTALL_DOCDIR})
|
||||||
|
|
||||||
|
if (WITH_TOOLS)
|
||||||
|
install (TARGETS ${tools} DESTINATION ${CMAKE_INSTALL_BINDIR})
|
||||||
|
endif ()
|
||||||
if (WITH_GUI)
|
if (WITH_GUI)
|
||||||
install (FILES ${PROJECT_NAME}.svg
|
install (FILES ${PROJECT_NAME}.svg
|
||||||
DESTINATION ${CMAKE_INSTALL_DATADIR}/icons/hicolor/scalable/apps)
|
DESTINATION ${CMAKE_INSTALL_DATADIR}/icons/hicolor/scalable/apps)
|
||||||
|
|
|
@ -81,10 +81,10 @@ The `make dicts` command will build some examples from freely available sources:
|
||||||
- Czech foreign words (the site's export is broken as of 2022/08, no response)
|
- Czech foreign words (the site's export is broken as of 2022/08, no response)
|
||||||
- Czech WordNet 1.9 PDT (synonyms, hypernyms, hyponyms)
|
- Czech WordNet 1.9 PDT (synonyms, hypernyms, hyponyms)
|
||||||
|
|
||||||
You can use the included 'transform' tool to convert already existing StarDict
|
You can use the included 'tdv-transform' tool to convert already existing
|
||||||
dictionaries that are nearly good as they are. Remember that you can change
|
StarDict dictionaries that are nearly good as they are. Remember that you can
|
||||||
the `sametypesequence` of the resulting '.ifo' file to another format, or run
|
change the `sametypesequence` of the resulting '.ifo' file to another format,
|
||||||
'dictzip' on '.dict' files to make them compact.
|
or run 'dictzip' on '.dict' files to make them compact.
|
||||||
|
|
||||||
https://mega.co.nz/#!axtD0QRK!sbtBgizksyfkPqKvKEgr8GQ11rsWhtqyRgUUV0B7pwg[CZ <--> EN/DE/PL/RU dictionaries]
|
https://mega.co.nz/#!axtD0QRK!sbtBgizksyfkPqKvKEgr8GQ11rsWhtqyRgUUV0B7pwg[CZ <--> EN/DE/PL/RU dictionaries]
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
*
|
*
|
||||||
* The external filter needs to process NUL-separated textual entries.
|
* The external filter needs to process NUL-separated textual entries.
|
||||||
*
|
*
|
||||||
* Example: transform input.ifo output -- perl -p0e s/bullshit/soykaf/g
|
* Example: tdv-transform input.ifo output -- perl -p0e s/bullshit/soykaf/g
|
||||||
*
|
*
|
||||||
* Copyright (c) 2020, Přemysl Eric Janouch <p@janouch.name>
|
* Copyright (c) 2020, Přemysl Eric Janouch <p@janouch.name>
|
||||||
*
|
*
|
Loading…
Reference in New Issue