Opened 8 years ago

Last modified 3 years ago

#4085 new defect

OMEdit cross-compilation missing options

Reported by: Martin Sjölund Owned by: Adeel Asghar
Priority: high Milestone:
Component: OMEdit Version:
Keywords: Cc:

Description

OMEdit lists options for cross-compilation based on which compilers it finds in the path, which works great for most architectures.

However, one of the common cases would be amd64 cross-compiling to i386, and for this there is no cross-compiler needed (gcc compiles for both architectures).

I propose to not have any special regex for this and just list i686-linux-gnu if x86_64-linux-gnu is available. And list x86_64-linux-gnu if i?86-linux-gnu is available.

Change History (10)

comment:1 by Rüdiger Franke, 8 years ago

FMI requires static linkage. The static 32bit libs for cross compilation, like libgcc, would hardly be available per default.

Wouldn't it be easier to customize the environment for cross-compilation, such that the generic rule by OMEdit (and the Cpp runtime) recognises it, instead of introducing special rules and still require custom installation actions?

I.e. install the libs and create a shell file i686-linux-gnu-gcc that calls gcc -m32?

comment:2 by Martin Sjölund, 8 years ago

The point is then the user would never see this option, because Linux OS'es will not install this file by default... And anyway, the build project already knows how to cross-compile to this architecture, which is rather common. We do statically link libgcc only if the library is found. And if a 32-bit libc6 is available, chances are very good that a static libgcc is available anyway. You also get decent error messages if a library is missing.

comment:3 by Rüdiger Franke, 8 years ago

Your use case appears likely under Windows, where people want to use the 64bit version of OpenModelica and build 32bit binaries. We might think of the more generic "32bit" option that shows up in 64bit builds.

comment:4 by Adeel Asghar, 8 years ago

Milestone: 1.11.01.12.0

Milestone changed to 1.12.0 since 1.11.0 was released.

comment:5 by Francesco Casella, 7 years ago

Milestone: 1.12.01.13.0

Milestone moved to 1.13.0 due to 1.12.0 already being released.

comment:6 by Francesco Casella, 6 years ago

Milestone: 1.13.01.14.0

Rescheduled to 1.14.0 after 1.13.0 releasee

comment:7 by Francesco Casella, 5 years ago

Milestone: 1.14.01.16.0

Releasing 1.14.0 which is stable and has many improvements w.r.t. 1.13.2. This issue is rescheduled to 1.16.0

comment:8 by Francesco Casella, 4 years ago

Milestone: 1.16.01.17.0

Retargeted to 1.17.0 after 1.16.0 release

comment:9 by Francesco Casella, 4 years ago

Milestone: 1.17.01.18.0

Retargeted to 1.18.0 because of 1.17.0 timed release.

comment:10 by Francesco Casella, 3 years ago

Milestone: 1.18.0

Ticket retargeted after milestone closed

Note: See TracTickets for help on using tickets.