Let the thread to be managed outside the binding.
[apps/agl-service-can-low-level.git] / CAN-binder / low-can-demo / CMakeLists.txt
index a554598..918920c 100644 (file)
@@ -17,9 +17,6 @@
 # limitations under the License.
 ###########################################################################
 
-# Add subdir targets
-search_targets()
-
 # Add target to project dependency list
 PROJECT_TARGET_ADD(low-can-demo)
 
@@ -27,19 +24,20 @@ PROJECT_TARGET_ADD(low-can-demo)
        add_custom_command(OUTPUT dist.prod
        DEPENDS ${TARGET_NAME}
        WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
-       COMMAND npm install
-       COMMAND gulp build-app-prod
+       COMMAND [ -d "dist.prod" ] || npm install
+       COMMAND [ -d "dist.prod" ] || gulp build-app-prod
+       COMMAND touch dist.prod
        COMMAND cp -r dist.prod ${CMAKE_CURRENT_BINARY_DIR})
 
        add_custom_target(${TARGET_NAME} ALL DEPENDS dist.prod)
+
        # Binder exposes a unique public entry point
        SET_TARGET_PROPERTIES(${TARGET_NAME} PROPERTIES
-               PREFIX ""
                LABELS "HTDOCS"
                OUTPUT_NAME dist.prod)
 
        # installation directory
        INSTALL(DIRECTORY dist.prod/ DESTINATION ${BINDINGS_INSTALL_DIR})
 
-       populate_widget()
\ No newline at end of file
+# Add subdir targets
+project_subdirs_add()