build: Move all possible variables into settings.cpp

Anything that doesn't have to be used as a macro
This commit is contained in:
patrick96 2019-10-28 09:56:19 +01:00 committed by Patrick Ziegler
parent 100632cce3
commit 3ea7600412
2 changed files with 13 additions and 7 deletions

View File

@ -11,7 +11,6 @@ extern const char* const APP_VERSION;
#cmakedefine01 ENABLE_MPD #cmakedefine01 ENABLE_MPD
#cmakedefine01 ENABLE_NETWORK #cmakedefine01 ENABLE_NETWORK
#cmakedefine01 WITH_LIBNL #cmakedefine01 WITH_LIBNL
#define WIRELESS_LIB "@WIRELESS_LIB@"
#cmakedefine01 ENABLE_I3 #cmakedefine01 ENABLE_I3
#cmakedefine01 ENABLE_CURL #cmakedefine01 ENABLE_CURL
#cmakedefine01 ENABLE_PULSEAUDIO #cmakedefine01 ENABLE_PULSEAUDIO
@ -54,10 +53,10 @@ static const int SIGN_PRIORITY_BAR{3};
static const int SIGN_PRIORITY_RENDERER{4}; static const int SIGN_PRIORITY_RENDERER{4};
static const int SIGN_PRIORITY_TRAY{5}; static const int SIGN_PRIORITY_TRAY{5};
static const int SINK_PRIORITY_BAR{1}; extern const int SINK_PRIORITY_BAR;
static const int SINK_PRIORITY_SCREEN{2}; extern const int SINK_PRIORITY_SCREEN;
static const int SINK_PRIORITY_TRAY{3}; extern const int SINK_PRIORITY_TRAY;
static const int SINK_PRIORITY_MODULE{4}; extern const int SINK_PRIORITY_MODULE;
extern const char* const ALSA_SOUNDCARD; extern const char* const ALSA_SOUNDCARD;
extern const char* const BSPWM_SOCKET_PATH; extern const char* const BSPWM_SOCKET_PATH;
@ -70,9 +69,10 @@ extern const char* const PATH_CPU_INFO;
extern const char* const PATH_MEMORY_INFO; extern const char* const PATH_MEMORY_INFO;
extern const char* const PATH_MESSAGING_FIFO; extern const char* const PATH_MESSAGING_FIFO;
extern const char* const PATH_TEMPERATURE_INFO; extern const char* const PATH_TEMPERATURE_INFO;
extern const char* const WIRELESS_LIB;
extern bool version_details(const std::vector<std::string>& args); bool version_details(const std::vector<std::string>& args);
extern void print_build_info(bool extended = false); void print_build_info(bool extended = false);
// vim:ft=cpp // vim:ft=cpp

View File

@ -3,6 +3,11 @@
const char* const APP_NAME{"@PROJECT_NAME@"}; const char* const APP_NAME{"@PROJECT_NAME@"};
const char* const APP_VERSION{"@APP_VERSION@"}; const char* const APP_VERSION{"@APP_VERSION@"};
const int SINK_PRIORITY_BAR{1};
const int SINK_PRIORITY_SCREEN{2};
const int SINK_PRIORITY_TRAY{3};
const int SINK_PRIORITY_MODULE{4};
const char* const ALSA_SOUNDCARD{"@SETTING_ALSA_SOUNDCARD@"}; const char* const ALSA_SOUNDCARD{"@SETTING_ALSA_SOUNDCARD@"};
const char* const BSPWM_SOCKET_PATH{"@SETTING_BSPWM_SOCKET_PATH@"}; const char* const BSPWM_SOCKET_PATH{"@SETTING_BSPWM_SOCKET_PATH@"};
const char* const BSPWM_STATUS_PREFIX{"@SETTING_BSPWM_STATUS_PREFIX@"}; const char* const BSPWM_STATUS_PREFIX{"@SETTING_BSPWM_STATUS_PREFIX@"};
@ -14,6 +19,7 @@ const char* const PATH_CPU_INFO{"@SETTING_PATH_CPU_INFO@"};
const char* const PATH_MEMORY_INFO{"@SETTING_PATH_MEMORY_INFO@"}; const char* const PATH_MEMORY_INFO{"@SETTING_PATH_MEMORY_INFO@"};
const char* const PATH_MESSAGING_FIFO{"@SETTING_PATH_MESSAGING_FIFO@"}; const char* const PATH_MESSAGING_FIFO{"@SETTING_PATH_MESSAGING_FIFO@"};
const char* const PATH_TEMPERATURE_INFO{"@SETTING_PATH_TEMPERATURE_INFO@"}; const char* const PATH_TEMPERATURE_INFO{"@SETTING_PATH_TEMPERATURE_INFO@"};
const char* const WIRELESS_LIB{"@WIRELESS_LIB@"};
bool version_details(const std::vector<std::string>& args) { bool version_details(const std::vector<std::string>& args) {
for (auto&& arg : args) { for (auto&& arg : args) {