dtdocbook/instant: the musl C library does not define MAXNAMLEN
Use the POSIX alternative NAME_MAX instead.
This commit is contained in:
committed by
Jon Trulson
parent
21491c0e52
commit
668b9c19a3
@@ -70,6 +70,7 @@ static char *CopyRt =
|
|||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <ctype.h>
|
#include <ctype.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
#include <limits.h>
|
||||||
#include <memory.h>
|
#include <memory.h>
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
@@ -89,8 +90,12 @@ static char *CopyRt =
|
|||||||
|
|
||||||
/* for backwards compatibility */
|
/* for backwards compatibility */
|
||||||
#ifndef _MAXNAMLEN
|
#ifndef _MAXNAMLEN
|
||||||
|
#ifndef MAXNAMLEN
|
||||||
|
#define _MAXNAMLEN NAME_MAX
|
||||||
|
#else
|
||||||
#define _MAXNAMLEN MAXNAMLEN
|
#define _MAXNAMLEN MAXNAMLEN
|
||||||
#endif
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
static int do_context, do_tree, do_summ, do_stats, do_validate, do_idlist;
|
static int do_context, do_tree, do_summ, do_stats, do_validate, do_idlist;
|
||||||
static char *this_prog;
|
static char *this_prog;
|
||||||
|
|||||||
Reference in New Issue
Block a user