Use PROGNAME_SETTINGS for settings(1)
This commit is contained in:
parent
f98c004503
commit
29cbff2575
|
@ -30,21 +30,21 @@
|
||||||
#define _(string) gettext(string)
|
#define _(string) gettext(string)
|
||||||
|
|
||||||
/* constants */
|
/* constants */
|
||||||
#ifndef PROGNAME
|
#ifndef PROGNAME_SETTINGS
|
||||||
# define PROGNAME "settings"
|
# define PROGNAME_SETTINGS "settings"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifndef PREFIX
|
#ifndef PREFIX
|
||||||
# define PREFIX "/usr/local"
|
# define PREFIX "/usr/local"
|
||||||
#endif
|
#endif
|
||||||
#ifndef BINDIR
|
#ifndef BINDIR
|
||||||
# define BINDIR PREFIX "/bin"
|
# define BINDIR PREFIX "/bin"
|
||||||
#endif
|
#endif
|
||||||
#ifndef DATADIR
|
#ifndef DATADIR
|
||||||
# define DATADIR PREFIX "/share"
|
# define DATADIR PREFIX "/share"
|
||||||
#endif
|
#endif
|
||||||
#ifndef LOCALEDIR
|
#ifndef LOCALEDIR
|
||||||
# define LOCALEDIR DATADIR "/locale"
|
# define LOCALEDIR DATADIR "/locale"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
@ -367,7 +367,7 @@ static int _settings_browse_folder(Settings * settings, Config * config,
|
||||||
name = config_get(config, section, "Name");
|
name = config_get(config, section, "Name");
|
||||||
exec = config_get(config, section, "Exec");
|
exec = config_get(config, section, "Exec");
|
||||||
if(p == NULL || name == NULL || exec == NULL
|
if(p == NULL || name == NULL || exec == NULL
|
||||||
|| strcmp(exec, PROGNAME) == 0)
|
|| strcmp(exec, PROGNAME_SETTINGS) == 0)
|
||||||
continue;
|
continue;
|
||||||
if(strcmp(p, application) != 0)
|
if(strcmp(p, application) != 0)
|
||||||
continue;
|
continue;
|
||||||
|
@ -484,7 +484,7 @@ static int _settings_browse_home(Settings * settings, Config * config)
|
||||||
/* settings_error */
|
/* settings_error */
|
||||||
static int _settings_error(char const * message, int ret)
|
static int _settings_error(char const * message, int ret)
|
||||||
{
|
{
|
||||||
fprintf(stderr, "%s: %s\n", PROGNAME, message);
|
fprintf(stderr, "%s: %s\n", PROGNAME_SETTINGS, message);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -492,7 +492,7 @@ static int _settings_error(char const * message, int ret)
|
||||||
/* settings_usage */
|
/* settings_usage */
|
||||||
static int _settings_usage(void)
|
static int _settings_usage(void)
|
||||||
{
|
{
|
||||||
fputs("Usage: " PROGNAME "\n", stderr);
|
fputs("Usage: " PROGNAME_SETTINGS "\n", stderr);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user