glibc-2.3.2-decc-compaq.patch

Marc Giger <[email protected]>
Newsgroups gmane.linux.gentoo.alpha
Message-ID <[email protected]>
Hi devs,

I'm playing around with the ccc/cxx and found some interesting things.

Can someone of you comment why the following patch is needed?

diff -ruN glibc-2.3.2.orig/include/features.h
glibc-2.3.2/include/features.h--- glibc-2.3.2.orig/include/features.h
2003-06-14 00:28:23.000000000 +0100+++ glibc-2.3.2/include/features.h   
  2003-06-14 00:58:57.000000000 +0100@@ -285,7 +285,8 @@
 #if defined __GNUC__ \
|| (defined __PGI && defined __i386__ ) \
|| (defined __INTEL_COMPILER && (defined __i386__ || defined __ia64__))\
- || (defined __STDC_VERSION__ && __STDC_VERSION__ >= 199901L)
+ || (defined __STDC_VERSION__ && __STDC_VERSION__ >= 199901L)\
+ &&!(defined(__DECC) || defined(__DECCXX)) 
# define__GLIBC_HAVE_LONG_LONG      1 
#endif

The Compaq C Compiler knows the "long long" datatype like gcc does. It's
also of the same size on both compilers 
(long == long int == long long == 8bytes). 

This breaks the compilation (with ccc) of some packages.

Comments?


Another thing is the following...:

printf '%s %s %s\n' \
                "-L${gcc_libs_path}" \
                " -SysIncDir
/usr/lib/compaq/ccc-${ccc_release}/alpha-linux/include" \               
" -SysIncDir /usr/include/linux" \                >
usr/lib/compaq/ccc-${ccc_release}/alpha-linux/bin/comp.config

..declared in the ccc ebuild. That's a big problem. I needed a lot of
time to figure out, why ccc could not compile files which had declared
INT_MAX or something like that. (@see <limits.h>)

The standard include path and the ccc include path must be declared
BEFORE gcc's include paths in comp.config, otherwise the INT_MAX & Co
Macros expands to __INT_MAX__ because the #include_next directives.
__INT_MAX__ is a predefined gcc thing.

Thank you for the time. Please mail me to discuss these.

greets

Marc

--
[email protected] mailing list
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.