- Subject: [slang-users] SLprep_set_eval_hook() usage
- From: "Gisle Vanem" <gvanem@xxxxxxxx>
- Date: Sat, 13 Sep 2014 15:22:59 +0200
Hi list.
I'm trying to extend my small S-Lang powered preprocessed makefile
(modelled after mkmake.c in ./src) to return the Windows SDK-version
my input file is targeting.
My idea was to map values from GetVersionEx() into '-D_WIN32_WINNT=0x??'
values (assuming the SDK match the OS-ver). How do I do this best?
I tried using the 'SLprep_set_eval_hook()' function and in my makefile:
@if $WinDir
@if (CFLAGS = -D_WIN32_WINNT=0x??)
@endif
And see that my hook is called with
'(CFLAGS = -D_WIN32_WINNT=0x??)\n'
Is the only way for hook to be called if the line starts with '@if ('?
If so, do I simply copy the '-DCFLAGS = _WIN32_WINNT=0x0x501'
back into the 'expr' buffer? The docs on this very dim IMHO.
--gv
_______________________________________________
For list information, visit <http://jedsoft.org/slang/mailinglists.html>.
[2014 date index]
[2014 thread index]
[Thread Prev] [Thread Next]
[Date Prev] [Date Next]