Samba 4 diffs for building under HP-UX 11.11 (in gcc environment)

tridge at samba.org tridge at samba.org
Wed Aug 17 23:44:46 GMT 2005


Don,

 > I got inspired after the CIFS conference, and Tridge's talk about the
 > Samba 4 test suite.  So I'm working with our lab to start moving over
 > from our internal test suite to one build on (or at least 
 > incorporating) the Samba 4 test suite.
 > In order to do this, I had to make some code changes so that Samba 4
 > would build (under gcc) on HP-UX.

Thanks! 

 > +#if defined(HAVE_SETEUID)
 >  	if (geteuid() != s->uid &&
 >  	    seteuid(s->uid) != 0) {
 > +#elif defined(HAVE_SETRESUID) && !defined(HAVE_SETEUID)
 > +	if (geteuid() != s->uid &&
 > +	    setresuid(-1,s->uid,-1) != 0) {
 > +#endif

The approach we have been taking for these types of things is to add
the missing function in lib/replace/

I'll add something in based on your patch and see if it helps for
'gwen', the HPUX machine we have in the build farm.

 > +/**********************************************************************
 > +*/ #if !defined(HAVE_STRTOLL) && defined(HAVE___STRTOLL) #include 
 > +<inttypes.h> long long strtoll(const char *nptr, char ** endptr, int
 > +base) {
 > +        return __strtoll(nptr,endptr,base); } #endif
 >  

ahh, I didn't realise HPUX had a __strtoll(). Does it also have a
__strtoull() ? I'll add a check for that as well and update the code
in lib/replace/ to handle both.

Watch for a patch in a few minutes ...

Cheers, Tridge


More information about the samba-technical mailing list