Discussion:
Compiling blat with the Open Watcom compiler
(too old to reply)
dc_w5
2009-05-09 07:13:46 UTC
Permalink
I'm trying to build blat using the Open Watcom compiler (the latest
version, 1.8) using makefile.w32 and it is failing on not finding
mapiwin.h which is included in bldhdrs.cpp.

I'm not sure why MAPI support is needed so I commented out the include
and continued. The build then failed with
sendsmtp.cpp(711): Error! E344: col(66) cannot subtract pointers to
different objects
on this line in sendsmtp.cpp
base64_encode((const unsigned char *)&str[11], (int)(out -
&str[11]), &str[11], FALSE);

I wondered if anyone has managed to compile with the Open Watcom
compiler?

Thanks
namtog
2009-05-09 14:58:09 UTC
Permalink
Greetings dc_w5,

You wrote;
"I'm trying to build blat using the Open Watcom compiler..."

I don't know of anyone who built Blat with other then a
Microsoft product.

It seems the stuff in the Blat source
for other compilers is legacy from Blat pre 2.00.

If you could build Blat with Watcom many would like to
know how you accomplished that task. Myself included.

Namtog
Chip
2009-05-09 16:33:04 UTC
Permalink
Post by namtog
Greetings dc_w5,
You wrote;
"I'm trying to build blat using the Open Watcom compiler..."
I don't know of anyone who built Blat with other then a
Microsoft product.
It seems the stuff in the Blat source
for other compilers is legacy from Blat pre 2.00.
If you could build Blat with Watcom many would like to
know how you accomplished that task. Myself included.
Namtog
I am working on that very thing this morning. I had previously installed
OpenWatcom 1.8 for another project, so I made some minor changes to the
source to get it compiling with OpenWatcom. However, I have an issue with
the linker not finding the socket routines, which I am investigating.
--
Chip
Chip
2009-05-09 16:42:51 UTC
Permalink
----- Original Message -----
From: "Chip" <***@att.net>
To: <***@yahoogroups.com>
Sent: Saturday, May 09, 2009 9:33 AM
Subject: Re: [blat] Re: Compiling blat with the Open Watcom compiler
Post by Chip
Post by namtog
Greetings dc_w5,
You wrote;
"I'm trying to build blat using the Open Watcom compiler..."
I don't know of anyone who built Blat with other then a
Microsoft product.
It seems the stuff in the Blat source
for other compilers is legacy from Blat pre 2.00.
If you could build Blat with Watcom many would like to
know how you accomplished that task. Myself included.
Namtog
I am working on that very thing this morning. I had previously installed
OpenWatcom 1.8 for another project, so I made some minor changes to the
source to get it compiling with OpenWatcom. However, I have an issue with
the linker not finding the socket routines, which I am investigating.
--
Chip
Have it building now. I needed to add "lib wsock32.lib" to the Libfiles
line. I will post the updates soon.
--
Chip
dc_w5
2009-05-09 17:27:10 UTC
Permalink
Post by Chip
Have it building now. I needed to add "lib wsock32.lib" to the Libfiles
line. I will post the updates soon.
--
Chip
Yes, that's one of the things I had to do:

bldhdrs.cpp : comment out #include <mapiwin.h> to remove compiler error
sendsmtp.cpp : cast two pointers to (const unsigned char *) to remove compiler error
blat.h : set INCLUDE_NNTP and SUPPORT_GSSAPI to false, to remove run-time exception
makefile.w32 : add m libr wsock32.lib to LFLAGS, add /DWIN32 to CFLAGS, add unicode.obj to OBJECTS and a dependency line

Got it working now!

Duncan
Chip
2009-05-10 03:42:27 UTC
Permalink
With a little fiddling, I was able to get Blat compiled with OpenWatcom and
to send me some test messages. I needed to make small changes to
makefile.w32, and changes to the source files for compiler warnings, and to
remove some exceptions in the GSS code. It was exception handling in the
GSS class constructor that was causing Blat to crash on me earlier today
when I first compiled it with OpenWatcom v1.8. I removed the "throw"
keywords, and added "return" statements before those closing braces in the
constructor function.

I will put together a release and notes for Tim, likely tomorrow, and let
you good folks have at it.

By the way, it still compiles and runs just fine when compiled with Visual
Studio 2005.
--
Chip
Loading...