summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorguenther <guenther@openbsd.org>2015-04-04 18:05:04 +0000
committerguenther <guenther@openbsd.org>2015-04-04 18:05:04 +0000
commitfd7ad13f9e73a3dbdacb10746cf5478433753328 (patch)
tree8ccda324cbd947602815a5fa9de16f1ee617a0e5
parentRounding rules for horizontal scaling widths are more complicated. (diff)
downloadwireguard-openbsd-fd7ad13f9e73a3dbdacb10746cf5478433753328.tar.xz
wireguard-openbsd-fd7ad13f9e73a3dbdacb10746cf5478433753328.zip
gcc 2.x is dead
ok millert@
-rw-r--r--include/wchar.h7
-rw-r--r--lib/csu/crtbegin.c12
-rw-r--r--lib/csu/crtbeginS.c13
-rw-r--r--lib/csu/crtend.c4
-rw-r--r--lib/csu/crtendS.c4
-rw-r--r--lib/libedit/sys.h4
-rw-r--r--usr.sbin/npppd/common/debugutil.h4
-rw-r--r--usr.sbin/npppd/npppd/ppp.h6
8 files changed, 13 insertions, 41 deletions
diff --git a/include/wchar.h b/include/wchar.h
index 54e21bc4b47..270bd6c6f78 100644
--- a/include/wchar.h
+++ b/include/wchar.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: wchar.h,v 1.28 2015/02/09 23:02:25 millert Exp $ */
+/* $OpenBSD: wchar.h,v 1.29 2015/04/04 18:05:05 guenther Exp $ */
/* $NetBSD: wchar.h,v 1.16 2003/03/07 07:11:35 tshiozak Exp $ */
/*-
@@ -185,12 +185,9 @@ size_t wcsftime(wchar_t * __restrict, size_t, const wchar_t *__restrict,
const struct tm *__restrict);
#endif
-#if (defined(__GNUC__) && __GNUC__ >= 2 && !defined(__STRICT_ANSI__)) || \
- __ISO_C_VISIBLE >= 1999
-/* LONGLONG */
+#if !defined(__STRICT_ANSI__) || __ISO_C_VISIBLE >= 1999
long long int wcstoll(const wchar_t * __restrict,
wchar_t ** __restrict, int base);
-/* LONGLONG */
unsigned long long int wcstoull(const wchar_t * __restrict,
wchar_t ** __restrict, int base);
#endif
diff --git a/lib/csu/crtbegin.c b/lib/csu/crtbegin.c
index bf2c4fb09cd..e1ffc16bb1b 100644
--- a/lib/csu/crtbegin.c
+++ b/lib/csu/crtbegin.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: crtbegin.c,v 1.17 2013/12/28 18:38:42 kettenis Exp $ */
+/* $OpenBSD: crtbegin.c,v 1.18 2015/04/04 18:05:05 guenther Exp $ */
/* $NetBSD: crtbegin.c,v 1.1 1996/09/12 16:59:03 cgd Exp $ */
/*
@@ -63,13 +63,12 @@ static const char __EH_FRAME_BEGIN__[]
* java class registration hooks
*/
-#if (__GNUC__ > 2)
static void *__JCR_LIST__[]
__attribute__((section(".jcr"), aligned(sizeof(void*)))) = { };
extern void _Jv_RegisterClasses (void *)
__attribute__((weak));
-#endif
+
/*
* Include support for the __cxa_atexit/__cxa_finalize C++ abi for
@@ -79,7 +78,6 @@ extern void _Jv_RegisterClasses (void *)
* http://www.codesourcery.com/cxx-abi/abi.html#dso-dtor
*/
-#if (__GNUC__ > 2)
void *__dso_handle = NULL;
__asm(".hidden __dso_handle");
@@ -92,7 +90,7 @@ atexit(void (*fn)(void))
{
return (__cxa_atexit((void (*)(void *))fn, NULL, NULL));
}
-#endif
+
static const init_f __CTOR_LIST__[1]
__attribute__((section(".ctors"))) = { (void *)-1 }; /* XXX */
@@ -154,12 +152,8 @@ __do_init()
initialized = 1;
__register_frame_info(__EH_FRAME_BEGIN__, &object);
-
-#if (__GNUC__ > 2)
if (__JCR_LIST__[0] && _Jv_RegisterClasses)
_Jv_RegisterClasses(__JCR_LIST__);
-#endif
-
(__ctors)();
atexit(__fini);
diff --git a/lib/csu/crtbeginS.c b/lib/csu/crtbeginS.c
index f3c784214a7..152bfa5ec79 100644
--- a/lib/csu/crtbeginS.c
+++ b/lib/csu/crtbeginS.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: crtbeginS.c,v 1.14 2013/12/28 18:38:42 kettenis Exp $ */
+/* $OpenBSD: crtbeginS.c,v 1.15 2015/04/04 18:05:05 guenther Exp $ */
/* $NetBSD: crtbegin.c,v 1.1 1996/09/12 16:59:03 cgd Exp $ */
/*
@@ -50,13 +50,12 @@
* java class registration hooks
*/
-#if (__GNUC__ > 2)
static void *__JCR_LIST__[]
__attribute__((section(".jcr"), aligned(sizeof(void*)))) = { };
extern void _Jv_RegisterClasses (void *)
__attribute__((weak));
-#endif
+
/*
* Include support for the __cxa_atexit/__cxa_finalize C++ abi for
@@ -66,7 +65,6 @@ extern void _Jv_RegisterClasses (void *)
* http://www.codesourcery.com/cxx-abi/abi.html#dso-dtor
*/
-#if (__GNUC__ > 2)
void *__dso_handle = &__dso_handle;
__asm(".hidden __dso_handle");
@@ -81,7 +79,7 @@ atexit(void (*fn)(void))
return (__cxa_atexit((void (*)(void *))fn, NULL, &__dso_handle));
}
asm(".hidden atexit");
-#endif
+
static init_f __CTOR_LIST__[1]
__attribute__((section(".ctors"))) = { (void *)-1 }; /* XXX */
@@ -141,11 +139,8 @@ _do_init(void)
if (!initialized) {
initialized = 1;
-#if (__GNUC__ > 2)
if (__JCR_LIST__[0] && _Jv_RegisterClasses)
_Jv_RegisterClasses(__JCR_LIST__);
-#endif
-
__ctors();
}
}
@@ -157,10 +152,8 @@ _do_fini(void)
if (!finalized) {
finalized = 1;
-#if (__GNUC__ > 2)
if (__cxa_finalize != NULL)
__cxa_finalize(__dso_handle);
-#endif
/*
* since the _init() function sets up the destructors to
diff --git a/lib/csu/crtend.c b/lib/csu/crtend.c
index 287e7bc1045..6d2ea472a74 100644
--- a/lib/csu/crtend.c
+++ b/lib/csu/crtend.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: crtend.c,v 1.10 2012/12/05 23:19:57 deraadt Exp $ */
+/* $OpenBSD: crtend.c,v 1.11 2015/04/04 18:05:05 guenther Exp $ */
/* $NetBSD: crtend.c,v 1.1 1996/09/12 16:59:04 cgd Exp $ */
#include <sys/types.h>
@@ -13,10 +13,8 @@ static init_f __DTOR_LIST__[1]
static const int __EH_FRAME_END__[]
__used __attribute__((section(".eh_frame"), aligned(4))) = { 0 };
-#if (__GNUC__ > 2)
static void * __JCR_END__[]
__used __attribute__((section(".jcr"), aligned(sizeof(void*)))) = { 0 };
-#endif
MD_SECTION_EPILOGUE(".init");
MD_SECTION_EPILOGUE(".fini");
diff --git a/lib/csu/crtendS.c b/lib/csu/crtendS.c
index 6ebfc5b3591..d83e6160232 100644
--- a/lib/csu/crtendS.c
+++ b/lib/csu/crtendS.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: crtendS.c,v 1.8 2012/12/05 23:19:57 deraadt Exp $ */
+/* $OpenBSD: crtendS.c,v 1.9 2015/04/04 18:05:05 guenther Exp $ */
/* $NetBSD: crtend.c,v 1.1 1997/04/16 19:38:24 thorpej Exp $ */
#include <sys/types.h>
@@ -10,10 +10,8 @@ static init_f __CTOR_LIST__[1]
static init_f __DTOR_LIST__[1]
__used __attribute__((section(".dtors"))) = { (void *)0 }; /* XXX */
-#if (__GNUC__ > 2)
static void * __JCR_END__[]
__used __attribute__((section(".jcr"), aligned(sizeof(void*)))) = { 0 };
-#endif
MD_SECTION_EPILOGUE(".init");
MD_SECTION_EPILOGUE(".fini");
diff --git a/lib/libedit/sys.h b/lib/libedit/sys.h
index cb01859112a..b5a00249380 100644
--- a/lib/libedit/sys.h
+++ b/lib/libedit/sys.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: sys.h,v 1.9 2010/06/30 00:05:35 nicm Exp $ */
+/* $OpenBSD: sys.h,v 1.10 2015/04/04 18:05:05 guenther Exp $ */
/* $NetBSD: sys.h,v 1.13 2009/12/30 22:37:40 christos Exp $ */
/*-
@@ -45,7 +45,7 @@
#include <sys/cdefs.h>
#endif
-#if !defined(__attribute__) && (defined(__cplusplus) || !defined(__GNUC__) || __GNUC__ == 2 && __GNUC_MINOR__ < 8)
+#if !defined(__attribute__) && defined(__cplusplus)
# define __attribute__(A)
#endif
diff --git a/usr.sbin/npppd/common/debugutil.h b/usr.sbin/npppd/common/debugutil.h
index 60fef162d64..82b0dbe92d6 100644
--- a/usr.sbin/npppd/common/debugutil.h
+++ b/usr.sbin/npppd/common/debugutil.h
@@ -49,13 +49,9 @@ extern int debuglevel;
/* adapted from FreeBSD:/usr/include/sys/cdefs */
#ifndef __printflike
-#if __GNUC__ < 2 || __GNUC__ == 2 && __GNUC_MINOR__ < 7
-#define __printflike(fmtarg, firstvararg)
-#else
#define __printflike(fmtarg, firstvararg) \
__attribute__((__format__ (__printf__, fmtarg, firstvararg)))
#endif
-#endif
#ifdef __cplusplus
extern "C" {
diff --git a/usr.sbin/npppd/npppd/ppp.h b/usr.sbin/npppd/npppd/ppp.h
index e5c4a2305b7..af3d4d9d52e 100644
--- a/usr.sbin/npppd/npppd/ppp.h
+++ b/usr.sbin/npppd/npppd/ppp.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: ppp.h,v 1.16 2013/04/26 02:20:04 gsoares Exp $ */
+/* $OpenBSD: ppp.h,v 1.17 2015/04/04 18:05:04 guenther Exp $ */
/*-
* Copyright (c) 2009 Internet Initiative Japan Inc.
@@ -703,13 +703,9 @@ typedef struct _dialin_proxy_info {
/* adapted from FreeBSD:/usr/include/sys/cdefs */
#ifndef __printflike
-#if __GNUC__ < 2 || __GNUC__ == 2 && __GNUC_MINOR__ < 7
-#define __printflike(fmtarg, firstvararg)
-#else
#define __printflike(fmtarg, firstvararg) \
__attribute__((__format__ (__printf__, fmtarg, firstvararg)))
#endif
-#endif
/*
* Does MRU cover MPPE/CCP header?