2 if test -z "${SOLARENV}"; then
3 if test -f ./Env.Build.sh ; then
6 if test -f ./Env.Host.sh ; then
11 if test -z "${SOLARENV}"; then
12 echo "bootstrap: No environment set!"
16 # remove aliases set by Env.Host.sh
17 unalias mkout 2> /dev/null
18 unalias deliver 2> /dev/null
19 unalias build 2> /dev/null
20 unalias zipdep 2> /dev/null
22 # executables are *.exe for WNT. This variable is necessary since Cygwin 1.5.x
23 # Use spawn instead of fork when building dmake on cygwin.
24 if test "$GUI_FOR_BUILD" = "WNT"; then
26 DMAKE_CONF="--enable-spawn"
33 # ------------------------------------------------------------------------------
36 if test "$BUILD_DMAKE" != "NO"; then
37 if test ! -x "$SRC_ROOT/dmake/dmake$EXEEXT"; then
38 cd "$SRC_ROOT/dmake" || exit
40 # If cross-compiling then don't use the cross compilers to build dmake.
41 if test "$GUI_FOR_BUILD" = "WNT"; then
42 # Let the Cygwin gcc be found
43 unset CC CXX AR NM OBJDUMP PKG_CONFIG RANLIB STRIP
44 elif test "$CROSS_COMPILING" = "YES"; then
45 export CC="$CC_FOR_BUILD"
46 export CXX="$CXX_FOR_BUILD"
47 unset AR NM OBJDUMP PKG_CONFIG RANLIB STRIP
50 # For normal unixy systems
51 if test -f "Makefile" ; then
52 $GNUMAKE distclean || exit
55 ./configure $DMAKE_CONF || exit
57 ## invoke the gnu make command set by configure.
61 echo "dmake has been successfully built"
65 echo "dmake/dmake already built"
69 mkdir -p "$SOLARENV/$OUTPATH_FOR_BUILD/bin"
70 if test "$BUILD_DMAKE" != "NO"; then
71 cp -f "$SRC_ROOT/dmake/dmake$EXEEXT" "$SOLARENV/$OUTPATH_FOR_BUILD/bin" || exit
73 echo "dmake copied to $SOLARENV/$OUTPATH_FOR_BUILD/bin/dmake$EXEEXT"
76 #make sure build.pl is executable
78 chmod +x "$SRC_ROOT/solenv/bin/build.pl"
79 chmod +x "$SRC_ROOT/solenv/bin/zipdep.pl"
80 chmod +x "$SRC_ROOT/solenv/bin/gccinstlib.pl"
85 # indent-tabs-mode: nil
88 # vim:set shiftwidth=4 softtabstop=4 expandtab: