I would try to do it through the configure/autoconf process and change the
code to be something like:

#ifdef SQL_FRIEND
#  ifdef HAVE_UNISTD_H
#    include <unistd.h>
#  endif
#  ifdef HAVE_CRYPT_H
#    include <crypt.h>
#  endif
#endif


But the configure process is based on autoconf 2.53 rather than something
modern, so making that work right in autoconf might be painful


--- Richard Conto

DNA Sequencing Core
Biomedical Research Core Facilities
Medical School Administration Office of Research
NCRC Bldg 14 room 168 -- (734) 764-7620


On Tue, Aug 12, 2014 at 10:24 AM, Liam Hoekenga <li...@umich.edu> wrote:

> OSX apparently doesn't have crypt.h.  It's stuff is in unistd.h.  This is
> a problem if you're building with the mysql stuff enabled.
>
> Does this look like a reasonable patch?
>
> --- cosign-cosign-3.3.0-branch/cgi/login.c 2014-06-02 14:44:48.000000000
> -0400
> +++ cosign-3.3.0rc1/cgi/login.c 2014-08-12 10:18:25.000000000 -0400
> @@ -14,5 +14,9 @@
>  #include <errno.h>
>  # ifdef SQL_FRIEND
> -#include <crypt.h>
> +    #ifdef __APPLE__
> +    #include <unistd.h>
> +    #else
> +    #include <crypt.h>
> +    #endif
>  # endif
>  #include <ctype.h>
>
> Liam
>
>
> ------------------------------------------------------------------------------
>
> _______________________________________________
> Cosign-discuss mailing list
> Cosign-discuss@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/cosign-discuss
>
>
------------------------------------------------------------------------------
_______________________________________________
Cosign-discuss mailing list
Cosign-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/cosign-discuss

Reply via email to