don't include fmemopen in tools builds. Since tools does not define
_NETBSD_SOURCE, we don't get the fmemopen prototype
This commit is contained in:
parent
c8b1f28fd2
commit
0d1cbc6a00
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: main1.c,v 1.23 2014/04/18 01:18:54 christos Exp $ */
|
||||
/* $NetBSD: main1.c,v 1.24 2014/04/18 02:17:14 christos Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1994, 1995 Jochen Pohl
|
||||
@ -37,7 +37,7 @@
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
#if defined(__RCSID) && !defined(lint)
|
||||
__RCSID("$NetBSD: main1.c,v 1.23 2014/04/18 01:18:54 christos Exp $");
|
||||
__RCSID("$NetBSD: main1.c,v 1.24 2014/04/18 02:17:14 christos Exp $");
|
||||
#endif
|
||||
|
||||
#include <sys/types.h>
|
||||
@ -128,7 +128,7 @@ sig_atomic_t fpe;
|
||||
|
||||
static void usage(void);
|
||||
|
||||
#ifdef __NetBSD__
|
||||
#if !HAVE_NBTOOL_CONFIG_H
|
||||
static const char builtins[] =
|
||||
"int __builtin_isinf(long double);\n"
|
||||
"int __builtin_isnan(long double);\n"
|
||||
@ -222,7 +222,7 @@ main(int argc, char *argv[])
|
||||
initscan();
|
||||
initmtab();
|
||||
|
||||
#ifdef __NetBSD__
|
||||
#if !HAVE_NBTOOL_CONFIG_H
|
||||
if ((yyin = fmemopen(__UNCONST(builtins), sizeof(builtins) - 1, "r"))
|
||||
== NULL)
|
||||
err(1, "cannot open builtins");
|
||||
|
Loading…
Reference in New Issue
Block a user