This is the mail archive of the newlib@sourceware.org mailing list for the newlib project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] remove _CONST from _LIB_VERSION


Checked in with minor modification to ChangeLog entry.

-- Jeff J.

Patrick Mansfield wrote:
Remove _CONST from _LIB_VERSION, as it is supposed to be writable.

I have an alternate patch to instead make it a define when __STDC__
defined (so it matches current allowed behaviour), that patch shrank the
libm.a size -t totals for me from 132784 to 100784, but of course then it
is no longer a runtime variable.

-- Patrick Mansfield

Index: build-spu-cvs-newlib/ChangeLog
===================================================================
RCS file: /cvs/src/src/ChangeLog,v
retrieving revision 1.673
diff -u -r1.673 ChangeLog
--- build-spu-cvs-newlib/ChangeLog 30 Aug 2006 13:14:18 -0000 1.673
+++ build-spu-cvs-newlib/ChangeLog 12 Sep 2006 22:28:04 -0000
@@ -1,3 +1,8 @@
+2006-09-12 Patrick Mansfield <patmans@us.ibm.com>
+
+ * include/math.h, s_lib_ver.c:
+ Remove _CONST from _LIB_VERSION, as it is supposed to be writable.
+
2006-08-30 Corinna Vinschen <corinna@vinschen.de>
* configure.in: Never build newlib for a Mingw host.
Index: build-spu-cvs-newlib/newlib/libc/include/math.h
===================================================================
RCS file: /cvs/src/src/newlib/libc/include/math.h,v
retrieving revision 1.21
diff -u -r1.21 math.h
--- build-spu-cvs-newlib/newlib/libc/include/math.h 27 Feb 2006 23:51:28 -0000 1.21
+++ build-spu-cvs-newlib/newlib/libc/include/math.h 12 Sep 2006 22:28:05 -0000
@@ -406,7 +406,7 @@
#define _LIB_VERSION_TYPE enum __fdlibm_version
#define _LIB_VERSION __fdlib_version
-extern __IMPORT _CONST _LIB_VERSION_TYPE _LIB_VERSION;
+extern __IMPORT _LIB_VERSION_TYPE _LIB_VERSION;
#define _IEEE_ __fdlibm_ieee
#define _SVID_ __fdlibm_svid
Index: build-spu-cvs-newlib/newlib/libm/common/s_lib_ver.c
===================================================================
RCS file: /cvs/src/src/newlib/libm/common/s_lib_ver.c,v
retrieving revision 1.1.1.1
diff -u -r1.1.1.1 s_lib_ver.c
--- build-spu-cvs-newlib/newlib/libm/common/s_lib_ver.c 17 Feb 2000 19:39:51 -0000 1.1.1.1
+++ build-spu-cvs-newlib/newlib/libm/common/s_lib_ver.c 12 Sep 2006 22:28:05 -0000
@@ -21,15 +21,15 @@
* define and initialize _LIB_VERSION
*/
#ifdef _POSIX_MODE
-_CONST _LIB_VERSION_TYPE _LIB_VERSION = _POSIX_;
+_LIB_VERSION_TYPE _LIB_VERSION = _POSIX_;
#else
#ifdef _XOPEN_MODE
-_CONST _LIB_VERSION_TYPE _LIB_VERSION = _XOPEN_;
+_LIB_VERSION_TYPE _LIB_VERSION = _XOPEN_;
#else
#ifdef _SVID3_MODE
-_CONST _LIB_VERSION_TYPE _LIB_VERSION = _SVID_;
+_LIB_VERSION_TYPE _LIB_VERSION = _SVID_;
#else /* default _IEEE_MODE */
-_CONST _LIB_VERSION_TYPE _LIB_VERSION = _IEEE_;
+_LIB_VERSION_TYPE _LIB_VERSION = _IEEE_;
#endif
#endif
#endif


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]