Port scons build files for Windows users

We disable:
- the tests (which require glib) although they can be
  reactivated with the `--tests` command line flag
- shared library (lack of export symbol declarations
  means that although it can be built, no symbol is
  exported and therefore it can't be used)

The `install` target installs the library and headers
under the `build` folder, because it's a traditional practice
to move libraries to a central location on Windows, unless
you are using cygwin. In which case pass `prefix` to the
command line.

We adapt tools\windows\build_examples.bat to take the library
that is built using scons or using tools\windows\build.bat
This commit is contained in:
nicolas 2016-05-22 13:29:12 +02:00
parent f31e3ba4bd
commit 69d3e70211
4 changed files with 76 additions and 21 deletions

View file

@ -24,8 +24,8 @@ cl.exe -nologo -FC -EHsc -Z7 -Oi -GR- -Gm- %CLFLAGS% -c ^
-Fo%BUILD%\obj\
if %errorlevel% neq 0 goto err
lib.exe %BUILD%\obj\*.obj -OUT:%BUILD%\hammer.lib
echo STATIC_LIBRARY %BUILD%\hammer.lib
lib.exe %BUILD%\obj\*.obj -OUT:%BUILD%\lib\hammer_s.lib
echo STATIC_LIBRARY %BUILD%\lib\hammer_s.lib
if %errorlevel% neq 0 goto err
popd

View file

@ -15,7 +15,7 @@ call %HEREPATH%\clvars.bat
echo SRC=%SRC%, BUILD=%BUILD%
echo CLFLAGS=%CLFLAGS%
set HAMMERLIB=%BUILD%\hammer.lib
set HAMMERLIB=%BUILD%\lib\hammer_s.lib
REM Now let's build some example programs