Skip to content

Build fails when cross-compiling #14

@sorny92

Description

@sorny92

If you try to cross-compile this package in conan you get the next error:

embedded_python/1.3.2@lumicks/stable: Calling build()

checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking for python3.9... no
checking for python3... python3
checking for --enable-universalsdk... no
checking for --with-universal-archs... no
checking MACHDEP... "linux"
checking for gcc... aarch64-linux-gnu-gcc-9
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... configure: error: in `/root/.conan/data/embedded_python/1.3.2/lumicks/stable/build/910f9072af01bd4246171eddd52c50d404399ecf/build':
configure: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.
See `config.log' for more details
embedded_python/1.3.2@lumicks/stable: 
embedded_python/1.3.2@lumicks/stable: ERROR: Package '910f9072af01bd4246171eddd52c50d404399ecf' build failed
embedded_python/1.3.2@lumicks/stable: WARN: Build folder /root/.conan/data/embedded_python/1.3.2/lumicks/stable/build/910f9072af01bd4246171eddd52c50d404399ecf
ERROR: embedded_python/1.3.2@lumicks/stable: Error in build() method, line 110
        build_helper.build_embedded()
while calling 'build_embedded', line 247
        self._build(self.prefix_dir)
while calling '_build', line 228
        self.conanfile.run(f"../src/configure {config_args}")
        ConanException: Error 1 while executing ../src/configure --enable-shared --prefix=/root/.conan/data/embedded_python/1.3.2/lumicks/stable/build/910f9072af01bd4246171eddd52c50d404399ecf/embedded_python --with-openssl=/root/.conan/data/OpenSSL/1.1.1f/_/_/package/34a6f15abcb5e4a5fe68f8affe1a3a5db07089e2

But the variable --host can't be pass because the arguments are hard-coded on the conanfile.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions