Commit 8349e65fb16f8dc3d7a10df90f8d40340dc3c40f
Committed by
GitHub
Exists in
master
and in
1 other branch
Merge pull request #3 from PerryWerneck/develop
Adding archlinux build, updating README
Showing
4 changed files
with
201 additions
and
5 deletions
Show diff stats
README.md
@@ -6,7 +6,7 @@ See more details at https://softwarepublico.gov.br/social/pw3270/ | @@ -6,7 +6,7 @@ See more details at https://softwarepublico.gov.br/social/pw3270/ | ||
6 | 6 | ||
7 | [](https://www.gnu.org/licenses/gpl-3.0) | 7 | [](https://www.gnu.org/licenses/gpl-3.0) |
8 |  | 8 |  |
9 | - | 9 | + |
10 |  | 10 |  |
11 | 11 | ||
12 | ## Instalation | 12 | ## Instalation |
@@ -44,13 +44,17 @@ For the supported distributions get the install repositories and instructions fr | @@ -44,13 +44,17 @@ For the supported distributions get the install repositories and instructions fr | ||
44 | $ git clone https://github.com/PerryWerneck/libipc3270.git ./libipc3270 | 44 | $ git clone https://github.com/PerryWerneck/libipc3270.git ./libipc3270 |
45 | ``` | 45 | ``` |
46 | 46 | ||
47 | -3. Install cross compilers | 47 | +3. Install 64 bits cross compilers |
48 | 48 | ||
49 | - TODO | 49 | + ```shell |
50 | + $ ./libipc3270/win/install-cross.sh --64 | ||
51 | + ``` | ||
50 | 52 | ||
51 | -3. Configure build | 53 | +3. Configure 64 bits build environment |
52 | 54 | ||
53 | - TODO | 55 | + ```shell |
56 | + $ ./libipc3270/win/win-configure.sh --64 | ||
57 | + ``` | ||
54 | 58 | ||
55 | 4. Build | 59 | 4. Build |
56 | 60 |
@@ -0,0 +1,40 @@ | @@ -0,0 +1,40 @@ | ||
1 | +# Maintainer: Perry Werneck <perry.werneck@gmail.com> | ||
2 | + | ||
3 | +pkgname=libipc3270 | ||
4 | + | ||
5 | +pkgver=5.3 | ||
6 | +pkgrel=0 | ||
7 | +pkgdesc="IPC client library for lib3270/pw3270" | ||
8 | +url="https://github.com/PerryWerneck/libipc3270" | ||
9 | +arch=(i686 x86_64) | ||
10 | +license=(GPL) | ||
11 | +depends=() | ||
12 | +makedepends=(autoconf automake make openssl lib3270 libv3270 python3 gtk3 libtool dbus-glib) | ||
13 | +checkdepends=() | ||
14 | + | ||
15 | +#groups=(gnome) | ||
16 | + | ||
17 | +source=($pkgname-$pkgver.tar.xz) | ||
18 | +sha256sums=('SKIP') | ||
19 | + | ||
20 | +provides=($pkgname) | ||
21 | +conflicts=($pkgname) | ||
22 | + | ||
23 | +prepare() { | ||
24 | + cd $pkgname-$pkgver | ||
25 | + mkdir -p scripts | ||
26 | + touch scripts/config.rpath | ||
27 | + NOCONFIGURE=1 ./autogen.sh | ||
28 | + ./configure --prefix=/usr --disable-static | ||
29 | +} | ||
30 | + | ||
31 | +build() { | ||
32 | + cd $pkgname-$pkgver | ||
33 | + make all | ||
34 | +} | ||
35 | + | ||
36 | +package() { | ||
37 | + cd $pkgname-$pkgver | ||
38 | + DESTDIR="$pkgdir" make install | ||
39 | +} | ||
40 | + |
@@ -0,0 +1,69 @@ | @@ -0,0 +1,69 @@ | ||
1 | +#!/bin/bash | ||
2 | + | ||
3 | +aclocal | ||
4 | +if test $? != 0 ; then | ||
5 | + echo "aclocal failed." | ||
6 | + exit -1 | ||
7 | +fi | ||
8 | + | ||
9 | +autoconf | ||
10 | +if test $? != 0 ; then | ||
11 | + echo "autoconf failed." | ||
12 | + exit -1 | ||
13 | +fi | ||
14 | + | ||
15 | +mkdir -p scripts | ||
16 | +automake --add-missing 2> /dev/null | true | ||
17 | + | ||
18 | +export HOST_CC=/usr/bin/gcc | ||
19 | + | ||
20 | +until [ -z "${1}" ] | ||
21 | +do | ||
22 | + if [ ${1:0:2} = '--' ]; then | ||
23 | + tmp=${1:2} | ||
24 | + parameter=${tmp%%=*} | ||
25 | + parameter=$(echo $parameter | tr "[:lower:]" "[:upper:]") | ||
26 | + | ||
27 | + case $parameter in | ||
28 | + | ||
29 | + 32) | ||
30 | + rm -f win32.cache | ||
31 | + ./configure \ | ||
32 | + --cache-file=win32.cache \ | ||
33 | + --host=i686-w64-mingw32 \ | ||
34 | + --prefix=/usr/i686-w64-mingw32/sys-root/mingw \ | ||
35 | + --libdir=/usr/i686-w64-mingw32/sys-root/mingw/lib | ||
36 | + | ||
37 | + exit $? | ||
38 | + ;; | ||
39 | + | ||
40 | + 64) | ||
41 | + rm -f win64.cache | ||
42 | + ./configure \ | ||
43 | + --cache-file=win64.cache \ | ||
44 | + --host=x86_64-w64-mingw32 \ | ||
45 | + --prefix=/usr/x86_64-w64-mingw32/sys-root/mingw \ | ||
46 | + --libdir=/usr/x86_64-w64-mingw32/sys-root/mingw/lib | ||
47 | + exit $? | ||
48 | + ;; | ||
49 | + | ||
50 | + ALL) | ||
51 | + ;; | ||
52 | + | ||
53 | + | ||
54 | + *) | ||
55 | + value=${tmp##*=} | ||
56 | + eval $parameter=$value | ||
57 | + esac | ||
58 | + | ||
59 | + fi | ||
60 | + | ||
61 | + shift | ||
62 | +done | ||
63 | + | ||
64 | +echo "Execute:" | ||
65 | +echo " ${0} --32 for 32 bits windows." | ||
66 | +echo " ${0} --64 for 64 bits windows." | ||
67 | + | ||
68 | +exit -1 | ||
69 | + |
@@ -0,0 +1,83 @@ | @@ -0,0 +1,83 @@ | ||
1 | +#!/bin/bash | ||
2 | + | ||
3 | +install_packages() { | ||
4 | + | ||
5 | +TEMPFILE=$(mktemp) | ||
6 | + | ||
7 | +cat > ${TEMPFILE} << EOF | ||
8 | +libtool | ||
9 | +gettext-devel | ||
10 | +cross-binutils | ||
11 | +cross-gcc | ||
12 | +cross-gcc-c++ | ||
13 | +cross-pkg-config | ||
14 | +filesystem | ||
15 | +lib3270-devel | ||
16 | +libv3270-devel | ||
17 | +EOF | ||
18 | + | ||
19 | +# Instala apicativos e temas necessários | ||
20 | +sudo zypper --non-interactive in \ | ||
21 | + adwaita-icon-theme \ | ||
22 | + gettext-tools \ | ||
23 | + glib2-devel \ | ||
24 | + autoconf \ | ||
25 | + automake \ | ||
26 | + libtool | ||
27 | + | ||
28 | +while read FILE | ||
29 | +do | ||
30 | + sudo zypper --non-interactive in ${1}-${FILE} | ||
31 | +done < ${TEMPFILE} | ||
32 | + | ||
33 | +rm -f ${TEMPFILE} | ||
34 | + | ||
35 | +} | ||
36 | + | ||
37 | +if [ -z ${1} ]; then | ||
38 | + echo "Use ${0} --32 for 32 bits cross-compiler" | ||
39 | + echo "Use ${0} --64 for 64 bits cross-compiler" | ||
40 | + exit -1 | ||
41 | +fi | ||
42 | + | ||
43 | + | ||
44 | +until [ -z "${1}" ] | ||
45 | +do | ||
46 | + if [ ${1:0:2} = '--' ]; then | ||
47 | + tmp=${1:2} | ||
48 | + parameter=${tmp%%=*} | ||
49 | + parameter=$(echo $parameter | tr "[:lower:]" "[:upper:]") | ||
50 | + | ||
51 | + case $parameter in | ||
52 | + | ||
53 | + ar) | ||
54 | + zypper ar obs://windows:mingw:win32 mingw32 | ||
55 | + zypper ar obs://windows:mingw:win64 mingw64 | ||
56 | + zypper ar obs://home:PerryWerneck:pw3270 pw3270 | ||
57 | + ;; | ||
58 | + | ||
59 | + 32) | ||
60 | + install_packages mingw32 | ||
61 | + ;; | ||
62 | + | ||
63 | + 64) | ||
64 | + install_packages mingw64 | ||
65 | + ;; | ||
66 | + | ||
67 | + ALL) | ||
68 | + install_packages mingw32 | ||
69 | + install_packages mingw64 | ||
70 | + ;; | ||
71 | + | ||
72 | + | ||
73 | + *) | ||
74 | + value=${tmp##*=} | ||
75 | + eval $parameter=$value | ||
76 | + esac | ||
77 | + | ||
78 | + fi | ||
79 | + | ||
80 | + shift | ||
81 | +done | ||
82 | + | ||
83 | + |