From c78e60f41a91f920714301f30e499be57b1f7b72 Mon Sep 17 00:00:00 2001 From: "Sunrim KIM (keen)" <3han5chou7@gmail.com> Date: Mon, 21 Jul 2014 22:39:27 +0900 Subject: [PATCH] Revert "make contribs independant of the directory structure of picrin" This reverts commit cdee9d91349ba53a23244d1f3ea5061c8c074975. --- {contrib/10.regexp/cmake => cmake}/FindREGEX.cmake | 0 contrib/10.partcont/CMakeLists.txt | 2 +- contrib/10.pretty-print/CMakeLists.txt | 2 +- contrib/10.regexp/CMakeLists.txt | 5 +---- contrib/20.for/CMakeLists.txt | 2 +- contrib/CMakeLists.txt | 3 +-- 6 files changed, 5 insertions(+), 9 deletions(-) rename {contrib/10.regexp/cmake => cmake}/FindREGEX.cmake (100%) diff --git a/contrib/10.regexp/cmake/FindREGEX.cmake b/cmake/FindREGEX.cmake similarity index 100% rename from contrib/10.regexp/cmake/FindREGEX.cmake rename to cmake/FindREGEX.cmake diff --git a/contrib/10.partcont/CMakeLists.txt b/contrib/10.partcont/CMakeLists.txt index bedbbd75..65f16fb2 100644 --- a/contrib/10.partcont/CMakeLists.txt +++ b/contrib/10.partcont/CMakeLists.txt @@ -1,2 +1,2 @@ -file(GLOB PARTCONT_FILES ${PICRIN_CONTRIB_DIR}/10.partcont/piclib/*.scm) +file(GLOB PARTCONT_FILES ${PROJECT_SOURCE_DIR}/contrib/10.partcont/piclib/*.scm) list(APPEND PICLIB_CONTRIB_LIBS ${PARTCONT_FILES}) diff --git a/contrib/10.pretty-print/CMakeLists.txt b/contrib/10.pretty-print/CMakeLists.txt index c5353018..cf0327da 100644 --- a/contrib/10.pretty-print/CMakeLists.txt +++ b/contrib/10.pretty-print/CMakeLists.txt @@ -1 +1 @@ -list(APPEND PICLIB_CONTRIB_LIBS ${PICRIN_CONTRIB_DIR}/10.pretty-print/pretty-print.scm) +list(APPEND PICLIB_CONTRIB_LIBS ${PROJECT_SOURCE_DIR}/contrib/10.pretty-print/pretty-print.scm) diff --git a/contrib/10.regexp/CMakeLists.txt b/contrib/10.regexp/CMakeLists.txt index aa177aaa..6ab06aaa 100644 --- a/contrib/10.regexp/CMakeLists.txt +++ b/contrib/10.regexp/CMakeLists.txt @@ -1,14 +1,11 @@ # regex -set(PICRIN_REGEX_DIR ${PICRIN_CONTRIB_DIR}/10.regexp) -set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${PICRIN_REGEX_DIR}/cmake/") - find_package(REGEX) if (REGEX_FOUND) add_definitions(${REGEX_DEFINITIONS}) include_directories(${REGEX_INCLUDE_DIR}) - file(GLOB PICRIN_REGEX_SOURCES ${PICRIN_REGEX_DIR}/src/*.c) + file(GLOB PICRIN_REGEX_SOURCES ${PROJECT_SOURCE_DIR}/contrib/10.regexp/src/*.c) list(APPEND PICRIN_CONTRIB_INITS regexp) list(APPEND PICRIN_CONTRIB_LIBRARIES ${REGEX_LIBRARIES}) diff --git a/contrib/20.for/CMakeLists.txt b/contrib/20.for/CMakeLists.txt index 9b0f64f0..ebe66a42 100644 --- a/contrib/20.for/CMakeLists.txt +++ b/contrib/20.for/CMakeLists.txt @@ -1,2 +1,2 @@ -file(GLOB FOR_FILES ${PICRIN_CONTRIB_DIR}/20.for/piclib/*.scm) +file(GLOB FOR_FILES ${PROJECT_SOURCE_DIR}/contrib/20.for/piclib/*.scm) list(APPEND PICLIB_CONTRIB_LIBS ${FOR_FILES}) diff --git a/contrib/CMakeLists.txt b/contrib/CMakeLists.txt index 50c586de..11050d90 100644 --- a/contrib/CMakeLists.txt +++ b/contrib/CMakeLists.txt @@ -1,5 +1,4 @@ -set(PICRIN_CONTRIB_DIR ${PROJECT_SOURCE_DIR}/contrib) -file(GLOB CONTRIBS ${PICRIN_CONTRIB_DIR}/*/CMakeLists.txt) +file(GLOB CONTRIBS ${PROJECT_SOURCE_DIR}/contrib/*/CMakeLists.txt) list(SORT CONTRIBS) foreach(contrib ${CONTRIBS}) include(${contrib})