WvStreams now builds with modern compilers; build system switched to redo

12 views
Skip to first unread message

Avery Pennarun

unread,
Oct 6, 2018, 5:39:24 AM10/6/18
to wvstreams-devel, redo
Hi all,

I realize there are very likely zero people remaining on earth who
have any reason to care whether wvstreams still builds, and that
includes me. But I'm on vacation and I thought I would do some
housekeeping, so here we are.

In the years since anybody cared, C++ compilers have become more and
more aggressive about making undefined behaviour "extra undefined" and
also have become sticklers about certain type conversions, so I had to
go through and fix some completely broken things, notably wvtask.cc,
which a large amount of other stuff depended on.

While there I strayed even further into "who cares" territory, fixing
various portability bugs to MacOS. Unit tests seem to all pass there
now.

Compiling for win32 and win64 also works. The unit tests compile, but
there are several important failures when I run them under wine64,
suggesting that something needs more debugging. I haven't yet looked
into that.

In the most exciting and possibly also most pointless news, I also
threw away the old make-based build system (who here remembers and
loves wvrules.mk? Anybody? No?) and replaced it with a completely
new build system using djb redo (https://github.com/apenwarr/redo).
And that, of course, is the reason I embarked on this project at all:
I wanted to experiment with using redo in a fairly complicated build
environment including autoconf, and wvstreams happens to be a project
I already knew a lot about, that has had a finicky build system for a
while, and yet nobody will actually care if I make it unbuildable by
people without redo installed, because nobody cares at all about
wvstreams. So it was a pretty good experiment.

You should be able to build my new wvstreams by doing something like this:

Install djb redo:
git clone https://github.com/apenwarr/redo
cd redo
DESTDIR=/tmp/rd redo install
export PATH=/tmp/rd/usr/bin:$PATH

To build wvstreams standalone on Linux (note: requires openssl 1.0.x,
not 1.1.x, sigh):
git clone https://github.com/apenwarr/wvstreams
cd wvstreams
mkdir out
cd out
../configure
redo -j20 test

To build wvstreams and some of its dependencies, including a
compatible copy of openssl:
git clone https://github.com/apenwarr/wvbuild
cd wvbuild
./configure # to set up for local system
or
./configure-mingw64 # to build using mingw32 cross-compiler for win64
redo -j20

In the unlikely event that anybody cares, please let me know how it
goes. I'm cc'ing the redo-list as well, because this makes a good
example of a fairly complicated set of build scripts, including
redo-make interop (the wvbuild setup correctly builds openssl, dbus,
and zlib, all of which have their own autoconf and Makefile build
systems).

Have fun,

Avery

hgruber

unread,
Oct 7, 2018, 12:31:18 PM10/7/18
to wvstreams-devel
I still do care and give it a try :-)

Helmut

Avery Pennarun

unread,
Oct 9, 2018, 12:22:30 AM10/9/18
to hgruber, wvstreams-devel
On Sun, Oct 7, 2018 at 12:31 PM, hgruber <hgr...@gmx.net> wrote:
> I still do care and give it a try :-)

But... why? :)

If you run into problems, now's a good time to let me know, while my
attention is still (briefly) focused on WvStreams. Maybe we can sort
it out.

If you're still using WvStreams on Windows, note that even when I do
get it compiling right now, many of the unit tests act funny under
wine64. I'm not sure if that's related to win64 incompatibility or
wine being weird, or something else. It's probably only one or two
bugs in some critical library, so should be fixable if I poke at it
for a while.

Have fun,

Avery

Avery Pennarun

unread,
Oct 10, 2018, 1:48:36 AM10/10/18
to wvstreams-devel, redo
On Sat, Oct 6, 2018 at 5:39 AM Avery Pennarun <apen...@gmail.com> wrote:
> Compiling for win32 and win64 also works. The unit tests compile, but
> there are several important failures when I run them under wine64,
> suggesting that something needs more debugging. I haven't yet looked
> into that.

Update: the win32/win64 unit tests are passing now in wine64.
Unsurprisingly the problem was that I had broken some things :)

Have fun,

Avery
Reply all
Reply to author
Forward
0 new messages