Cyrus SASL will not compile on Solaris 8

Cyrus SASL will not compile on Solaris 8

Post by John_ » Tue, 20 Sep 2005 22:50:42



I am attempting to compile Cyrus SASL v2.1.21 so that I can (try to) get
Apache LDAP to cooperate with Sun Java System Directory Server on a
Solaris 8 (SPARC) system.  I'm using GCC v3.4.2 and GNU Make v3.80

I'm running the following for the configure:
     CFLAGS="-mcpu=v9" ./configure

Unfortunately, when I run "make" I get a flood of what look like syntax
errors compiling the digestmd5 code...

digestmd5.c:971: error: dereferencing pointer to incomplete type
digestmd5.c:972: error: `DES_DECRYPT' undeclared (first use in this
function)
digestmd5.c:976: error: dereferencing pointer to incomplete type
digestmd5.c: In function `enc_des':
digestmd5.c:1021: error: dereferencing pointer to incomplete type
digestmd5.c:1022: error: dereferencing pointer to incomplete type
digestmd5.c:1023: error: `DES_ENCRYPT' undeclared (first use in this
function)
digestmd5.c:1027: error: dereferencing pointer to incomplete type
digestmd5.c: In function `init_des':
digestmd5.c:1042: error: invalid application of `sizeof' to incomplete
type `digestmd5.c'
digestmd5.c:1047: error: `des_cblock' undeclared (first use in this
function)
digestmd5.c:1047: error: parse error before ')' token
digestmd5.c:1049: error: dereferencing pointer to incomplete type
digestmd5.c:1054: error: increment of pointer to unknown structure
digestmd5.c:1054: error: arithmetic on pointer to an incomplete type
digestmd5.c:1056: error: parse error before ')' token
digestmd5.c:1058: error: dereferencing pointer to incomplete type
make[2]: *** [digestmd5.lo] Error 1
make[2]: Leaving directory `/tmp/cyrus-sasl-2.1.21/plugins'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/tmp/cyrus-sasl-2.1.21'
make: *** [all] Error 2

Do anyone know how to correct this problem?  Did I miss a configuration
option somewhere?

-- John

 
 
 

Cyrus SASL will not compile on Solaris 8

Post by Marc » Tue, 20 Sep 2005 23:28:09



> digestmd5.c:972: error: `DES_DECRYPT' undeclared (first use in this
> function)

I don't know this program, but it seems to be missing either
#include <openssl/des.h>
or
#include <rpc/des_crypt.h> (less likely)

 
 
 

Cyrus SASL will not compile on Solaris 8

Post by John_ » Wed, 21 Sep 2005 00:12:15




>>digestmd5.c:972: error: `DES_DECRYPT' undeclared (first use in this
>>function)

> I don't know this program, but it seems to be missing either
> #include <openssl/des.h>
> or
> #include <rpc/des_crypt.h> (less likely)

SSL is installed, but as a package from SunFreeware.  The des.h file is
located in /usr/local/ssl/include/openssl.  I take it that this is not a
standard location?  (This kind of sensitivity is really what turns me
off of compiling from source code.)

Anyway, I ran a "make clean", then ran
    CFLAGS="-mcpu=v9" ./configure --includedir=/usr/local/ssl
which failed with the syntax errors.

So, I ran "make clean" and ran
    CFLAGS="-mcpu=v9" ./configure --includedir=/usr/local/ssl/include.
I confirmed in Makefile that "includedir = /usr/local/ssl/include", but
it still came back with errors:

gcc -DHAVE_CONFIG_H -I. -I. -I.. -I../include -I../lib -I../sasldb
-I../include -Wall -W -mcpu=v9 -MT digestmd5.lo -MD -MP -MF
.deps/digestmd5.Tpo -c digestmd5.c  -fPIC -DPIC -o digestmd5.lo
digestmd5.c:812: error: parse error before "des_key_schedule"
digestmd5.c:812: warning: no semicolon at end of struct or union
digestmd5.c:813: warning: type defaults to `int' in declaration of `ivec'
digestmd5.c:813: warning: data definition has no type or storage class
digestmd5.c:814: error: parse error before "keysched2"
digestmd5.c:814: warning: type defaults to `int' in declaration of
`keysched2'
digestmd5.c:814: warning: data definition has no type or storage class
digestmd5.c: In function `dec_3des':
digestmd5.c:849: warning: implicit declaration of function
`des_ede2_cbc_encrypt'
digestmd5.c:852: error: dereferencing pointer to incomplete type
<..snip..>

It still looks like somethihng is not being included properly.  I also
don't see /usr/local/ssl/include specified in the gcc command.  (I don't
know if it needs to be as I'm not anywhere close to being a compiling/C
expert.)

Any ideas?

-- John

 
 
 

Cyrus SASL will not compile on Solaris 8

Post by John_ » Wed, 21 Sep 2005 00:26:04



> SSL is installed, but as a package from SunFreeware.  The des.h file is
> located in /usr/local/ssl/include/openssl.

> Anyway, I ran a "make clean", then ran
>    CFLAGS="-mcpu=v9" ./configure --includedir=/usr/local/ssl
> which failed with the syntax errors.

> So, I ran "make clean" and ran
>    CFLAGS="-mcpu=v9" ./configure --includedir=/usr/local/ssl/include.
> I confirmed in Makefile that "includedir = /usr/local/ssl/include", but
> it still came back with errors:

Okay.  Shows how much of a Monday this is turning out to be.   It's in
/usr/local/ssl/include/openssl and that's the path that I didn't
include.  DUH.   Unfortunately, even when I did change that, the
compilation still bombed out.

According to the configure script, it expects the directory to be in
$INCLUDEDIR/include, which is not the case there.  So, I copied the .h
files into /usr/local/ssl/include, ran configure again with INCLUDEDIR
as "/usr/local/ssl".   Make is still bombing out at the same location:

gcc -DHAVE_CONFIG_H -I. -I. -I.. -I../include -I../lib -I../sasldb
-I../include -Wall -W -mcpu=v9 -MT digestmd5.lo -MD -MP -MF
.deps/digestmd5.Tpo -c digestmd5.c  -fPIC -DPIC -o digestmd5.lo
digestmd5.c:812: error: parse error before "des_key_schedule"
digestmd5.c:812: warning: no semicolon at end of struct or union
digestmd5.c:813: warning: type defaults to `int' in declaration of `ivec'
digestmd5.c:813: warning: data definition has no type or storage class
digestmd5.c:814: error: parse error before "keysched2"
digestmd5.c:814: warning: type defaults to `int' in declaration of
`keysched2'
digestmd5.c:814: warning: data definition has no type or storage class
digestmd5.c: In function `dec_3des':
digestmd5.c:849: warning: implicit declaration of function
`des_ede2_cbc_encrypt'
digestmd5.c:852: error: dereferencing pointer to incomplete type
digestmd5.c:853: error: dereferencing pointer to incomplete type
digestmd5.c:854: error: dereferencing pointer to incomplete type
digestmd5.c:855: error: `DES_DECRYPT' undeclared (first use in this
function)
digestmd5.c:855: error: (Each undeclared identifier is reported only once
<..snip..>

I'm really getting this close to just using Sun Java Web Server.  I
would assume (which I know is dangerous) that Sun's web server would
easily plug into Sun's directory server.  But I'd prefer to not have to
worry about licensing issues by using Apache and mod_auth_ldap.
Unfortunately, that seems to require SASL.

-- John

 
 
 

Cyrus SASL will not compile on Solaris 8

Post by Jeroen Bess » Wed, 21 Sep 2005 02:05:25




>> SSL is installed, but as a package from SunFreeware.  The des.h file
>> is located in /usr/local/ssl/include/openssl.

>> Anyway, I ran a "make clean", then ran
>>    CFLAGS="-mcpu=v9" ./configure --includedir=/usr/local/ssl
>> which failed with the syntax errors.

>> So, I ran "make clean" and ran
>>    CFLAGS="-mcpu=v9" ./configure --includedir=/usr/local/ssl/include.
>> I confirmed in Makefile that "includedir = /usr/local/ssl/include",
>> but it still came back with errors:

> Okay.  Shows how much of a Monday this is turning out to be.   It's in
> /usr/local/ssl/include/openssl and that's the path that I didn't
> include.  DUH.   Unfortunately, even when I did change that, the
> compilation still bombed out.

> According to the configure script, it expects the directory to be in
> $INCLUDEDIR/include, which is not the case there.  So, I copied the .h
> files into /usr/local/ssl/include, ran configure again with INCLUDEDIR
> as "/usr/local/ssl".   Make is still bombing out at the same location:

> gcc -DHAVE_CONFIG_H -I. -I. -I.. -I../include -I../lib -I../sasldb
> -I../include -Wall -W -mcpu=v9 -MT digestmd5.lo -MD -MP -MF
> .deps/digestmd5.Tpo -c digestmd5.c  -fPIC -DPIC -o digestmd5.lo
> digestmd5.c:812: error: parse error before "des_key_schedule"
> digestmd5.c:812: warning: no semicolon at end of struct or union
> digestmd5.c:813: warning: type defaults to `int' in declaration of `ivec'
> digestmd5.c:813: warning: data definition has no type or storage class
> digestmd5.c:814: error: parse error before "keysched2"
> digestmd5.c:814: warning: type defaults to `int' in declaration of
> `keysched2'
> digestmd5.c:814: warning: data definition has no type or storage class
> digestmd5.c: In function `dec_3des':
> digestmd5.c:849: warning: implicit declaration of function
> `des_ede2_cbc_encrypt'
> digestmd5.c:852: error: dereferencing pointer to incomplete type
> digestmd5.c:853: error: dereferencing pointer to incomplete type
> digestmd5.c:854: error: dereferencing pointer to incomplete type
> digestmd5.c:855: error: `DES_DECRYPT' undeclared (first use in this
> function)
> digestmd5.c:855: error: (Each undeclared identifier is reported only once
> <..snip..>

> I'm really getting this close to just using Sun Java Web Server.  I
> would assume (which I know is dangerous) that Sun's web server would
> easily plug into Sun's directory server.  But I'd prefer to not have to
> worry about licensing issues by using Apache and mod_auth_ldap.
> Unfortunately, that seems to require SASL.

> -- John

Try something like this before configure:
export CPPFLAGS="-I/usr/local/include/ -I/usr/local/ssl/include/openssl/"
export LDFLAGS="-L/usr/local/lib/ -L/usr/local/ssl/lib/"

This worked for me, with des.h in /usr/local/ssl/include/openssl/

--
Best regards,
Jeroen Besse
(to contact me: the nospam address actually exists)

 
 
 

Cyrus SASL will not compile on Solaris 8

Post by Neal A. Lucie » Wed, 21 Sep 2005 09:10:34



> I am attempting to compile Cyrus SASL v2.1.21 so that I can (try to) get
> Apache LDAP to cooperate with Sun Java System Directory Server on a
> Solaris 8 (SPARC) system.  I'm using GCC v3.4.2 and GNU Make v3.80

> I'm running the following for the configure:
>     CFLAGS="-mcpu=v9" ./configure

> Unfortunately, when I run "make" I get a flood of what look like syntax
> errors compiling the digestmd5 code...

> digestmd5.c:971: error: dereferencing pointer to incomplete type
> digestmd5.c:972: error: `DES_DECRYPT' undeclared (first use in this
> function)
> digestmd5.c:976: error: dereferencing pointer to incomplete type
> digestmd5.c: In function `enc_des':
> digestmd5.c:1021: error: dereferencing pointer to incomplete type
> digestmd5.c:1022: error: dereferencing pointer to incomplete type
> digestmd5.c:1023: error: `DES_ENCRYPT' undeclared (first use in this
> function)
> digestmd5.c:1027: error: dereferencing pointer to incomplete type
> digestmd5.c: In function `init_des':
> digestmd5.c:1042: error: invalid application of `sizeof' to incomplete
> type `digestmd5.c'
> digestmd5.c:1047: error: `des_cblock' undeclared (first use in this
> function)
> digestmd5.c:1047: error: parse error before ')' token
> digestmd5.c:1049: error: dereferencing pointer to incomplete type
> digestmd5.c:1054: error: increment of pointer to unknown structure
> digestmd5.c:1054: error: arithmetic on pointer to an incomplete type
> digestmd5.c:1056: error: parse error before ')' token
> digestmd5.c:1058: error: dereferencing pointer to incomplete type
> make[2]: *** [digestmd5.lo] Error 1
> make[2]: Leaving directory `/tmp/cyrus-sasl-2.1.21/plugins'
> make[1]: *** [all-recursive] Error 1
> make[1]: Leaving directory `/tmp/cyrus-sasl-2.1.21'
> make: *** [all] Error 2

> Do anyone know how to correct this problem?  Did I miss a configuration
> option somewhere?

I had similar problems on Solaris 9 SPARC.  This is an excerpt of what I
posted awhile ago on making openldap with ssl and sasl.  You can see the
full thread at:
http://www.veryComputer.com/

You do need to know that my openssl is installed with a prefix of
'/local'.  Depending on how SunFreeWare lays out its openssl build you
made need slightly different CFLAGS, CPPFLAGS, and LDFLAGS.

Quoting Myself:

- Show quoted text -

Quote:> cyrus-sasl-2.1.21 installed with prefix /homes/nlucier/sasl
> ran into 2 problems compiling sasl:
> 1. needed to set CFLAGS, CPPFALGS, LDFLAGS to locate ssl even though
> configure didn't complain that it couldn't find ssl (it didn't break
> until trying to compile plugins/digestmd5.c, gcc complains about parse
> errors on line 812)
> 2. changed saslauthd/auth_getpwent.c to move the include for crypt.h
> ahead of the include for ssl.h
> bessel saslauthd % diff auth_getpwent.c
> ../../orig/cyrus-sasl-2.1.21/saslauthd/auth_getpwent.c
> 44,47d43
> < #ifdef HAVE_CRYPT_H
> < #include <crypt.h>
> < #endif
> <
> 55a52,54
>  > #ifdef HAVE_CRYPT_H
>  > #include <crypt.h>
>  > #endif

> The resultant script to build cyrus-sasl:
>         #!/bin/tcsh
>         setenv CFLAGS "-I/local/include"
>         setenv CPPFLAGS "-I/local/include"
>         setenv LDFLAGS "-L/local/lib -R/local/lib"
>         ./configure     --prefix=/homes/nlucier/sasl

HTH,
Neal

p.s. the Apache 1.x ldap module is *

 
 
 

1. solaris 9 / cyrus imap sasl compile problems

Greetings,

I am wondering if anyone has been able to successfully get cyrus imap
running under solaris 9. I'm having a whole lot of trouble getting
this to compile.. each step closer I get, it fails on something new. I
have the latest cyrus imap, sasl, openssl and berkeleydb installed. I
want to use cyrus sasl for authentication. Cyrus sasl did compile and
install, but I'm not convinced I did a successful job of it.

I apologize for not posting specific errors. This is driving me crazy
and I need to get some fresh air. I'm hoping that if someone HAS has
success with this, they will please email me directly and hopefully
lend a helping hand.

Thanks for your time and any support!

Reece

2. MediaVision Pro Audio 16 and boot/install Linux SNOW 2.2

3. Compiling Cyrus SASL 1.5.27 on Solaris 8

4. Linux distributions on QIC tape

5. Cyrus SASL Compile Error

6. HELP! mail, news & browsing quit working!

7. Compiling cyrus-sasl

8. LAG to make connections - why?

9. Cyrus-SASL compile problem

10. Problems with Heimdal, OpenLDAP, Cyrus SASL, GSSAPI, and Active Directory

11. cyrus-sasl installation help

12. cyrus-sasl and ld

13. LDAP over SSL using OpenLDAP/OpenSSL/Cyrus SASL with Netscape's LDAP server