Обсуждение: Talking about Solaris 7

Поиск
Список
Период
Сортировка

Talking about Solaris 7

От
"Martin A. Marques"
Дата:
I have a problem with the compilation of Postgres on Solaris with ssl 
support. The error I get is this when executing make:

gcc -g -Wall -Wmissing-prototypes -Wmissing-declarations -I/usr/local/include 
-I/usr/local/ssl//include -I../../../src/include  -c nodeTidscan.c -o 
nodeTidscan.ogcc -g -Wall -Wmissing-prototypes -Wmissing-declarations 
-I/usr/local/include -I/usr/local/ssl//include -I../../../src/include  -c 
spi.c -o spi.o
/usr/ccs/bin/ld -r -o SUBSYS.o execAmi.o execFlatten.o execJunk.o execMain.o 
execProcnode.o execQual.o execScan.o execTuples.o execUtils.o functions.o 
nodeAppend.o nodeAgg.o nodeHash.o nodeHashjoin.o nodeIndexscan.o 
nodeMaterial.o nodeMergejoin.o nodeNestloop.o nodeResult.o nodeSeqscan.o 
nodeSetOp.o nodeSort.o nodeUnique.o nodeLimit.o nodeGroup.o nodeSubplan.o 
nodeSubqueryscan.o nodeTidscan.o spi.o
make[3]: Leaving directory 
`/space/pruebas/postgresql-7.1beta1/src/backend/executor'
/usr/local/bin/make -C lib all
make[3]: Entering directory 
`/space/pruebas/postgresql-7.1beta1/src/backend/lib'
gcc -g -Wall -Wmissing-prototypes -Wmissing-declarations -I/usr/local/include 
-I/usr/local/ssl//include -I../../../src/include  -c bit.c -o bit.o
gcc -g -Wall -Wmissing-prototypes -Wmissing-declarations -I/usr/local/include 
-I/usr/local/ssl//include -I../../../src/include  -c hasht.c -o hasht.o
gcc -g -Wall -Wmissing-prototypes -Wmissing-declarations -I/usr/local/include 
-I/usr/local/ssl//include -I../../../src/include  -c lispsort.c -o lispsort.o
gcc -g -Wall -Wmissing-prototypes -Wmissing-declarations -I/usr/local/include 
-I/usr/local/ssl//include -I../../../src/include  -c stringinfo.c -o 
stringinfo.o
gcc -g -Wall -Wmissing-prototypes -Wmissing-declarations -I/usr/local/include 
-I/usr/local/ssl//include -I../../../src/include  -c dllist.c -o dllist.o
/usr/ccs/bin/ld -r -o SUBSYS.o bit.o hasht.o lispsort.o stringinfo.o dllist.o
make[3]: Leaving directory 
`/space/pruebas/postgresql-7.1beta1/src/backend/lib'
/usr/local/bin/make -C libpq all
make[3]: Entering directory 
`/space/pruebas/postgresql-7.1beta1/src/backend/libpq'
gcc -g -Wall -Wmissing-prototypes -Wmissing-declarations -I/usr/local/include 
-I/usr/local/ssl//include -I../../../src/include  -c be-fsstubs.c -o 
be-fsstubs.o
gcc -g -Wall -Wmissing-prototypes -Wmissing-declarations -I/usr/local/include 
-I/usr/local/ssl//include -I../../../src/include  -c auth.c -o auth.o
gcc -g -Wall -Wmissing-prototypes -Wmissing-declarations -I/usr/local/include 
-I/usr/local/ssl//include -I../../../src/include  -c crypt.c -o crypt.o
In file included from crypt.c:27:
/usr/include/crypt.h:23: conflicting types for `des_encrypt'
/usr/local/ssl/include/openssl/des.h:150: previous declaration of 
`des_encrypt'
make[3]: *** [crypt.o] Error 1
make[3]: Leaving directory 
`/space/pruebas/postgresql-7.1beta1/src/backend/libpq'
make[2]: *** [libpq-recursive] Error 2
make[2]: Leaving directory `/space/pruebas/postgresql-7.1beta1/src/backend'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/space/pruebas/postgresql-7.1beta1/src'
make: *** [all] Error 2
*** Error code 2
make: Fatal error: Command failed for target `all'


Any extra code you may want, just ask.

-- 
System Administration: It's a dirty job, 
but someone told I had to do it.
-----------------------------------------------------------------
Martín Marqués            email:     martin@math.unl.edu.ar
Santa Fe - Argentina        http://math.unl.edu.ar/~martin/
Administrador de sistemas en math.unl.edu.ar
-----------------------------------------------------------------


Re: Talking about Solaris 7

От
Alexander Klimov
Дата:
Hi.

I had the same problem and sent bug report to openssl-users@openssl.org
some time ago (20 Sep 2000), so, hopefully, they will fix it eventualy.

There is a workaround for it. The comment in ssl/include/openssl/des.h
said: `You should not use this function except to implement 'modes' of
DES.', so you can just comment out declaration of des_encrypt (line 150)
without any problem.

On Thu, 25 Jan 2001, Martin A. Marques wrote:

> I have a problem with the compilation of Postgres on Solaris with ssl 
> support. The error I get is this when executing make:
...
> In file included from crypt.c:27:
> /usr/include/crypt.h:23: conflicting types for `des_encrypt'
> /usr/local/ssl/include/openssl/des.h:150: previous declaration of 
> `des_encrypt'


Regards,
ASK



Re: Talking about Solaris 7

От
"Martin A. Marques"
Дата:
El Lun 29 Ene 2001 07:57, Alexander Klimov escribió:
> Hi.
>
> I had the same problem and sent bug report to openssl-users@openssl.org
> some time ago (20 Sep 2000), so, hopefully, they will fix it eventualy.
>
> There is a workaround for it. The comment in ssl/include/openssl/des.h
> said: `You should not use this function except to implement 'modes' of
> DES.', so you can just comment out declaration of des_encrypt (line 150)
> without any problem.

Now, why are the definitions so different?

/usr/include/crypt.h:23 (I guess this is Solaris crypt header)

extern void des_encrypt(char *, int);

and /usr/local/ssl/include/openssl/des.h:150 (this is from openssl)

void des_encrypt(DES_LONG *data,des_key_schedule ks, int enc);

I may be wrong, but why are the two functions decrared with different 
arguments?


-- 
System Administration: It's a dirty job, 
but someone told I had to do it.
-----------------------------------------------------------------
Martín Marqués            email:     martin@math.unl.edu.ar
Santa Fe - Argentina        http://math.unl.edu.ar/~martin/
Administrador de sistemas en math.unl.edu.ar
-----------------------------------------------------------------


Re: Talking about Solaris 7

От
Alexander Klimov
Дата:
On Mon, 29 Jan 2001, Martin A. Marques wrote:

> El Lun 29 Ene 2001 07:57, Alexander Klimov escribiС:
> > Hi.
> >
> > I had the same problem and sent bug report to openssl-users@openssl.org
> > some time ago (20 Sep 2000), so, hopefully, they will fix it eventualy.
> >
> > There is a workaround for it. The comment in ssl/include/openssl/des.h
> > said: `You should not use this function except to implement 'modes' of
> > DES.', so you can just comment out declaration of des_encrypt (line 150)
> > without any problem.
> 
> Now, why are the definitions so different?
> 
> /usr/include/crypt.h:23 (I guess this is Solaris crypt header)
> 
> extern void des_encrypt(char *, int);
> 
> and /usr/local/ssl/include/openssl/des.h:150 (this is from openssl)
> 
> void des_encrypt(DES_LONG *data,des_key_schedule ks, int enc);
> 
> I may be wrong, but why are the two functions decrared with different 
> arguments?

It is just two different functions: one from ssl and one from solaris. You
are not going to use either of them (postgress could not use solarise's
version because it propriate to solaris, and could not use ssl's because
it is internal to ssl). The situation just semi-bug of ssl & solaris they
have name clash.

Regards,
ASK