${PROJECT_BINARY_DIR}/nominatim)
endif()
-
- add_custom_target(serve
- php -S 127.0.0.1:8088
- WORKING_DIRECTORY ${PROJECT_BINARY_DIR}/website
- )
-
- add_custom_target(serve-global
- php -S 0.0.0.0:8088
- WORKING_DIRECTORY ${PROJECT_BINARY_DIR}/website
- )
+#-----------------------------------------------------------------------------
+# Targets for running a development webserver from the build directory.
+#-----------------------------------------------------------------------------
+
+if (BUILD_API)
+ set(WEBSITEFILES
+ 403.html
+ 509.html
+ crossdomain.xml
+ favicon.ico
+ nominatim.xml
+ robots.txt
+ taginfo.json
+ )
+
+ foreach (webfile ${WEBSITEFILES})
+ configure_file(${PROJECT_SOURCE_DIR}/website/${webfile}
+ ${PROJECT_BINARY_DIR}/website/${webfile})
+ endforeach()
+endif()
+
#-----------------------------------------------------------------------------
# Tests
#-----------------------------------------------------------------------------