large compiling error when compiling PGP on Linux...

large compiling error when compiling PGP on Linux...

Post by David Wadde » Fri, 05 Apr 1996 04:00:00



Sorry, but I'm a newbie to PGP, but anyways...
I have Linux Slackware 3.0 with GCC 2.7.2,the newest libc, the newest
ld.so, and kernel 1.3.83, when i go to compile... I can compile the
RSAREF fine, bt when I go to compile the pgp, I get the following errors
after a few minutes of compiling...

foo:/usr/src/pgp/crap/src# make linux
make all CC=gcc LD=gcc OBJS_EXT="_80386.o _zmatch.o" \
CFLAGS="-I../rsaref/source -I../rsaref/test -DUSEMPILIB -O6 -g3 -DUNIX
-DIDEA32 -DASM"
make[1]: Entering directory `/usr/src/pgp/crap/src'
gcc -o pgp pgp.o crypto.o keymgmt.o fileio.o mdfile.o more.o armor.o
mpilib.o mpiio.o genprime.o rsagen.o random.o idea.o passwd.o md5.o
system.o language.o getopt.o keyadd.o config.o keymaint.o charset.o
randpool.o noise.o zbits.o zdeflate.o zfile_io.o zglobals.o zinflate.o
zip.o zipup.o ztrees.o zunzip.o  rsaglue2.o _80386.o _zmatch.o
../rsaref/install/unix/rsaref.a
crypto.o: In function `read_mpi':
/usr/src/pgp/crap/src/crypto.c:627: undefined reference to `P_SETP'
crypto.o: In function `signfile':
/usr/src/pgp/crap/src/crypto.c:864: undefined reference to `P_SETP'
crypto.o: In function `compromise':
/usr/src/pgp/crap/src/crypto.c:1044: undefined reference to `P_SETP'
/usr/src/pgp/crap/src/crypto.c:1052: undefined reference to `P_SETP'
crypto.o: In function `signkey':
/usr/src/pgp/crap/src/crypto.c:1202: undefined reference to `P_SETP'
crypto.o:/usr/src/pgp/crap/src/crypto.c:1351: more undefined references
to `P_SETP' follow
mpilib.o: In function `mp_udiv':
/usr/src/pgp/crap/src/mpilib.c:392: undefined reference to `P_ROTL'
/usr/src/pgp/crap/src/mpilib.c:395: undefined reference to `P_SUBB'
mpilib.o: In function `mp_recip':
/usr/src/pgp/crap/src/mpilib.c:429: undefined reference to `P_ROTL'
/usr/src/pgp/crap/src/mpilib.c:431: undefined reference to `P_SUBB'
mpilib.o: In function `mp_mod':
/usr/src/pgp/crap/src/mpilib.c:517: undefined reference to `P_ROTL'
/usr/src/pgp/crap/src/mpilib.c:519: undefined reference to `P_SUBB'
mpilib.o: In function `mp_mult':
/usr/src/pgp/crap/src/mpilib.c:662: undefined reference to `P_ROTL'
/usr/src/pgp/crap/src/mpilib.c:664: undefined reference to `P_ADDC'
mpilib.o: In function `mp_dmul':
/usr/src/pgp/crap/src/mpilib.c:1230: undefined reference to `P_SMULA'
mpilib.o: In function `stage_smith_modulus':
/usr/src/pgp/crap/src/mpilib.c:1588: undefined reference to `P_SETP'
/usr/src/pgp/crap/src/mpilib.c:1616: undefined reference to `p_setrecip'
/usr/src/pgp/crap/src/mpilib.c:1617: undefined reference to `P_SETP'
mpilib.o: In function `smith_modmult':
/usr/src/pgp/crap/src/mpilib.c:1230: undefined reference to `P_SMULA'
/usr/src/pgp/crap/src/mpilib.c:1646: undefined reference to `P_SETP'
/usr/src/pgp/crap/src/mpilib.c:1666: undefined reference to `P_SETP'
/usr/src/pgp/crap/src/mpilib.c:1687: undefined reference to
`p_quo_digit'
/usr/src/pgp/crap/src/mpilib.c:1689: undefined reference to `P_SMULA'
/usr/src/pgp/crap/src/mpilib.c:1698: undefined reference to `P_SUBB'
/usr/src/pgp/crap/src/mpilib.c:1708: undefined reference to `P_SETP'
/usr/src/pgp/crap/src/mpilib.c:1714: undefined reference to `P_SETP'
mpilib.o: In function `smith_burn':
/usr/src/pgp/crap/src/mpilib.c:1736: undefined reference to `p_setrecip'
mpilib.o: In function `mp_modexp':
/usr/src/pgp/crap/src/mpilib.c:1798: undefined reference to `P_SETP'
/usr/src/pgp/crap/src/mpilib.c:1806: undefined reference to `P_SETP'
/usr/src/pgp/crap/src/mpilib.c:1736: undefined reference to `p_setrecip'
/usr/src/pgp/crap/src/mpilib.c:1855: undefined reference to `P_SETP'
mpilib.o: In function `mp_modexp_crt':
/usr/src/pgp/crap/src/mpilib.c:1947: undefined reference to `P_SUBB'
/usr/src/pgp/crap/src/mpilib.c:1948: undefined reference to `P_ADDC'
/usr/src/pgp/crap/src/mpilib.c:1954: undefined reference to `P_ADDC'
genprime.o: In function `nextprime':
/usr/src/pgp/crap/src/genprime.c:529: undefined reference to `P_SETP'
/usr/src/pgp/crap/src/genprime.c:593: undefined reference to `P_SETP'
genprime.o: In function `mp_inv':
/usr/src/pgp/crap/src/genprime.c:801: undefined reference to `P_SUBB'
/usr/src/pgp/crap/src/genprime.c:808: undefined reference to `P_ADDC'
rsagen.o: In function `rsa_keygen':
/usr/src/pgp/crap/src/rsagen.c:165: undefined reference to `P_SETP'
/usr/src/pgp/crap/src/rsagen.c:223: undefined reference to `P_SUBB'
keymaint.o: In function `show_key':
/usr/src/pgp/crap/src/keymaint.c:1286: undefined reference to `P_SETP'
zdeflate.o: In function `lm_init':
/usr/src/pgp/crap/src/zdeflate.c:287: undefined reference to
`match_init'
zdeflate.o: In function `deflate':
/usr/src/pgp/crap/src/zdeflate.c:636: undefined reference to
`longest_match'
rsaglue2.o: In function `NN_ModExp':
/usr/src/pgp/crap/src/rsaglue2.c:485: undefined reference to `P_SETP'
/usr/src/pgp/crap/src/rsaglue2.c:494: undefined reference to `P_SETP'
_zmatch.o(.text+0xb): undefined reference to `_max_chain_length'
_zmatch.o(.text+0x11): undefined reference to `_strstart'
_zmatch.o(.text+0x23): undefined reference to `_window'
_zmatch.o(.text+0x29): undefined reference to `_prev_length'
_zmatch.o(.text+0x38): undefined reference to `_good_match'
_zmatch.o(.text+0x5a): undefined reference to `_prev'
_zmatch.o(.text+0x66): undefined reference to `_window'
_zmatch.o(.text+0x6f): undefined reference to `_window'
_zmatch.o(.text+0x77): undefined reference to `_window'
_zmatch.o(.text+0x94): undefined reference to `_window'
_zmatch.o(.text+0xa4): undefined reference to `_match_start'
make[1]: *** [pgp] Error 1
make[1]: Leaving directory `/usr/src/pgp/crap/src'
make: *** [linux] Error 2

Thank you for any help.

 
 
 

large compiling error when compiling PGP on Linux...

Post by zin » Sun, 07 Apr 1996 04:00:00


David,

your problem is that PGP was not setup to be compiled as ELF under
linux.  here's a simple way to get it to compile as ELF.

(from my crypto web page)


    There is a better way.  I got similiar link error and someone
    suggested adding the line "ASMDEF=-DSYSV" to the linux section of the
    Makefile.  This causes the assembler to write function names in the
    way that ELF expects (ELF removes the underscore from function names).
    For me at least, the everything compiled and linked smoothly after
    that.  The advantage of this fix is that you get the i386 assembler
    routines instead of the portable C ones.<P>

     - Ian<p>

-pjf

--
"Those that give up essential liberty to obtain a little temporary
 safety deserve neither liberty nor safety." -- Benjamin Franklin (1773)
                          finger for PGP key
zifi runs LINUX 1.3.81 -=-=-=WEB=-=-=->  http://zifi.genetics.utah.edu

 
 
 

large compiling error when compiling PGP on Linux...

Post by Travis Por » Tue, 09 Apr 1996 04:00:00


Dear Readers,

I got a similar error when trying to compile Gnu Common Lisp 2.1 from the
Carnegie Mellon AI repository.  I have Red Hat 2.1, gcc 2.7.2, libc.so.5.0.9,
and ld.so.1.7.14.  

After compiling the separate files, it gets to this point, which appears to be
the final linking step.  This is one long gcc command, followed by
some error messages; I broke up the gcc command onto several lines for clarity:

[/usr/local/gcl-2.1/unixport] # make
gcc -pipe -fwritable-strings  -DVOL=volatile -I/usr/local/gcl-2.1/o -fsigned-char -static  
 -o raw_gcl ../o/main.o ../o/alloc.o ../o/gbc.o ../o/bitop.o ../o/typespec.o
../o/eval.o ../o/macros.o ../o/lex.o ../o/bds.o ../o/frame.o ../o/predicate.o
../o/reference.o ../o/assignment.o ../o/bind.o ../o/let.o ../o/conditional.o
../o/block.o ../o/iteration.o ../o/mapfun.o ../o/prog.o ../o/multival.o
../o/catch.o ../o/symbol.o ../o/cfun.o ../o/cmpaux.o ../o/package.o ../o/big.o
../o/number.o ../o/num_pred.o ../o/num_comp.o ../o/num_arith.o ../o/num_sfun.o
../o/num_co.o ../o/num_log.o ../o/num_rand.o ../o/earith.o ../o/character.o  
../o/sequence.o ../o/list.o ../o/hash.o ../o/array.o ../o/string.o
../o/regexpr.o ../o/structure.o ../o/toplevel.o ../o/file.o ../o/read.o
../o/backq.o ../o/print.o ../o/format.o ../o/pathname.o ../o/unixfsys.o
../o/unixfasl.o ../o/error.o ../o/unixtime.o ../o/unixsys.o ../o/unixsave.o
../o/funlink.o ../o/fat_string.o ../o/run_process.o ../o/nfunlink.o
../o/usig.o ../o/usig2.o ../o/utils.o ../o/makefun.o ../o/sockets.o
../o/init_pari.o ../o/new_init.o ../mp/mpi-386d.o  
 ../mp/libmport.a
../o/sfasl.o  ../lsp/defmacro.o ../lsp/evalmacros.o ../lsp/top.o .lsp/module.o
../lsp/predlib.o ../lsp/setf.o ../lsp/arraylib.o ../lsp/asse.o
../lsp/defstruct.o ../lsp/describe.o ../lsp/iolib.o ../lsp/listlib.o
.lsp/mislib.o ../lsp/numlib.o ../lsp/packlib.o ../lsp/seq.o
../lsp/seqlib.../lsp/trace.o ../lsp/sloop.o  ../lsp/debug.o ../lsp/info.o
../cmpnew/cmpline.o ../cmpnew/cmputil.o ../cmpnew/cmptype.o
../cmpnew/cmpbind.o ../cmpw/cmpblock.o ../cmpnew/cmpcall.o
../cmpnew/cmpcatch.o ../cmpnew/cmpenv.o /cmpnew/cmpeval.o ../cmpnew/cmpflet.o
../cmpnew/cmpfun.o ../cmpnew/cmpif.../cmpnew/cmplabel.o
../cmpnew/cmplam.o ../cmpnew/cmplet.o ../cmpnew/cmpl.o
 ../cmpnew/cmpmap.o ../cmpnew/cmpmulti.o
 ../cmpnew/cmpspecial.o /cmpnew/cmptag.o ../cmpnew/cmptop.o
../cmpnew/cmpvar.o ../cmpnew/cmpvs.o /cmpnew/cmpwt.o  sys_gcl.o  -lm  
 ../o/gcllib.a

../o/big.o(.text+0x31b): undefined reference to `addsi'
...<I delete several hundred lines of similar undefined reference errors>
mp2.o(.text+0x18e7): undefined reference to `addii'
mp2.o(.text+0x1932): undefined reference to `dvmdii'
mp2.o(.text+0x19c5): undefined reference to `dvmdii'
make: *** [raw_gcl] Error 1

The routines addsi and so on appear to be located in ../mp/libmport.a
which was included in the gcc statement above.  But the linker does not seem
to find them.  

1.  Any idea what to do?
2.  What manual contains this information, so that next time something like
this happens, I'll know where to look?

Many thanks!!

--Travis



>Subject: large compiling error when compiling PGP on Linux...
>Date: Thu, 04 Apr 1996 17:36:18 -0500
>Sorry, but I'm a newbie to PGP, but anyways...
>I have Linux Slackware 3.0 with GCC 2.7.2,the newest libc, the newest
>ld.so, and kernel 1.3.83, when i go to compile... I can compile the
>RSAREF fine, bt when I go to compile the pgp, I get the following errors
>after a few minutes of compiling...
>foo:/usr/src/pgp/crap/src# make linux
>make all CC=gcc LD=gcc OBJS_EXT="_80386.o _zmatch.o" \
>CFLAGS="-I../rsaref/source -I../rsaref/test -DUSEMPILIB -O6 -g3 -DUNIX
>-DIDEA32 -DASM"
>make[1]: Entering directory `/usr/src/pgp/crap/src'
>gcc -o pgp pgp.o crypto.o keymgmt.o fileio.o mdfile.o more.o armor.o
>mpilib.o mpiio.o genprime.o rsagen.o random.o idea.o passwd.o md5.o
>system.o language.o getopt.o keyadd.o config.o keymaint.o charset.o
>randpool.o noise.o zbits.o zdeflate.o zfile_io.o zglobals.o zinflate.o
>zip.o zipup.o ztrees.o zunzip.o  rsaglue2.o _80386.o _zmatch.o
>../rsaref/install/unix/rsaref.a
>crypto.o: In function `read_mpi':
>/usr/src/pgp/crap/src/crypto.c:627: undefined reference to `P_SETP'

 
 
 

large compiling error when compiling PGP on Linux...

Post by Dave Kinchl » Tue, 09 Apr 1996 04:00:00


I just compiled pgp2.6.2 under linux (1.2.13, gcc 2.7.2) via the
                make linux
target, and had the same problem (undefined P_SETP), what I found was
that there was a missing ASMDEF= statement in the Makefile (maybe it
wasn't necessary before?), anyway, here is a diff:
*** Makefile    Sun Apr  7 22:09:30 1996
--- makefile.orig       Thu Oct 13 17:33:34 1994
***************
*** 159,167 ****

  linux:
        $(MAKE) all CC=gcc LD=gcc OBJS_EXT="_80386.o _zmatch.o" \
!       CFLAGS="$(RSAINCDIR) -m486 -ansi -static -O6 -g3 -DUNIX \
!               -DIDEA32 -DASM -DSYSV" ASMDEF=" -m486 -O6 \
!               -g3 -DUNIX -DIDEA32 -DASM -DSYSV"

  386bsd:
        $(MAKE) all CC=gcc LD=gcc OBJS_EXT="_80386.o _zmatch.o" \
--- 159,165 ----

  linux:
        $(MAKE) all CC=gcc LD=gcc OBJS_EXT="_80386.o _zmatch.o" \
!       CFLAGS="$(RSAINCDIR) -O6 -g3 -DUNIX -DIDEA32 -DASM"

  386bsd:
        $(MAKE) all CC=gcc LD=gcc OBJS_EXT="_80386.o _zmatch.o" \

I didn't bother to check whether most of these options are useful for
assembly, but the -DASM, -DSYSV and -Di386 are necessary (at least
they were for me). The -DASM is used in platform.h to determine that
assembly code is being used, the -DSYSV is needed so that the correct
entry points are created (necessary because of elf, I think)

Seemed to work for me, so far anyway ;-(

Hope this helps.
--


Unix PGP Key fingerprint =  6F 36 6F 9D 79 16 DF 40  2B EC 18 5B 5C 6D 03 6F
Home PGP Key fingerprint =  28 20 0E DF 27 17 80 C5  5D 04 8E 1B D0 9A A6 4C


|> >Subject: large compiling error when compiling PGP on Linux...
|> >Date: Thu, 04 Apr 1996 17:36:18 -0500
|>
|> >Sorry, but I'm a newbie to PGP, but anyways...
|> >I have Linux Slackware 3.0 with GCC 2.7.2,the newest libc, the newest
|> >ld.so, and kernel 1.3.83, when i go to compile... I can compile the
|> >RSAREF fine, bt when I go to compile the pgp, I get the following errors
|> >after a few minutes of compiling...
|>
|> >foo:/usr/src/pgp/crap/src# make linux
|> >make all CC=gcc LD=gcc OBJS_EXT="_80386.o _zmatch.o" \
|> >CFLAGS="-I../rsaref/source -I../rsaref/test -DUSEMPILIB -O6 -g3 -DUNIX
|> >-DIDEA32 -DASM"
|> >make[1]: Entering directory `/usr/src/pgp/crap/src'
|> >gcc -o pgp pgp.o crypto.o keymgmt.o fileio.o mdfile.o more.o armor.o
|> >mpilib.o mpiio.o genprime.o rsagen.o random.o idea.o passwd.o md5.o
|> >system.o language.o getopt.o keyadd.o config.o keymaint.o charset.o
|> >randpool.o noise.o zbits.o zdeflate.o zfile_io.o zglobals.o zinflate.o
|> >zip.o zipup.o ztrees.o zunzip.o  rsaglue2.o _80386.o _zmatch.o
|> >../rsaref/install/unix/rsaref.a
|> >crypto.o: In function `read_mpi':
|> >/usr/src/pgp/crap/src/crypto.c:627: undefined reference to `P_SETP'
|>
|>

 
 
 

1. PGP-6.5.8 compile errors [Linux]

I'm trying to compile PGP-6.5.8 on a custom Linux system. The build fails
almost immediately with the following error reported.

make[2]: Entering directory `/usr/src/pgpsrc/libs/pfl/common/file'
gcc -O2 -DPGP_UNIX=1 -DPGP_COMPILER_GCC=1   -DHAVE_CONFIG_H -DPGP_DEBUG=0 \
-DUNFINISHED_CODE_ALLOWED=1 -DUSE_PGP_LEAKS=0  -I../.././unix \
-I../.././common -I../.././common/file -I../.././common/prefs \
-I../.././common/util -I../.././common/lthread -I.     -c -o \
pgpStdFileIO.o pgpStdFileIO.c
pgpStdFileIO.c: In function `sStdFileSetPosProc':
pgpStdFileIO.c:127: incompatible types in assignment
pgpStdFileIO.c: In function `sStdFileIOGetEOFProc':
pgpStdFileIO.c:224: incompatible types in assignment
make[2]: *** [pgpStdFileIO.o] Error 1
make[2]: Leaving directory `/usr/src/pgpsrc/libs/pfl/common/file'
make[1]: *** [all] Error 1
make[1]: Leaving directory `/usr/src/pgpsrc/libs/pfl/common'
make: *** [all] Error 1

There's obviously something that needs to be installed, but I can't think
what. On a Debian 2.2 box there's no such problem and comparing the two
'config.cache' files reveals no differences.

ver_linux yields the following about this system:
 Gnu C                  2.95.3
 Gnu make               3.79.1
 binutils               2.11.2
 util-linux             2.11m
 mount                  2.11m
 modutils               2.4.12
 e2fsprogs              1.25
 reiserfsprogs          3.x.0j
 PPP                    2.4.1
 Linux C Library        2.2.4
 Dynamic linker (ldd)   2.2.4
 Procps                 2.0.7
 Net-tools              1.60
 Kbd                    1.06
 Sh-utils               2.0

Can anyone shed any light on this?. What's the missing link?.

tia

--
Speed.

2. Need help with find for whereis files

3. compiling pgp error

4. problems with CDROM in linux

5. pgp-2.3 compiling errors

6. Q: Linux, sendmsg() & file descriptors

7. UGLY make errors when compiling PGP

8. PRCS 1.1 released

9. Problem compiling pgp on Linux

10. Solution: Compiling PGP in Linux

11. Compiling PGP on LINUX

12. Can't compile PGP on Linux

13. Has anyone compiled PGP-enabled elm for Linux?