Alma Linux 32-Bit ISO Image

Do we have Alma Linux 32-Bit ISO Image for building 32-Bit RPM.
How do we build 32-Bit RPMs of Alma Linux when we don’t have “Alma Linux 32-Bit ISO Image”

dnf list *.i686

The repositories of 64-bit Alma do contain some packages that contain 32-bit binaries. Mostly libraries, so that 32-bit binaries can be dynamically linked at runtime and run on 64-bit Alma.

Those 32-bit RPMs have been compiled with 64-bit compiler on 64-bit system, just like MS C/C++ compilers did remain 32-bit executables long after they were already used to generate 64-bit programs. Windows and ARM executables can be cross-compiled on Linux too, IIRC.

man gcc writes:

   These -m switches are supported in addition to the above on x86-64 processors in 64-bit environments.
       Generate code for a 16-bit, 32-bit or 64-bit environment.  The -m32 option sets "int", "long", and pointer types to 32 bits, and generates code that runs on any i386 system.
       The -m64 option sets "int" to 32 bits and "long" and pointer types to 64 bits, and generates code for the x86-64 architecture.  For Darwin only the -m64 option also turns off the -fno-pic and -mdynamic-no-pic options.
       The -mx32 option sets "int", "long", and pointer types to 32 bits, and generates code for the x86-64 architecture.
       The -m16 option is the same as -m32, except for that it outputs the ".code16gcc" assembly directive at the beginning of the assembly output so that the binary can run in 16-bit mode.
       The -miamcu option generates code which conforms to Intel MCU psABI.  It requires the -m32 option to be turned on.

However, what is the actual goal?

  • To compile legacy code into 32-bit executable so that it can be run on (64-bit) Alma?
    Install necessary *.i686 library packages and adjust compiler/rpmbuild options (if necessary).
  • To generate packages for 32-bit Alma that apparently does not exist?

for -lstdc++
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-redhat-linux/8/ when searching for -lstdc++
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-redhat-linux/8/libstdc++.a when searching for -lstdc++
/usr/bin/ld: cannot find -lstdc++
collect2: error: ld returned 1 exit status
make[3]: *** [Makefile:499:] Error 1
make[3]: Leaving directory ‘/root/COLLAB_ALMA/32_bit/flac/BUILD/flac-1.3.2/src/libFLAC++’
make[2]: *** [Makefile:428: all-recursive] Error 1
make[2]: Leaving directory ‘/root/COLLAB_ALMA/32_bit/flac/BUILD/flac-1.3.2/src’
make[1]: *** [Makefile:484: all-recursive] Error 1
make[1]: Leaving directory ‘/root/COLLAB_ALMA/32_bit/flac/BUILD/flac-1.3.2’
make: *** [Makefile:416: all] Error 2
error: Bad exit status from /var/tmp/rpm-tmp.EorQue (%build)

Please reply where to add -m32 flag to solve this issue

you have to easy choice
you install en vm qemu with centos 7 on board and you built
you use a docker and a official centos 7 and you export the volume to your pc

You did not say what you need those packages for.

You are not building as root user, are you? Always build as regular user.

I don’t build packages, but apparently mock is the recommended tool and it has configs to get proper 32-bit build environment.

Hi jlehtone,

Which config is needed for building Alma 32-Bit RPM.
Can you please mention the name of mock config which is used for building 32-bit RPM