fizmo 0.7.4

Version 0.7.3 of the fizmo interpreter is now available in source form from spellbreaker.org/~chrender/fizmo/. While the only new feature is the “maximum-undo-steps” option, it contains some minor optimizations and a lot of bug fixes which are mostly related to Andrew Plotkin’s iOS Fizmo release – many thanks! – making this a recommended update in case you’re willing to build from source, since no binary packages are available yet.

Excellent news!

I tried adding this to Gentoo Linux, but the build system doesn’t play nice. I simply can’t get it to build. I gave up :stuck_out_tongue:

What is going wrong? I had to get Fizmo building on MacOS before I could start porting it to iOS, so I have some experience now. Though I haven’t tried on Linux.

I can build it just fine on its own. But not when building it using an ebuild. These are sandboxed builds (analogous to *.src.rpm packages on RPM-based distros.) fizmo’s build system seems to ignore many variables and have some of them hardcoded (like CFLAGS and LDFLAGS). These issues have been somewhat worked around already by David Leverton, who maintains fizmo in the interactive-fiction Gentoo overlay. But building fails with:

"x86_64-pc-linux-gnu-gcc" -pipe -mtune=native -march=native -O2 -fomit-frame-pointer -floop-interchange -floop-strip-mine -floop-block -Wall -Wextra -DENABLE_READCHAR_VIA_TERMIOS= -I/usr/include/libxml2 -I/var/tmp/portage/games-engines/fizmo-0.7.2/work/fizmo-0.7.2/build/include/fizmo   -c fizmo-console.c
"x86_64-pc-linux-gnu-gcc" -Wl,--as-needed -Wl,-O1 -Wl,--hash-style=gnu -Wl,--sort-common fizmo-console.o -o fizmo-console -lm -L/var/tmp/portage/games-engines/fizmo-0.7.2/work/fizmo-0.7.2/build/lib/fizmo -lfizmo -lxml2  
/usr/lib/gcc/x86_64-pc-linux-gnu/4.7.1/../../../../x86_64-pc-linux-gnu/bin/ld: /var/tmp/portage/games-engines/fizmo-0.7.2/work/fizmo-0.7.2/build/lib/fizmo/libfizmo.a(math.o): undefined reference to symbol 'rint@@GLIBC_2.2.5'
/usr/lib/gcc/x86_64-pc-linux-gnu/4.7.1/../../../../x86_64-pc-linux-gnu/bin/ld: note: 'rint@@GLIBC_2.2.5' is defined in DSO /usr/lib/gcc/x86_64-pc-linux-gnu/4.7.1/../../../../lib64/libm.so so try adding it to the linker command line
/usr/lib/gcc/x86_64-pc-linux-gnu/4.7.1/../../../../lib64/libm.so: could not read symbols: Invalid operation

I tried for quite a bit to find out what’s causing this, but failed and gave up.

Yyyeah, that’s out of my league. Sorry.

OK, figured it out. The problem is that fizmo’s makefiles don’t specify all needed libraries and thus cause underlinking (wiki.mandriva.com/en/Underlinking). This breaks package builds on all distributions that use “–as-needed” in the default linker flags.

I’ve disabled that flag for fizmo and added 0.7.3 in the Gentoo interactive-fiction overlay.

Thanks for posting this, and even more thanks for the fix. I’ll try to improve the build system in the next version. Not being a build system expert, I’d be happy for any suggestions or advice.

There’s now a beta version of a auto[conf|make]-enabled fizmo available at spellbreaker.org/~chrender/fizmo … -b1.tar.gz which appears to work at least for Debian Linux and OS X/Macports.

After two little improvements over the beta, fizmo 0.7.4 is now available from spellbreaker.org/~chrender/fizmo … 7.4.tar.gz, containing no bugfixes but only the new autoconf/automake-based build system, which hopefully makes building/packing a bit easier.

I pushed 0.7.4 to Gentoo’s interactive-fiction overlay. The new build system now works out of the box without requiring any hacks and workarounds anymore :slight_smile:

Btw, “Gentoo” is spelled wrong in christoph-ender.de/fizmo (it says “GenToo”.) The correct name for that distro actually consists of two words: “Gentoo Linux”.