* PGP and DUnix
@ 1998-12-10 5:00 Seppo.Routimo
1998-12-24 5:00 ` Nikola Milutinovic
0 siblings, 1 reply; 3+ messages in thread
From: Seppo.Routimo @ 1998-12-10 5:00 UTC (permalink / raw)
Hi
Has anyone compiled PGP 5.0i on DUnix 4.0D?
I seem to have problems with the source, there
are few rows which end ;) and I think they should end );
If I change them, compile finds new errors and exits...
Seppo
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: PGP and DUnix
1998-12-10 5:00 PGP and DUnix Seppo.Routimo
@ 1998-12-24 5:00 ` Nikola Milutinovic
1998-12-25 5:00 ` Thomas Leitner
0 siblings, 1 reply; 3+ messages in thread
From: Nikola Milutinovic @ 1998-12-24 5:00 UTC (permalink / raw)
To: Seppo.Routimo
"Seppo.Routimo" wrote:
>
> Hi
>
> Has anyone compiled PGP 5.0i on DUnix 4.0D?
> I seem to have problems with the source, there
> are few rows which end ;) and I think they should end );
>
> If I change them, compile finds new errors and exits...
I'm trying as well, so if anyone has done it, let us know, please.
The problem is in "src/lib/bn/bnimem.c", more specifically in line like:
BIG(ptr = (char *)ptr - oldbytes;)
BIG is a macro:
#if !defined(BN_BIG_ENDIAN) && !defined(BN_LITTLE_ENDIAN)
#define BN_LITTLE_ENDIAN 1
#endif /* !BN_BIG_ENDIAN && !BN_LITTLE_ENDIAN */
#if BN_BIG_ENDIAN
#define BIG(b) b
#define LITTLE(l) /*nothing*/
#define BIGLITTLE(b,l) b
#elif BN_LITTLE_ENDIAN
#define BIG(b) /*nothing*/
#define LITTLE(l) l
#define BIGLITTLE(b,l) l
#else
#error One of BN_BIG_ENDIAN or BN_LITTLE_ENDIAN must be defined as 1
#endif
Basically, it should default to BN_LITTLE_ENDIAN, thus:
#define BIG(b) /*nothing*/
#define LITTLE(l) l
#define BIGLITTLE(b,l) l
The problem is in the macro, the way I see it. It doesn't get recognized
by the CPP. I've run "cc -P bnimem.c and in the resulting file I can see
that BIG is not substituted, it remains after Pre-Processor and is
treated as a function call. That is why we get a syntax error on "...
;)", If you reverse it, then you'll have linker errors, since there is
no function called "BIG".
As far as I can see, all header files are included OK, there is no
BN_*_ENDIAN definition, though. So, it should default to LITTLE and all
should go well.
The problem could be in that "no define for either *_ENDIAN". Maybe,
since BN_BIG_ENDIAN is not defined at all, the whole "#if ..."
construction fails. What is the exact CC/CPP specification on this? I'll
try making it "politically correct", by adding a line:
#if !defined(BN_BIG_ENDIAN) && !defined(BN_LITTLE_ENDIAN)
#define BN_LITTLE_ENDIAN 1
#define BN_BIG_ENDIAN 0
#endif /* !BN_BIG_ENDIAN && !BN_LITTLE_ENDIAN */
Nix.
--
Le ave tha t spa ce alo ne!
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: PGP and DUnix
1998-12-24 5:00 ` Nikola Milutinovic
@ 1998-12-25 5:00 ` Thomas Leitner
0 siblings, 0 replies; 3+ messages in thread
From: Thomas Leitner @ 1998-12-25 5:00 UTC (permalink / raw)
Nikola Milutinovic <Nikola.Milutinovic@ev.co.yu> wrote:
> "Seppo.Routimo" wrote:
>>
>>
>> Has anyone compiled PGP 5.0i on DUnix 4.0D?
Yes, me. I took this source:
-rw------- 1 tom users 927363 Feb 9 1998 pgp50i-unix-src.tar.gz
$ cksum pgp50i-unix-src.tar.gz
2410245757 927363 pgp50i-unix-src.tar.gz
And applied the following patches (it is possible that you need to
apply them per hand because they were for another PGP version --
I can't remember):
$ cat alpha.diff
*** src/lib/pgp/include/pgpUsuals.h~ Sat Aug 9 22:44:58 1997
--- src/lib/pgp/include/pgpUsuals.h Tue Aug 12 16:57:16 1997
***************
*** 50,57 ****
*/
#if ULONG_MAX > 0xfffffffful
#if ULONG_MAX == 0xfffffffffffffffful
! typedef ulong bnword64;
! #define BNWORD64 bnword64
#define HAVE64 1
#endif
#endif
--- 50,56 ----
*/
#if ULONG_MAX > 0xfffffffful
#if ULONG_MAX == 0xfffffffffffffffful
! typedef ulong word64;
#define HAVE64 1
#endif
#endif
$ cat makefile.diff
diff -r -c pgp50i-b8/src/apps/pgp/Makefile.in
old/pgp50i-b8/src/apps/pgp/Makefile.in
*** pgp50i-b8/src/apps/pgp/Makefile.in Mon Aug 11 15:41:37 1997
- --- old/pgp50i-b8/src/apps/pgp/Makefile.in Sat Aug 9 23:45:38 1997
***************
*** 7,15 ****
#
PROG = pgp
! # Set this to "pgp5" if you want the keep old and new versions in parallel
! INSTPGP = pgp
! INSTALLPROGS =
COMMON=../common
LOCALINCLUDES = -I$(COMMON) -I$(srcdir)/$(COMMON)
- --- 7,13 ----
#
PROG = pgp
! INSTALLPROGS = $(PROG)
COMMON=../common
LOCALINCLUDES = -I$(COMMON) -I$(srcdir)/$(COMMON)
***************
*** 22,32 ****
install:: $(PROG)
( \
! $(INSTALL) -m 755 pgp $(DESTDIR)$(bindir)/$(INSTPGP); \
cd $(DESTDIR)$(bindir); \
$(RM) pgpe pgps pgpv pgp_old; \
! $(LN_S) $(INSTPGP) pgpe; \
! $(LN_S) $(INSTPGP) pgps; \
! $(LN_S) $(INSTPGP) pgpv; \
! $(LN_S) $(INSTPGP) pgp_old \
)
- --- 20,30 ----
install:: $(PROG)
( \
! $(INSTALL) -m 755 pgp $(DESTDIR)$(bindir); \
cd $(DESTDIR)$(bindir); \
$(RM) pgpe pgps pgpv pgp_old; \
! $(LN_S) pgp pgpe; \
! $(LN_S) pgp pgps; \
! $(LN_S) pgp pgpv; \
! $(LN_S) pgp pgp_old \
)
diff -r -c pgp50i-b8/src/man/Makefile.in old/pgp50i-b8/src/man/Makefile.in ***
pgp50i-b8/src/man/Makefile.in Mon Aug 11 16:01:48 1997 - ---
old/pgp50i-b8/src/man/Makefile.in Sat Aug 9 23:45:36 1997 *************** ***
6,20 ****
# $Id: Makefile.in,v 1.3.2.4 1997/06/24 23:03:16 quark Exp $
#
! # Change this to pgp5 if you want old and new versions in parallel
! INSTPGP=pgp
! MAN1=$(INSTPGP).1 pgpe.1 pgpk.1 pgps.1 pgpv.1
MAN5=pgp.cfg.5
! $(INSTPGP).1: pgp.1
! $(LN_S) $< $@
!
! install:: $(INSTPGP).1
if test 'x$(MAN1)' != x; then \
if test ! -d $(DESTDIR)$(mandir)/man1; then \
mkdir -p $(DESTDIR)$(mandir)/man1; \
- --- 6,15 ----
# $Id: Makefile.in,v 1.3.2.4 1997/06/24 23:03:16 quark Exp $
#
! MAN1=pgp.1 pgpe.1 pgpk.1 pgps.1 pgpv.1
MAN5=pgp.cfg.5
! install::
if test 'x$(MAN1)' != x; then \
if test ! -d $(DESTDIR)$(mandir)/man1; then \
mkdir -p $(DESTDIR)$(mandir)/man1; \
-------------------
Hope this helps // Tom
--
Tom Leitner Dept. of Communications, Graz Univ. of Technology,
tom@finwds01.tu-graz.ac.at Inffeldgasse 12, A-8010 Graz / Austria / Europe
PGP public key @ http://wiis.tu-graz.ac.at/people/tom.html
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~1998-12-25 5:00 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1998-12-10 5:00 PGP and DUnix Seppo.Routimo
1998-12-24 5:00 ` Nikola Milutinovic
1998-12-25 5:00 ` Thomas Leitner
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox