[v2,1/4] config: add 32-bit x86 debian cross-compilation file

Message ID 20240906161244.1663967-2-bruce.richardson@intel.com (mailing list archive)
State New
Delegated to: David Marchand
Headers
Series simplify doing 32-bit DPDK builds |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Bruce Richardson Sept. 6, 2024, 4:12 p.m. UTC
To simplify building 32-bit binaries on 64-bit system, we can supply a
cross-compilation file which provides the relevant compiler flags and
settings needed - '-m32' compile/link flag, and appropriate
PKG_CONFIG_LIBDIR value. This latter setting will depend upon the layout
format of the particular OS/distro in use, so initially add a cross file
with paths set for Debian or Ubuntu systems.

Note, unlike previous cross files, this file has a .ini extension which
means that editors use correct syntax highlighting on it.

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com>
---
 config/x86/cross-32bit-debian.ini | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)
 create mode 100644 config/x86/cross-32bit-debian.ini

--
2.43.0
  

Patch

diff --git a/config/x86/cross-32bit-debian.ini b/config/x86/cross-32bit-debian.ini
new file mode 100644
index 0000000000..2f6e4714cb
--- /dev/null
+++ b/config/x86/cross-32bit-debian.ini
@@ -0,0 +1,22 @@ 
+[binaries]
+c = 'cc'
+cpp = 'c++'
+ar = 'ar'
+strip = 'strip'
+pkg-config = 'pkg-config'
+
+[host_machine]
+system = 'linux'
+cpu_family = 'x86'
+cpu = 'native'
+endian = 'little'
+
+[properties]
+pkg_config_libdir = '/usr/lib/i386-linux-gnu/pkgconfig'
+
+[built-in options]
+c_args = '-m32'
+c_link_args = '-m32'
+cpp_args = '-m32'
+cpp_link_args = '-m32'
+libdir = 'lib/i386-linux-gnu'