summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorPeter Wu <peter@lekensteyn.nl>2016-11-29 00:44:56 +0100
committerMichael Mann <mmann78@netscape.net>2016-12-05 01:35:26 +0000
commit83a1ab23abdb22ae7b84cff99009988f97fb3653 (patch)
tree8e30c454093ae268cf533ac04ba0205f46657e6a /CMakeLists.txt
parentfca6bf6a99b08be574ab8679104d19623b4881fc (diff)
downloadwireshark-83a1ab23abdb22ae7b84cff99009988f97fb3653.tar.gz
cmake: Fix building with plugins disabled
When Lua is enabled, scripts can still be loaded from the plugin dir (filesystem.c uses PLUGIN_INSTALL_DIR), so be sure to set it or the cmake build fails. Change-Id: I87d2d705434052220f9619438c90905c24b2a3a6 Reviewed-on: https://code.wireshark.org/review/18976 Reviewed-by: Peter Wu <peter@lekensteyn.nl> Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt14
1 files changed, 8 insertions, 6 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 942bb3b180..446657c950 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1191,7 +1191,14 @@ if(LIBSSH_FOUND)
endif()
endif()
-# Location of our plugins. PLUGIN_DIRECTORY should allow running
+# Directory where plugins and Lua dissectors can be found.
+if (WIN32)
+ set(PLUGIN_INSTALL_DIR "plugins/${CPACK_PACKAGE_VERSION}")
+else ()
+ set(PLUGIN_INSTALL_DIR "${CMAKE_INSTALL_LIBDIR}/${CPACK_PACKAGE_NAME}/plugins/${CPACK_PACKAGE_VERSION}")
+endif()
+
+# Location of our plugins. PLUGIN_DIR should allow running
# from the build directory similar to DATAFILE_DIR above.
if(ENABLE_PLUGINS)
# Target platform locations
@@ -1201,11 +1208,6 @@ if(ENABLE_PLUGINS)
set(HAVE_PLUGINS 1)
add_custom_target(plugins)
set_target_properties(plugins PROPERTIES FOLDER "Plugins")
- if (WIN32)
- set(PLUGIN_INSTALL_DIR "plugins/${CPACK_PACKAGE_VERSION}")
- else ()
- set(PLUGIN_INSTALL_DIR "${CMAKE_INSTALL_LIBDIR}/${CPACK_PACKAGE_NAME}/plugins/${CPACK_PACKAGE_VERSION}")
- endif()
set(PLUGIN_SRC_DIRS
plugins/docsis
plugins/ethercat