make nls/gettext support optional patch by Jos van der Ende http://bugs.gentoo.org/205576 --- cpufrequtils-005/Makefile +++ cpufrequtils-005/Makefile @@ -141,6 +141,7 @@ ifeq ($(strip $(NLS)),true) INSTALL_NLS += install-gmo COMPILE_NLS += update-gmo + CFLAGDEF += -DNLS endif --- cpufrequtils-005/utils/info.c +++ cpufrequtils-005/utils/info.c @@ -10,7 +10,6 @@ #include #include #include -#include #include #include @@ -18,9 +17,18 @@ #include "cpufreq.h" +#ifdef NLS +#include #define _(String) gettext (String) #define gettext_noop(String) String #define N_(String) gettext_noop (String) +#else +#define gettext_noop(String) String +#define _(String) gettext_noop (String) +#define gettext(String) gettext_noop (String) +#define N_(String) gettext_noop (String) +#define textdomain(String) +#endif #define LINE_LEN 10 --- cpufrequtils-005/utils/set.c +++ cpufrequtils-005/utils/set.c @@ -12,16 +12,24 @@ #include #include #include -#include #include #include #include "cpufreq.h" +#ifdef NLS +#include #define _(String) gettext (String) #define gettext_noop(String) String #define N_(String) gettext_noop (String) +#else +#define gettext_noop(String) String +#define _(String) gettext_noop (String) +#define gettext(String) gettext_noop (String) +#define N_(String) gettext_noop (String) +#define textdomain(String) +#endif #define NORM_FREQ_LEN 32