Bug 3452 - 4.0 TP1 configure bugs with Sun Studio 11
Summary: 4.0 TP1 configure bugs with Sun Studio 11
Status: RESOLVED FIXED
Alias: None
Product: Samba 4.0
Classification: Unclassified
Component: Other (show other bugs)
Version: unspecified
Hardware: Sparc Solaris
: P3 normal (vote)
Target Milestone: ---
Assignee: Andrew Bartlett
QA Contact: Andrew Bartlett
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-01-26 08:50 UTC by David S. Collier-Brown
Modified: 2007-07-17 00:02 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David S. Collier-Brown 2006-01-26 08:50:47 UTC
I have some additional and some overalpping errors
when I switch from gcc4 to the free (beer) Sun
compilers. Theyr'e labelled warnings, but
the compiles eventually fail from side-effects
of these. 

"./include/config.h", line 1082: warning: macro redefined: _FILE_OFFSET_BITS
This is detected by gcc as well.  Configure should test to see if 
_FILE_OFFSET_BITS exists already, in the code that reports
---
checking for special C compiler options needed for large files... no
checking for _FILE_OFFSET_BITS value needed for large files... 64
checking for _LARGE_FILES value needed for large files... no
---

"lib/registry/reg_backend_nt4.c", line 748: undefined symbol: __FUNCTION__
This is the use of __FUNCTION__ instead of __func__ in the
_DEBUG macro. Configure says
checking for __FUNCTION__ macro... no
so we really shouldn't use it if it doesn't exist (;-))
I'd suggest checking for __FUNCTION__ and
if it fails checking for __func__


"./lib/appweb/mpr/miniMpr.h", line 204: warning: old-style declaration or incorrect type for: __extension__^M
"./lib/appweb/mpr/miniMpr.h", line 204: syntax error before or at: typedef
The code says
---
#ifndef uint
        #define uint unsigned
#endif
        __extension__ typedef long long int int64;
        __extension__ typedef unsigned long long int uint64;
#endif
---
I suspect configure should test if __extension__ works
and define it to blanks if itd oes not. This will
bite several vendor and third-party compilers.



And this one looks like a sun bug:
"./librpc/gen_ndr/orpc.h", line 131: warning: enumerator value overflows INT_MAX (2147483647)
The hex value is a negative int, so the 
enum COMRESULT {
        COM_OK=0x00000000,
        COM_OUTOFMEMORY=0x80000002,
        COM_INVALIDARG=0x80000003,
        COM_NOINTERFACE=0x80000004,
        COM_ACCESSDENIED=0x80070005,
        COM_INVALID_OXID=0x80070776,
        COM_INVALID_OID=0x80070777,
        COM_INVALID_SET=0x80070778,
        COM_UNEXPECTED=0x8000FFFF,
        COM_CLSNOTFOUND=0x80040154
The standard allows unsigned, but says the
implementor is free to use either signed
or unsigned ints. Sun seems to have chosen
signed ints.
Comment 1 Jelmer Vernooij 2006-03-10 07:47:51 UTC
The __FUNCTION__ issue in reg_backend_nt4.c has apparently been fixed in SVN.
Comment 2 Andrew Bartlett 2007-07-17 00:02:55 UTC
I presume these have been fixed by now.  Please re-file against the current SVN if it's an issue.