Skip to content

Commit 6890f37

Browse files
committed
INSTALL: Document 32bit and cross-compilation setup
which requires also to set pkg-config environment variables. This setup is needed since c7d2a74 ("rpc-tirpc: Detect libtirpc with pkg-config") Reviewed-by: Li Wang <[email protected]> Acked-by: Jan Stancek <[email protected]> Acked-by: Cyril Hrubis <[email protected]> Signed-off-by: Petr Vorel <[email protected]>
1 parent dfda9ec commit 6890f37

File tree

1 file changed

+16
-2
lines changed

1 file changed

+16
-2
lines changed

INSTALL

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -214,14 +214,28 @@ contributions are welcome.
214214

215215
Cross compiling
216216
---------------
217-
218217
To cross compile, you must specify the correct variables when running configure.
219-
e.g. CC, LDFLAGS, etc...
218+
e.g. CC, LDFLAGS, etc.
219+
For correct pkgconf / pkg-config detection you need to set
220+
PKG_CONFIG_SYSROOT_DIR=$SYSROOT
220221

221222
After configure has run, it will generate include/mk/config.mk. You can tweak
222223
settings in there if need be, but you should not specificy settings on the
223224
command-line when running make.
224225

226+
32 bit build on 64 bit machine
227+
------------------------------
228+
You need to set CFLAGS=-m32 LDFLAGS=-m32 and PKG_CONFIG_LIBDIR
229+
230+
* RPM based distributions (openSUSE, Fedora, etc.)
231+
PKG_CONFIG_LIBDIR=/usr/lib/pkgconfig CFLAGS=-m32 LDFLAGS=-m32 ./configure
232+
233+
* Debian / Ubuntu and derivates
234+
PKG_CONFIG_LIBDIR=/usr/lib/i386-linux-gnu/pkgconfig CFLAGS=-m32 LDFLAGS=-m32 ./configure
235+
236+
* Arch Linux
237+
PKG_CONFIG_LIBDIR=/usr/lib32/pkgconfig CFLAGS=-m32 LDFLAGS=-m32 ./configure
238+
225239
uClinux Users
226240
--------------
227241
Specify UCLINUX=1 when calling make; -DUCLINUX=1 use is deprecated and highly

0 commit comments

Comments
 (0)