[dev] [sbase][patch] new expr, take 2 (and makefile improvements)

From: Evan Gates <evan.gates_AT_gmail.com>
Date: Thu, 13 Nov 2014 14:05:19 -0800

After the troubles with yaac and the makefile last time around I wrote
another expr, this time in C, using Dijkstra's shunting-yard
algorithm[0]. The end result is still less than half the length of the
existing recursive descent expr, and provides slightly better error
messages than my last attempt. Included patch: sbase-new_expr2.diff

While working on it I found out that building a single tool in sbase
(e.g. make expr) would fail if util.a was not yet built, so I'm
including a patch to fix that, which adds a recipe for $(BIN) that
depends on util.a. Included patch: sbase-build_single.diff

After that I removed the binlib recipe and just made all depend on
$(BIN). This works for me and I think it should work with other makes
as well, but as I demonstrated last time please make sure to test it.
This patch depends on the previous one. Included patch:
sbase-remove_binlib.diff

And lastly I added -D_DEFAULT_SOURCE in config.mk so gcc will shutup
about -D_BSD_SOURCE being deprecated. Included patch:
sbase-default_source.diff

emg

[0]https://en.wikipedia.org/wiki/Shunting-yard_algorithm

Received on Thu Nov 13 2014 - 23:05:19 CET

This archive was generated by hypermail 2.3.0 : Thu Nov 13 2014 - 23:12:07 CET