From: Shlomi Fish Date: Thu, 21 Jul 2016 15:41:40 +0000 (+0300) Subject: Build some of the cookies. X-Git-Tag: fortune-mod-1.99.3~23 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=7d0a2d666521b05eb2a20668291eeddbcc7ff38b;p=fortune-mod Build some of the cookies. --- diff --git a/fortune-mod/CMakeLists.txt b/fortune-mod/CMakeLists.txt index 878f6f0..104bc92 100644 --- a/fortune-mod/CMakeLists.txt +++ b/fortune-mod/CMakeLists.txt @@ -120,3 +120,5 @@ ADD_DEFINITIONS("-DLOCOFFDIR=\"${LOCALODIR}\"") ADD_DEFINITIONS("-DLOCFORTDIR=\"${LOCALDIR}\"") ADD_DEFINITIONS("-DOFFDIR=\"${OCOOKIEDIR}\"") ADD_DEFINITIONS("-DFORTDIR=\"${COOKIEDIR}\"") + +ADD_SUBDIRECTORY("datfiles") diff --git a/fortune-mod/datfiles/CMakeLists.txt b/fortune-mod/datfiles/CMakeLists.txt new file mode 100644 index 0000000..70aba09 --- /dev/null +++ b/fortune-mod/datfiles/CMakeLists.txt @@ -0,0 +1,59 @@ +SET (COOKIES + art + ascii-art + computers + cookie + definitions + drugs + education + ethnic + food + fortunes + goedel + humorists + kids + law + linuxcookie + literature + love + magic + medicine + men-women + miscellaneous + news + people + pets + platitudes + politics + riddles + science + songs-poems + sports + startrek + translate-me + wisdom + work + linux + perl + knghtbrd + paradoxum + zippy + debian +) + +FOREACH(c ${COOKIES}) + SET(TARGET_NAME "cookie__${c}") + SET(DEST "${c}.dat") + SET(SOURCE "${CMAKE_CURRENT_SOURCE_DIR}/${c}") + + ADD_CUSTOM_COMMAND( + OUTPUT "${DEST}" + COMMAND "${CMAKE_CURRENT_BINARY_DIR}/../strfile" + ARGS "${SOURCE}" "${DEST}" + DEPENDS "${SOURCE}" + ) + ADD_CUSTOM_TARGET( + "${TARGET_NAME}" ALL + DEPENDS "${DEST}" + ) +ENDFOREACH()