# Use the installed appli
IF(WIN32)
+ SET (EXECUTABLE_OUTPUT_REL_PATH "")
+ SET (LIBRARY_OUTPUT_REL_PATH "")
FILE(TO_NATIVE_PATH ${PROJECT_BINARY_DIR}/$(OutDir) BBTK_BIN_PATH)
# TO DO : use computed path for build/install tree
SET(BBTK_BBI "${BBTK_DIR}/bin/bbi")
SET(BBTK_BBDOC "${BBTK_DIR}/bin/bbdoc")
ELSE(WIN32)
- FILE(TO_NATIVE_PATH ${EXECUTABLE_OUTPUT_PATH} BBTK_BIN_PATH)
- # TO DO : use computed path for build/install tree
- SET(BBTK_BBI "${BBTK_DIR}/../../bin/bbi")
- SET(BBTK_BBS2CPP "${BBTK_DIR}/../../bin/bbs2cpp")
- SET(BBTK_BBC "${BBTK_DIR}/../../bin/bbc")
- SET(BBTK_BBFY "${BBTK_DIR}/../../bin/bbfy")
- SET(BBTK_BBDOC "${BBTK_DIR}/../../bin/bbdoc")
+# SET (EXECUTABLE_OUTPUT_REL_PATH bin)
+# SET (LIBRARY_OUTPUT_REL_PATH bin)
+ SET(BBTK_BIN_PATH ${BBTK_INSTALL_PREFIX}/bin)
+ SET(BBTK_BBI "${BBTK_BIN_PATH}/bbi")
+ SET(BBTK_BBS2CPP "${BBTK_BIN_PATH}/bbs2cpp")
+ SET(BBTK_BBC "${BBTK_BIN_PATH}/bbc")
+ SET(BBTK_BBFY "${BBTK_BIN_PATH}/bbfy")
+ SET(BBTK_BBDOC "${BBTK_BIN_PATH}/bbdoc")
ENDIF(WIN32)
# runs bbtk-make-index as a post install step
IF(NOT BBTK_CORE_PACKAGE)
- INSTALL(CODE "EXECUTE_PROCESS(COMMAND bbtk-make-index)")
+ INSTALL(CODE "EXECUTE_PROCESS(COMMAND ${BBTK_BIN_PATH}/bbtk-make-index)")
ENDIF(NOT BBTK_CORE_PACKAGE)
#-----------------------------------------------------------------------------
+#-----------------------------------------------------------------------------
+SET(BBTK_INSTALL_PREFIX ${CMAKE_INSTALL_PREFIX})
+#-----------------------------------------------------------------------------
+
#-----------------------------------------------------------------------------
# The vars BBTK_DOC_REL_PATH and BBTK_BBS_REL_PATH
# store documentation and scripts **RELATIVE** paths
SET(BBTK_BBS_BUILD_PATH ${PROJECT_BINARY_DIR}/${BBTK_BBS_REL_PATH})
SET(BBTK_DATA_BUILD_PATH ${PROJECT_BINARY_DIR}/${BBTK_DATA_REL_PATH})
-SET(BBTK_DOC_INSTALL_PATH ${CMAKE_INSTALL_PREFIX}/${BBTK_DOC_REL_PATH})
-SET(BBTK_BBDOC_INSTALL_PATH ${CMAKE_INSTALL_PREFIX}/${BBTK_BBDOC_REL_PATH})
-SET(BBTK_DOXYGEN_INSTALL_PATH ${CMAKE_INSTALL_PREFIX}/${BBTK_DOXYGEN_REL_PATH})
-SET(BBTK_BBS_INSTALL_PATH ${CMAKE_INSTALL_PREFIX}/${BBTK_BBS_REL_PATH})
-SET(BBTK_DATA_INSTALL_PATH ${CMAKE_INSTALL_PREFIX}/${BBTK_DATA_REL_PATH})
+SET(BBTK_DOC_INSTALL_PATH ${BBTK_INSTALL_PREFIX}/${BBTK_DOC_REL_PATH})
+SET(BBTK_BBDOC_INSTALL_PATH ${BBTK_INSTALL_PREFIX}/${BBTK_BBDOC_REL_PATH})
+SET(BBTK_DOXYGEN_INSTALL_PATH ${BBTK_INSTALL_PREFIX}/${BBTK_DOXYGEN_REL_PATH})
+SET(BBTK_BBS_INSTALL_PATH ${BBTK_INSTALL_PREFIX}/${BBTK_BBS_REL_PATH})
+SET(BBTK_DATA_INSTALL_PATH ${BBTK_INSTALL_PREFIX}/${BBTK_DATA_REL_PATH})
# Create build directories if necessary
MKDIR(${BBTK_DOC_BUILD_PATH})
)
ENDFOREACH(path ${CFP_RELATIVE_LIBRARY_PATHS})
+# Set the "prefix path"
+SET(@LIBRARY_NAME@_INSTALL_PREFIX ${CFP_LIBRARY_PATH_PREFIX})
# The C and C++ flags added by @LIBRARY_NAME@ to the cmake-configured flags.
SET(@LIBRARY_NAME@_REQUIRED_C_FLAGS "@CFP_LIB_REQUIRED_C_FLAGS@")
${BBTK_BBDOC_BUILD_PATH}/bbtk-make-index
@ONLY
)
+CONFIGURE_FILE(
+ ${CMAKE_CURRENT_SOURCE_DIR}/bbtk-make-index.sh.in
+ ${BBTK_BIN_PATH}/bbtk-make-index
+ @ONLY
+ )
INSTALL(
PROGRAMS ${BBTK_BBDOC_BUILD_PATH}/bbtk-make-index
DESTINATION bin
echo "** Recreating bbtk doc index **"
TMP=$(which $0|rev)
-TMP2=$(echo ${TMP#*/}|rev)
-DIR=${TMP2}/../@bbtk_install_gnome_DATA_REL_PATH@
+BIN=$(echo ${TMP#*/}|rev)
-echo "> cd ${DIR}/@BBTK_BBDOC_REL_PATH@"
-cd ${DIR}/@BBTK_BBDOC_REL_PATH@
+echo "> cd ${BIN}/../@BBTK_BBDOC_REL_PATH@"
+cd ${BIN}/../@BBTK_BBDOC_REL_PATH@
-echo "> bbi -n ./make-index"
-bbi -n ./make-index
+echo "> ${BIN}/bbi ./make-index"
+${BIN}/bbi ./make-index
echo "** Done ! **"