X-Git-Url: https://feistymeow.org/gitweb/?a=blobdiff_plain;f=scripts%2Fgenerator%2Fproduce_feisty_meow.sh;h=3985f0957d7a6336e74bc80bf982f4b13f48d662;hb=cf3d63de321ae4a18860c4be8a968eb906ddd2fe;hp=41e3bd544f156c9f5588cc0c669ab39b4462b37c;hpb=e16e899f1a75d8c4df9d36ffac2d8d2d401c4114;p=feisty_meow.git diff --git a/scripts/generator/produce_feisty_meow.sh b/scripts/generator/produce_feisty_meow.sh index 41e3bd54..3985f095 100644 --- a/scripts/generator/produce_feisty_meow.sh +++ b/scripts/generator/produce_feisty_meow.sh @@ -88,7 +88,7 @@ function update_system_helper_header() fi # set the cygwin root path if we're on cygwin. - whichable cygpath + whichable cygpath &>/dev/null if [ $? -eq 0 ]; then # found cygpath, so run it now to get the dossy path of the root ('/' folder). found_root="$(cygpath -w -m /)" @@ -96,20 +96,44 @@ function update_system_helper_header() echo "Failure to find virtual Unix root folder with cygpath." exit 1322 fi -echo "found root as '$found_root'" +#echo "found root as '$found_root'" # translate any backslashes to forward thinking slashes. - found_root=$(echo $found_root | tr '\\' '/') -echo "processed root is now: '$found_root'" + found_root="$(echo $found_root | tr '\\' '/')" +#echo "processed root is now: '$found_root'" # edit the entry in place to correct the default path. sed -i \ -e "s% *#define FEISTY_MEOW_VIRTUAL_UNIX_ROOT \".*$%#define FEISTY_MEOW_VIRTUAL_UNIX_ROOT \"$found_root\"%" \ - "$CLAM_BINARIES/paths.ini" + "$FEISTY_MEOW_BINARIES/system_helper.h" exit_on_error "updating system_helper header in $FEISTY_MEOW_BINARIES" -echo "system helper file now has:" -cat "$FEISTY_MEOW_BINARIES/system_helper.h" +#echo "system helper file now has:" +#cat "$FEISTY_MEOW_BINARIES/system_helper.h" fi } +function make_code { + make $* $BE_NOISY ${BUILD_DEFAULTS[@]} + if [ $? != 0 ]; then + echo "Failed to make on: $*" + exit 2323 + fi +} + +# removes pcdos eol from any scripts. that assumes that the bootstrap script +# itself isn't polluted with them. +function strip_cr { + ctrl_m=$'\015' + for i in $*; do + tempgrep="$(mktemp "$TEMPORARIES_PILE/tempgrep.XXXXXX")" + grep -l "$ctrl_m" "$i" >$tempgrep + if [ ! -z "$(cat $tempgrep)" ]; then + temp="$(mktemp "$TEMPORARIES_PILE/tempsed.XXXXXX")" + sed -e "s/$ctrl_m$//" <$i >$temp + mv -f $temp $i + fi + rm "$tempgrep" + done +} + ############## # turn off sounds to avoid running the sound player that's not been built yet. @@ -122,9 +146,6 @@ echo "Build bootstrap process has started." # preconditions for the build process... -# set up our output directories etc. -prepare_clam_binaries_dir - # set a flag for this process so we can omit certain compilations as necessary. export BOOT_STRAPPING=true @@ -143,30 +164,6 @@ declare -a BUILD_DEFAULTS=( "BOOT_STRAPPING=t" "OPTIMIZE=t" "REBUILD=t" "DEBUG=" # noisy can be added to spew lots of text: "NOISY=t" # this can help with compilation issues by showing all the flags. -function make_code { - make $* $BE_NOISY ${BUILD_DEFAULTS[@]} - if [ $? != 0 ]; then - echo "Failed to make on: $*" - exit 2323 - fi -} - -# removes pcdos eol from any scripts. that assumes that the bootstrap script -# itself isn't polluted with them. -function strip_cr { - ctrl_m=$'\015' - for i in $*; do - tempgrep="$(mktemp "$TEMPORARIES_PILE/tempgrep.XXXXXX")" - grep -l "$ctrl_m" "$i" >$tempgrep - if [ ! -z "$(cat $tempgrep)" ]; then - temp="$(mktemp "$TEMPORARIES_PILE/tempsed.XXXXXX")" - sed -e "s/$ctrl_m$//" <$i >$temp - mv -f $temp $i - fi - rm "$tempgrep" - done -} - # the promote function moves a file from the exe directory into the build's # bin directory. it performs the copy step and makes the file executable. # the original name should just be the root of the filename without any @@ -210,6 +207,9 @@ source "$BUILD_SCRIPTS_PATH/build_variables.sh" "$BUILD_SCRIPTS_PATH/build_varia # clean out any current contents. bash "$BUILD_SCRIPTS_PATH/whack_build.sh" clean +# set up our output directories etc. +prepare_clam_binaries_dir + # make this again so no one gets cranky. mkdir -p "$FEISTY_MEOW_LOGS"