aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/constants.hpp.in
diff options
context:
space:
mode:
authorJosh Blum <josh@joshknows.com>2010-08-12 03:49:37 +0000
committerJosh Blum <josh@joshknows.com>2010-08-11 21:13:34 -0700
commit836c6bcda0065ad5345e1b7545feefab5a81e566 (patch)
tree15c0dbb3832a81054477c53953300b0e13e89835 /host/lib/constants.hpp.in
parent9503c5101007ba1261b8d23ee6a17305bbaa6f2a (diff)
downloaduhd-836c6bcda0065ad5345e1b7545feefab5a81e566.tar.gz
uhd-836c6bcda0065ad5345e1b7545feefab5a81e566.tar.bz2
uhd-836c6bcda0065ad5345e1b7545feefab5a81e566.zip
uhd: avoid segfaults - use CPP macros for paths and dont split empty string
Diffstat (limited to 'host/lib/constants.hpp.in')
-rw-r--r--host/lib/constants.hpp.in7
1 files changed, 4 insertions, 3 deletions
diff --git a/host/lib/constants.hpp.in b/host/lib/constants.hpp.in
index 295c8f16c..aa51e558c 100644
--- a/host/lib/constants.hpp.in
+++ b/host/lib/constants.hpp.in
@@ -21,8 +21,9 @@
#include <uhd/config.hpp>
#include <string>
-static const std::string UHD_VERSION_STRING = "@CPACK_PACKAGE_VERSION@";
-static const std::string UHD_INSTALL_PREFIX = "@CMAKE_INSTALL_PREFIX@";
-static const std::string UHD_PKG_DATA_DIR = "@PKG_DATA_DIR@";
+//these should be pre-processor macros to avoid static initialization issues
+#define UHD_VERSION_STRING "@CPACK_PACKAGE_VERSION@"
+#define UHD_INSTALL_PREFIX "@CMAKE_INSTALL_PREFIX@"
+#define UHD_PKG_DATA_DIR "@PKG_DATA_DIR@"
#endif /* INCLUDED_LIBUHD_CONSTANTS_HPP */