blob: f37a7678b7c77f3272f9310d8698e74861ad6a3b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
|
# Native (non-web) interface written in C for interacting with [Interchange](https://interchangecommerce.org) servers
# Building
## Getting and preparing for configuration
```sh
$ git clone git://darapsa.org/libicclient.git
$ cd libicclient
$ libtoolize
$ autoreconf --install
```
## Optionally setting environment values
```sh
$ export NDK=/opt/android-ndk-r19
$ export TOOLCHAIN=$NDK/toolchains/llvm/prebuilt/linux-x86_64
```
and then
```sh
$ export TARGET=aarch64-linux-android
```
or
```sh
$ export TARGET=armv7a-linux-androideabi
```
or
```sh
$ export TARGET=i686-linux-android
```
or
```sh
$ export TARGET=x86_64-linux-android
```
and then
```sh
$ export API=21
$ export CC=$TOOLCHAIN/bin/$TARGET$API-clang
```
and only for Android 32-bit ARM, reset TARGET
```sh
$ export TARGET=arm-linux-androideabi
```
and then
```sh
$ export AR=$TOOLCHAIN/bin/$TARGET-ar
$ export AS=$TOOLCHAIN/bin/$TARGET-as
$ export LD=$TOOLCHAIN/bin/$TARGET-ld
$ export RANLIB=$TOOLCHAIN/bin/$TARGET-ranlib
$ export STRIP=$TOOLCHAIN/bin/$TARGET-strip
$ export PREFIX=$TOOLCHAIN/sysroot/usr
```
If debugging for Android:
```sh
$ export CPPFLAGS="$CPPFLAGS -DDEBUG -DANDROID"
$ export CFLAGS="$CFLAGS -g"
```
If, for example, on FreeBSD and cross-compiling for arm64 Android relying on Linux binary compatibility:
```sh
$ setenv LDFLAGS "$LDFLAGS -L$PREFIX/lib/$TARGET/$API"
```
## Configuring for various target hosts
```sh
$ ./configure
```
or
```sh
$ ./configure --host=$TARGET --prefix=$PREFIX --libdir=$PREFIX/lib/$TARGET/$API --disable-static
```
or so on.
## Compiling, linking, and installing
```sh
$ make # -jN (with N an integer number of parallel tasks you allow your computer to run for compiling this)
$ sudo make install
```
|