So after TONS of tries of fixing the error myself, i gave up.
CMake seems to be angry at variable called: `IMPORT_EXECUTABLES`.
Log is at https://pastebin.com/hCeXzvZp .
Version of GZDoom: g3.1.0
I'm very new at CMake so any help will be appreciated.
[CMake] Cannot cross-compile for aarch64 architecture
Moderators: GZDoom Developers, LZDoom Developers, UZDoom Developers
Forum rules
Please be as descriptive as possible in your posts (list your hardware and operating system, the version of the source port you are using, any mods you are running and how they're being loaded, etc.)
This will help others to give you a solution!
Please be as descriptive as possible in your posts (list your hardware and operating system, the version of the source port you are using, any mods you are running and how they're being loaded, etc.)
This will help others to give you a solution!
-
NeverMine17
- Posts: 5
- Joined: Tue May 23, 2017 10:40 am
-
Rachael
- Posts: 13979
- Joined: Tue Jan 13, 2004 1:31 pm
- Preferred Pronouns: She/Her
Re: [CMake] Cannot cross-compile for aarch64 architecture
This is not a bug.
-
NeverMine17
- Posts: 5
- Joined: Tue May 23, 2017 10:40 am
Re: [CMake] Cannot cross-compile for aarch64 architecture
Sorry for posting in the wrong place.
So, do you have any comments on this?
So, do you have any comments on this?
-
derkternerks
- Posts: 2
- Joined: Fri Jul 28, 2017 2:13 am
Re: [CMake] Cannot cross-compile for aarch64 architecture
Bumping this because I have the same problem. Where can this be cross-posted if this is not the proper forum?
-
Rachael
- Posts: 13979
- Joined: Tue Jan 13, 2004 1:31 pm
- Preferred Pronouns: She/Her
Re: [CMake] Cannot cross-compile for aarch64 architecture
I moved it to the correct forum already. This really is the best place for it.
I've never done a cross-compile so I can't help you, I am sorry. As far as I know it's not officially supported - someone (maybe Randi?) added in the definitions in CMake for it, but did not provide any documentation.
All I can tell you is, you have to compile for your host platform first, in order to get the dependency tools (updaterevision, zipdir, etc) first.
Alternatively, you can just run QEMU with binfmt support (usually supported by most Debian distros) and edit the CMake files to force GCC to target your desired platform directly.
I've never done a cross-compile so I can't help you, I am sorry. As far as I know it's not officially supported - someone (maybe Randi?) added in the definitions in CMake for it, but did not provide any documentation.
All I can tell you is, you have to compile for your host platform first, in order to get the dependency tools (updaterevision, zipdir, etc) first.
Alternatively, you can just run QEMU with binfmt support (usually supported by most Debian distros) and edit the CMake files to force GCC to target your desired platform directly.
-
_mental_
-

- Posts: 3820
- Joined: Sun Aug 07, 2011 4:32 am
Re: [CMake] Cannot cross-compile for aarch64 architecture
Native build creates ImportExecutables.cmake file. Its full path should be specified as a value of IMPORT_EXECUTABLES variable.
-
Blzut3
-

- Posts: 3219
- Joined: Wed Nov 24, 2004 12:59 pm
- Operating System Version (Optional): Kubuntu
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
Re: [CMake] Cannot cross-compile for aarch64 architecture
I did. It was for building PowerPC binaries on x86 Macs without needing to produce universal binaries (which comes with a lot of limitations since build systems aren't really cut out for that kind of thing). To that end it actually is documented here. Since GZDoom no longer supports that I can't say that the cross compiling feature has ever been tested against anything.Rachael wrote:someone
As it so happens I just set up a script to capture how to cross compile on ECWolf so here's the general idea on how to use it to compile with MinGW on Linux (you can find Android in that file as well). For Linux to Linux just with a different arch you should be able to get away with just setting the C and C++ compilers, turning on FORCE_CROSSCOMPILE, and supplying IMPORT_EXECUTABLES but you may have to do more. The main thing to look out for is system include contamination which can be somewhat influenced by CMAKE_FIND_ROOT_PATH. Basically check the advanced options in CMake and make sure that all the INCLUDE_DIR variables are what you expect them to be.
Officially what CMake recommends is building out a toolchain file, and your distro might provide one for its cross compilers.