include_directories(${UDEV_INCLUDE_DIR})
endif()
-set(FGJS_SOURCES
- fgjs.cxx
- jsinput.cxx
- jssuper.cxx
- )
-
-add_executable(fgjs ${FGJS_SOURCES})
+if(ENABLE_FGJS)
+ set(FGJS_SOURCES
+ fgjs.cxx
+ jsinput.cxx
+ jssuper.cxx
+ )
-target_link_libraries(fgjs
- ${SIMGEAR_CORE_LIBRARIES}
- ${PLIB_LIBRARIES}
- ${SIMGEAR_CORE_LIBRARY_DEPENDENCIES})
+ add_executable(fgjs ${FGJS_SOURCES})
+ target_link_libraries(fgjs
+ ${SIMGEAR_CORE_LIBRARIES}
+ ${PLIB_LIBRARIES}
+ ${SIMGEAR_CORE_LIBRARY_DEPENDENCIES}
+ )
-add_executable(js_demo js_demo.cxx)
+ install(TARGETS fgjs RUNTIME DESTINATION bin)
+endif()
-target_link_libraries(js_demo
- ${SIMGEAR_CORE_LIBRARIES}
- ${PLIB_LIBRARIES}
- ${SIMGEAR_CORE_LIBRARY_DEPENDENCIES})
+if(ENABLE_JS_DEMO)
+ add_executable(js_demo js_demo.cxx)
+ target_link_libraries(js_demo
+ ${SIMGEAR_CORE_LIBRARIES}
+ ${PLIB_LIBRARIES}
+ ${SIMGEAR_CORE_LIBRARY_DEPENDENCIES}
+ )
-flightgear_component(Input "${SOURCES}" "${HEADERS}")
+ install(TARGETS js_demo RUNTIME DESTINATION bin)
+endif()
-install(TARGETS fgjs js_demo RUNTIME DESTINATION bin)
+flightgear_component(Input "${SOURCES}" "${HEADERS}")
\ No newline at end of file