From e1e28f09f37b5f0ee67b806d29934022c9654214 Mon Sep 17 00:00:00 2001
From: patrick96
Date: Fri, 17 May 2019 09:44:35 +0200
Subject: [PATCH] refactor(build): Remove version number namespace
I don't know the original intention behind this but it clutters up debug
traces and basically makes ccache useless.
The only benefit it has, giving version info in stacktraces, is kind of
void since we already ask for version information on github issues.
---
CMakeLists.txt | 2 --
include/common.hpp | 4 +---
include/settings.hpp.cmake | 1 -
3 files changed, 1 insertion(+), 6 deletions(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 1907c14f..837ef9df 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -40,8 +40,6 @@ else()
set(APP_VERSION "${version_txt}")
endif()
-STRING(REGEX REPLACE "[^a-zA-Z0-9_]" "_" APP_VERSION_NAMESPACE "v${APP_VERSION}")
-
set(CMAKE_MODULE_PATH
${CMAKE_MODULE_PATH}
${PROJECT_SOURCE_DIR}/cmake
diff --git a/include/common.hpp b/include/common.hpp
index e29ef35b..6da08c49 100644
--- a/include/common.hpp
+++ b/include/common.hpp
@@ -8,10 +8,8 @@
#include "settings.hpp"
#define POLYBAR_NS \
- namespace polybar { \
- inline namespace APP_VERSION_NAMESPACE {
+ namespace polybar {
#define POLYBAR_NS_END \
- } \
}
#ifndef PIPE_READ
diff --git a/include/settings.hpp.cmake b/include/settings.hpp.cmake
index 34713b0d..73882477 100644
--- a/include/settings.hpp.cmake
+++ b/include/settings.hpp.cmake
@@ -6,7 +6,6 @@
#define APP_NAME "@PROJECT_NAME@"
#cmakedefine APP_VERSION "@APP_VERSION@"
-#cmakedefine APP_VERSION_NAMESPACE @APP_VERSION_NAMESPACE@
#cmakedefine01 ENABLE_ALSA
#cmakedefine01 ENABLE_MPD