[MacPorts] #46701: kerberos5 does not build on PPC Tiger, Mac OS X 10.4.11, because void value cannot be ignored as it ought to be

MacPorts noreply at macports.org
Thu Feb 12 09:38:44 PST 2015


#46701: kerberos5 does not build on PPC Tiger, Mac OS X 10.4.11, because void value
cannot be ignored as it ought to be
------------------------------+--------------------------------
  Reporter:  Peter_Dyballa@…  |      Owner:  macports-tickets@…
      Type:  defect           |     Status:  new
  Priority:  Normal           |  Milestone:
 Component:  ports            |    Version:  2.3.3
Resolution:                   |   Keywords:
      Port:  kerberos5        |
------------------------------+--------------------------------

Comment (by Peter_Dyballa@…):

 I think I have found the cause for the failure – it's not easy to
 understand what GCC 4.2 reports! On (PPC) Tiger unsetenv() is a void, but
 the return value of unsetenv() is compared with zero, which has to fail.
 Changing that block

 {{{

 -    if (unsetenv(KRB5_ENV_CCNAME) != 0) {
 -        retval = errno;
 -        com_err(prog_name, retval, _("while clearing the value of %s"),
 -                KRB5_ENV_CCNAME);
 -        return retval;
 -    }
 }}}

 to simple

 {{{
 +    /* On PPC Tiger unsetenv is a void(), nothing to compare. */
 +    unsetenv(KRB5_ENV_CCNAME);
 }}}

 seems to be equivalent and to fix the issue. This is a rather crude fix,
 because I have no idea which #defines for the Darwin/Mac OS X version
 exist.

-- 
Ticket URL: <https://trac.macports.org/ticket/46701#comment:1>
MacPorts <https://www.macports.org/>
Ports system for OS X


More information about the macports-tickets mailing list