Commit f865586c9c4ff4546460800c82692eb48241fb88
1 parent
98a79c4d
Exists in
master
Incluindo scripts para cross-compiling em windows.
Showing
2 changed files
with
90 additions
and
0 deletions
Show diff stats
@@ -0,0 +1,60 @@ | @@ -0,0 +1,60 @@ | ||
1 | +#!/bin/bash | ||
2 | + | ||
3 | +install_packages() | ||
4 | +{ | ||
5 | + | ||
6 | +# Instala apicativos e temas necessários | ||
7 | +sudo zypper --non-interactive in \ | ||
8 | + ${1}-cross-gcc-c++ \ | ||
9 | + ${1}-cross-pkg-config \ | ||
10 | + ${1}-cross-cpp \ | ||
11 | + ${1}-cross-binutils \ | ||
12 | + ${1}-pw3270 \ | ||
13 | + ${1}-lib3270-devel \ | ||
14 | + ${1}-pw3270-devel | ||
15 | + | ||
16 | +} | ||
17 | + | ||
18 | + | ||
19 | +until [ -z "${1}" ] | ||
20 | +do | ||
21 | + if [ ${1:0:2} = '--' ]; then | ||
22 | + tmp=${1:2} | ||
23 | + parameter=${tmp%%=*} | ||
24 | + parameter=$(echo $parameter | tr "[:lower:]" "[:upper:]") | ||
25 | + | ||
26 | + case $parameter in | ||
27 | + | ||
28 | + ar) | ||
29 | + zypper ar --refresh http://download.opensuse.org/repositories/windows:/mingw:/win32/openSUSE_42.2/ mingw32 | ||
30 | + zypper ar --refresh http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_42.2/ mingw64 | ||
31 | + zypper ar --refresh http://download.opensuse.org/repositories/home:/PerryWerneck:/mingw32/openSUSE_Leap_42.2/ mingw32-pw3270 | ||
32 | + zypper ar --refresh http://download.opensuse.org/repositories/home:/PerryWerneck:/mingw64/openSUSE_Leap_42.2/ mingw64-pw3270 | ||
33 | + zypper ref | ||
34 | + ;; | ||
35 | + | ||
36 | + 32) | ||
37 | + install_packages mingw32 | ||
38 | + ;; | ||
39 | + | ||
40 | + 64) | ||
41 | + install_packages mingw64 | ||
42 | + ;; | ||
43 | + | ||
44 | + ALL) | ||
45 | + install_packages mingw32 | ||
46 | + install_packages mingw64 | ||
47 | + ;; | ||
48 | + | ||
49 | + | ||
50 | + *) | ||
51 | + value=${tmp##*=} | ||
52 | + eval $parameter=$value | ||
53 | + esac | ||
54 | + | ||
55 | + fi | ||
56 | + | ||
57 | + shift | ||
58 | +done | ||
59 | + | ||
60 | + |
@@ -0,0 +1,30 @@ | @@ -0,0 +1,30 @@ | ||
1 | +#!/bin/bash | ||
2 | + | ||
3 | +myDIR=$(dirname $(dirname $(readlink -f $0))) | ||
4 | + | ||
5 | +cd $myDIR | ||
6 | + | ||
7 | +rm -f *.zip | ||
8 | + | ||
9 | +win32-configure && make clean && make zip | ||
10 | +if [ "$?" != "0" ]; then | ||
11 | + exit -1 | ||
12 | +fi | ||
13 | + | ||
14 | +win64-configure && make clean && make zip | ||
15 | +if [ "$?" != "0" ]; then | ||
16 | + exit -1 | ||
17 | +fi | ||
18 | + | ||
19 | +if [ -d ~/public_html/win/pw3270/x86_32 ]; then | ||
20 | + cp *i686*.zip ~/public_html/win/pw3270/x86_32 | ||
21 | +elif [ -d ~/public_html/win/x86_32 ]; then | ||
22 | + cp *i686*.zip ~/public_html/win/x86_32 | ||
23 | +fi | ||
24 | + | ||
25 | +if [ -d ~/public_html/win/pw3270/x86_64 ]; then | ||
26 | + cp *x86_64*.zip ~/public_html/win/pw3270/x86_64 | ||
27 | +elif [ -d ~/public_html/win/x86_32 ]; then | ||
28 | + cp *x86_64*.zip ~/public_html/win/x86_64 | ||
29 | +fi | ||
30 | + |