summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAmaury Pouly <amaury.pouly@gmail.com>2016-05-13 23:55:33 +0100
committerAmaury Pouly <amaury.pouly@gmail.com>2016-05-13 23:55:33 +0100
commit60fb707203c5b0ce2c32776890611846f0c22566 (patch)
tree000158568f4a7037b6eca4248097743fd07ea51e
parentd405026ca8bc4c63d8fcd5d63cef02341182774b (diff)
downloadrockbox-60fb707203c5b0ce2c32776890611846f0c22566.tar.gz
rockbox-60fb707203c5b0ce2c32776890611846f0c22566.zip
configure: statically link sdl on win32 cross compile
Change-Id: If9115da0470e2c301589329af67433f7260d24d3
-rwxr-xr-xtools/configure4
-rwxr-xr-xtools/release/sims.pl11
2 files changed, 2 insertions, 13 deletions
diff --git a/tools/configure b/tools/configure
index efad8a7c46..0c040455ae 100755
--- a/tools/configure
+++ b/tools/configure
@@ -255,7 +255,7 @@ simcc () {
255 if [ "$win32crosscompile" = "yes" ]; then 255 if [ "$win32crosscompile" = "yes" ]; then
256 # We are crosscompiling 256 # We are crosscompiling
257 # add cross-compiler option(s) 257 # add cross-compiler option(s)
258 LDOPTS="$LDOPTS -mconsole" 258 LDOPTS="$LDOPTS -mconsole -static"
259 output="$output.exe" 259 output="$output.exe"
260 winbuild="yes" 260 winbuild="yes"
261 CROSS_COMPILE=${CROSS_COMPILE:-"i586-mingw32msvc-"} 261 CROSS_COMPILE=${CROSS_COMPILE:-"i586-mingw32msvc-"}
@@ -342,7 +342,7 @@ simcc () {
342 else 342 else
343 # generic sdl-config checker 343 # generic sdl-config checker
344 GCCOPTS="$GCCOPTS `$sdl --cflags`" 344 GCCOPTS="$GCCOPTS `$sdl --cflags`"
345 LDOPTS="$LDOPTS `$sdl --libs`" 345 LDOPTS="$LDOPTS `$sdl --static-libs`"
346 fi 346 fi
347 fi 347 fi
348 348
diff --git a/tools/release/sims.pl b/tools/release/sims.pl
index 1a6edb3ea1..d5cef51c67 100755
--- a/tools/release/sims.pl
+++ b/tools/release/sims.pl
@@ -148,22 +148,11 @@ sub runone {
148 print "Zip up the sim and associated files\n" if ($verbose); 148 print "Zip up the sim and associated files\n" if ($verbose);
149 mkpath(dirname($newo)); 149 mkpath(dirname($newo));
150 system("mv build-$dir $newo"); 150 system("mv build-$dir $newo");
151 if ($cross) {
152 print "Find and copy SDL.dll\n" if ($verbose);
153 open(MAKE, "$newo/Makefile");
154 my $GCCOPTS=(grep(/^export GCCOPTS=/, <MAKE>))[0];
155 chomp($GCCOPTS);
156 (my $sdldll = $GCCOPTS) =~ s/^export GCCOPTS=.*-I([^ ]+)\/include\/SDL.*$/$1\/bin\/SDL.dll/;
157 print "Found $sdldll\n" if ($verbose);
158 `cp $sdldll ./$newo/`;
159 close(MAKE);
160 }
161 my $toplevel = getcwd(); 151 my $toplevel = getcwd();
162 chdir(dirname($newo)); 152 chdir(dirname($newo));
163 $cmd = "zip -9 -r -q \"".basename($newo)."\" " 153 $cmd = "zip -9 -r -q \"".basename($newo)."\" "
164 . "\"".basename($newo)."\"/rockboxui* " 154 . "\"".basename($newo)."\"/rockboxui* "
165 . "\"".basename($newo)."\"/UI256.bmp " 155 . "\"".basename($newo)."\"/UI256.bmp "
166 . "\"".basename($newo)."\"/SDL.dll "
167 . "\"".basename($newo)."\"/simdisk "; 156 . "\"".basename($newo)."\"/simdisk ";
168 print("$cmd\n") if($verbose); 157 print("$cmd\n") if($verbose);
169 `$cmd`; 158 `$cmd`;