flx now has a new switch: flx --force-compiler
This implies --force. What --force does is force flx to invoke the compiler flxg, even if it thinks some files are up to date *except* if you're trying to run an executable in which case it will run even if the files it was built with are not up to date. The latter is so you can run binaries at all, without the sources. I will fix that presently (it isn't consistent and there's no workaround). However --force does not make the flxg compiler rebuild anything, it just forces flx to invoke it (modulo caveat above). The --force-compiler switch passes --force to the flxg compiler which now makes it rebuild the syntax automaton, the libraries, and reparse all the application program as well, that is, it is a total rebuild where all caches are considered dirty. The primary issue here is that when I am building and testing Felix, I am using tools *written in Felix* to do this. If I make a bug .. and I make bugs regularly .. then every change would cause the very tools I am using to build things to themselves get rebuilt and fail due to the bug. This allows me to write in the Makefile: flxg: # building flxg build/release/host/bin/flx --test=build/release src/tools/flx_build_flxg cp tmp-dir/flxg build/release/host/bin copy: # copying ./src to build/release/src build/release/host/bin/flx --test=build/release src/tools/flx_build_rtl \ --repo=.\ --target-dir=build/release \ --target-bin=host \ --copy-repo Note that I am calling flx to run the programs "flx_build_flxg" and "flx_build_rtl". The binary is cached, but I'm doing the run via the source file name. If I do this: flx --clean the caches get deleted and these tools get rebuilt automatically. So if there's a bug, I cannot do the --clean or I'll end up without the tools, and have to revert to the Python build. But apart from cherrypicking deletes on the cache, there was no other way to rebuild and rerun the regression test cases, without also rebuilding the build tools .. and the idea of the regression tests is to find bugs and fix them, so I need the build tools to remain intact using the old (unbugged) code until all the bugs are killed. The --force option didn't fix this properly: it rebuilt the tests as required but it didn't rebuild the standard library. In principle, --force-compiler should be automatic when flx detects the compiler has changed, and that would be fine even in my bootstrapping case, provided fully built executables are not rebuilt. So there's another change coming. We need an option like flx --run fred which will run the executable fred if it exists, without building it, even if the dependencies changed. In fact we need this to run any non-cached program (to get the environment variables for plugins right). This more or less happens now without the --run switch. The problem is that it shouldn't: its inconsistent. In principle flx program is supposed to run program.flx and the binary is supposed to be just a cached value, and with that interpretation if any of the dependencies are missing, including of course the source program.flx, the execution should fail. But I cannot make that happen without the --run switch or the only way to run binaries would be like: program for a static linked exe or flx_arun program.dylib for a shared lib (on OSX) and both of these could fail if any dynamic loading was required (since "flx" wasn't there to get the paths right). You should be able to do this, but you shouldn't HAVE to. -- john skaller skal...@users.sourceforge.net http://felix-lang.org ------------------------------------------------------------------------------ October Webinars: Code for Performance Free Intel webinars can help you accelerate application performance. Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from the latest Intel processors and coprocessors. See abstracts and register > http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk _______________________________________________ Felix-language mailing list Felix-language@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/felix-language