3 #----------------------------------------------------------------------------
4 IF(${BBTK_PACKAGE_NAME}_INCLUDE_ALL_BBS_BOXES)
6 ${BBTK_PACKAGE_NAME}_BBS_BOXES
7 RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
11 # !! Produces a cmake seg. fault :
13 # ${BBTK_PACKAGE_NAME}_BBS_BOXES
18 ENDIF(${BBTK_PACKAGE_NAME}_INCLUDE_ALL_BBS_BOXES)
19 #----------------------------------------------------------------------------
21 #----------------------------------------------------------------------------
22 IF(${BBTK_PACKAGE_NAME}_INCLUDE_ALL_BBS_APPLI)
23 FILE(GLOB ${BBTK_PACKAGE_NAME}_BBS_APPLI
24 RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
27 ENDIF(${BBTK_PACKAGE_NAME}_INCLUDE_ALL_BBS_APPLI)
28 #----------------------------------------------------------------------------
30 #----------------------------------------------------------------------------
31 INCLUDE(${BBTK_CMAKE_DIR}/BBTKCreatePackageIncludeScript.cmake)
33 BBTK_CREATE_PACKAGE_INCLUDE_SCRIPT(
34 "${BBTK_PACKAGE_NAME}"
35 "${${BBTK_PACKAGE_NAME}_BBS_BOXES}"
36 "${${BBTK_PACKAGE_NAME}_BBS_APPLI}"
38 #----------------------------------------------------------------------------
40 #----------------------------------------------------------------------------
41 #---------------------------------------------------------------------------
43 # If a core package set option from bbtk global one
44 IF (BUILD_BBS_APPLI_BINARIES)
45 SET(BUILD_BBTK_PACKAGE_${BBTK_PACKAGE_NAME}_BBS_APP ON)
46 ELSE (BUILD_BBS_APPLI_BINARIES)
47 SET(BUILD_BBTK_PACKAGE_${BBTK_PACKAGE_NAME}_BBS_APP OFF)
48 ENDIF (BUILD_BBS_APPLI_BINARIES)
49 ELSE(BBTK_CORE_PACKAGE)
50 # If not a core package
52 OPTION(BUILD_BBTK_PACKAGE_${BBTK_PACKAGE_NAME}_BBS_APP
53 "Build binaries for bbs applications of package ${BBTK_PACKAGE_NAME} ?" OFF)
54 SWITCH_ON_IF_BUILD_ALL(BUILD_BBTK_PACKAGE_${BBTK_PACKAGE_NAME}_BBS_APP)
55 ENDIF(BBTK_CORE_PACKAGE)
56 #---------------------------------------------------------------------------
59 IF (BUILD_BBTK_PACKAGE_${BBTK_PACKAGE_NAME}_BBS_APP)
60 FOREACH(bbs ${${BBTK_PACKAGE_NAME}_BBS_APPLI})
61 GET_FILENAME_COMPONENT(name "${bbs}" NAME_WE)
64 OUTPUT ${BBTK_BIN_PATH}/${OUTPUT}
66 cd ${BBTK_BIN_PATH} && ${BBTK_BBC} ${BBTK_PACKAGE_NAME}/appli/${name}
68 ${BBTK_BBS2CPP_DEPENDENCY}
71 FILES ${BBTK_BIN_PATH}/${OUTPUT}
74 ADD_CUSTOM_TARGET(${OUTPUT} ALL
75 DEPENDS ${BBTK_BIN_PATH}/${OUTPUT}
80 ENDIF (BUILD_BBTK_PACKAGE_${BBTK_PACKAGE_NAME}_BBS_APP)
81 #----------------------------------------------------------------------------