From 9df03145fa63817fd4bf8557f4002f7174709125 Mon Sep 17 00:00:00 2001 From: christos Date: Tue, 6 Nov 2007 19:13:16 +0000 Subject: [PATCH] move the test to replace getopt higher up, before we need to include anything. --- lib/libc/stdlib/getopt_long.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/lib/libc/stdlib/getopt_long.c b/lib/libc/stdlib/getopt_long.c index 7e9a625d5268..c9111b89043a 100644 --- a/lib/libc/stdlib/getopt_long.c +++ b/lib/libc/stdlib/getopt_long.c @@ -1,4 +1,4 @@ -/* $NetBSD: getopt_long.c,v 1.21 2007/07/05 16:05:40 ginsbach Exp $ */ +/* $NetBSD: getopt_long.c,v 1.22 2007/11/06 19:13:16 christos Exp $ */ /*- * Copyright (c) 2000 The NetBSD Foundation, Inc. @@ -33,9 +33,14 @@ #include "nbtool_config.h" #endif +#if HAVE_NBTOOL_CONFIG_H && !HAVE_GETOPT_LONG && !HAVE_DECL_OPTIND +#define REPLACE_GETOPT +#endif + +#ifdef REPLACE_GETOPT #include #if defined(LIBC_SCCS) && !defined(lint) -__RCSID("$NetBSD: getopt_long.c,v 1.21 2007/07/05 16:05:40 ginsbach Exp $"); +__RCSID("$NetBSD: getopt_long.c,v 1.22 2007/11/06 19:13:16 christos Exp $"); #endif /* LIBC_SCCS and not lint */ #include "namespace.h" @@ -51,11 +56,6 @@ __RCSID("$NetBSD: getopt_long.c,v 1.21 2007/07/05 16:05:40 ginsbach Exp $"); #include #include -#if HAVE_NBTOOL_CONFIG_H && !HAVE_GETOPT_LONG && !HAVE_DECL_OPTIND -#define REPLACE_GETOPT -#endif - -#ifdef REPLACE_GETOPT #ifdef __weak_alias __weak_alias(getopt,_getopt) #endif