diff options
Diffstat (limited to 'scripts')
| -rwxr-xr-x | scripts/mingw-x-build-installer.sh | 43 | 
1 files changed, 23 insertions, 20 deletions
| diff --git a/scripts/mingw-x-build-installer.sh b/scripts/mingw-x-build-installer.sh index fb491f6..8f0dddc 100755 --- a/scripts/mingw-x-build-installer.sh +++ b/scripts/mingw-x-build-installer.sh @@ -7,45 +7,48 @@  #  # Usage: ./scripts/mingw-x-build-installer.sh  # -# Result: binary installer in ./release_mingw32 directory +# Result: binary installer in $DEPLOYDIR directory  #  #  # Prerequisites:  # -# You need to run the scripts/mingw-x-build-dependencues.sh script -# and build openscad before running this script. +#   source ./scripts/setenv-mingw-xbuild.sh +#   ./scripts/mingw-x-build-dependencues.sh +# +# and then build openscad before running this script.  #  # You need MCAD. run 'git submodule init && git submodule update'  #  # You need the Nullsoft installer system, on ubuntu 'sudo apt-get install nsis'  #  # You need to copy/paste the FileAssociation.nsh file from -# http://nsis.sourceforge.net/File_Association into RELEASE_DIR +# http://nsis.sourceforge.net/File_Association into DEPLOYDIR  # (it has no license information so cannot be included directly)  #  # Also see http://en.wikibooks.org/wiki/OpenSCAD_User_Manual/Cross-compiling_for_Windows_on_Linux_or_Mac_OS_X  #  OPENSCADDIR=$PWD -RELEASE_DIR=$OPENSCADDIR/release_mingw32 -  if [ ! -f $OPENSCADDIR/openscad.pro ]; then  	echo "Must be run from the OpenSCAD source root directory"  	exit 0  fi +. ./scripts/setenv-mingw-xbuild.sh +  if [ ! -e $OPENSCADDIR/libraries/MCAD ]; then -	echo "Please download the MCAD submodule: (git submodule init && git submodule update)" -	exit 0 +	echo "Downloading MCAD" +	git submodule init +	git submodule update  fi -if [ ! -e $RELEASE_DIR ]; then -	echo $RELEASE_DIR "empty. Please build OpenSCAD for mingw32 first." +if [ ! -e $DEPLOYDIR ]; then +	echo $DEPLOYDIR "empty. Please build OpenSCAD for mingw32 first."  	exit 0  fi -if [ ! -e $RELEASE_DIR/openscad.exe ]; then -	echo "Can't find" $RELEASE_DIR"/openscad.exe Please build OpenSCAD for mingw32 first." +if [ ! -e $DEPLOYDIR/openscad.exe ]; then +	echo "Can't find" $DEPLOYDIR"/openscad.exe Please build OpenSCAD for mingw32 first."  	exit 0  fi @@ -54,24 +57,24 @@ if [ ! "`command -v makensis`" ]; then  	exit 0  fi -if [ ! -e $RELEASE_DIR/FileAssociation.nsh ]; then -	echo "Please install FileAssociation.nsh into" $RELEASE_DIR +if [ ! -e $DEPLOYDIR/FileAssociation.nsh ]; then +	echo "Please install FileAssociation.nsh into" $DEPLOYDIR  	echo "You can copy/paste it from http://nsis.sourceforge.net/File_Association"  fi -echo "Copying files to" $RELEASE_DIR +echo "Copying files to" $DEPLOYDIR -cp -av $OPENSCADDIR/libraries $RELEASE_DIR -cp -av $OPENSCADDIR/examples $RELEASE_DIR -cp -av $OPENSCADDIR/scripts/installer.nsi $RELEASE_DIR +cp -av $OPENSCADDIR/libraries $DEPLOYDIR +cp -av $OPENSCADDIR/examples $DEPLOYDIR +cp -av $OPENSCADDIR/scripts/installer.nsi $DEPLOYDIR  echo "running nsis" -cd $RELEASE_DIR && makensis installer.nsi +cd $DEPLOYDIR && makensis installer.nsi  cd $OPENSCADDIR -INSTALLFILE=$RELEASE_DIR/openscad_setup.exe +INSTALLFILE=$DEPLOYDIR/openscad_setup.exe  if [ -e $INSTALLFILE ]; then  	echo "Build complete. Install file ready: $INSTALLFILE" | 
