mirror of
https://github.com/xzeldon/htop.git
synced 2024-12-24 15:15:44 +00:00
Quote SYSCONFDIR definition
As SYSCONFDIR is a compile time string literal, use compile time string concatenation instead of a runtime one. Also drop related TODO, cause we indeed using the correct way of getting $sysconfdir from autoconf
This commit is contained in:
parent
06b1674aa6
commit
8bd543562b
@ -18,7 +18,7 @@ pixmap_DATA = htop.png
|
||||
appicondir = $(datadir)/icons/hicolor/scalable/apps
|
||||
appicon_DATA = htop.svg
|
||||
|
||||
AM_CFLAGS += -pedantic -std=c99 -D_XOPEN_SOURCE_EXTENDED -DSYSCONFDIR=\"$(sysconfdir)\" -I"$(top_srcdir)/$(my_htop_platform)"
|
||||
AM_CFLAGS += -pedantic -std=c99 -D_XOPEN_SOURCE_EXTENDED -DSYSCONFDIR="\"$(sysconfdir)\"" -I"$(top_srcdir)/$(my_htop_platform)"
|
||||
AM_LDFLAGS =
|
||||
|
||||
myhtopsources = \
|
||||
|
@ -424,10 +424,7 @@ Settings* Settings_new(int initialCpuCount) {
|
||||
}
|
||||
if (!ok) {
|
||||
this->changed = true;
|
||||
// TODO: how to get SYSCONFDIR correctly through Autoconf?
|
||||
char* systemSettings = String_cat(SYSCONFDIR, "/htoprc");
|
||||
ok = Settings_read(this, systemSettings, initialCpuCount);
|
||||
free(systemSettings);
|
||||
ok = Settings_read(this, SYSCONFDIR "/htoprc", initialCpuCount);
|
||||
}
|
||||
if (!ok) {
|
||||
Settings_defaultMeters(this, initialCpuCount);
|
||||
|
Loading…
Reference in New Issue
Block a user