Use a platform-specific routine for long option usage

Related to https://github.com/htop-dev/htop/pull/564
This commit is contained in:
Nathan Scott
2021-03-22 14:49:07 +11:00
parent d56d23d91a
commit 253ff23f9e
9 changed files with 51 additions and 36 deletions

View File

@ -26,9 +26,6 @@ in the source distribution for its full text.
#include "generic/uname.h"
#define PLATFORM_LONG_OPTIONS
#define PLATFORM_LONG_OPTIONS_USAGE
#define kill(pid, signal) kill(pid / 1024, signal)
typedef struct var kvar_t;
@ -92,6 +89,10 @@ static inline void Platform_getRelease(char** string) {
*string = Generic_uname();
}
#define PLATFORM_LONG_OPTIONS
static inline void Platform_longOptionsUsage(ATTR_UNUSED const char* name) { }
static inline bool Platform_getLongOption(ATTR_UNUSED int opt, ATTR_UNUSED int argc, ATTR_UNUSED char** argv) {
return false;
}