Makefile 如何使用jhbuild交叉编译模块?

Makefile 如何使用jhbuild交叉编译模块?,makefile,cross-compiling,autotools,jhbuild,Makefile,Cross Compiling,Autotools,Jhbuild,我有一个如下jhbuild.modulesxml文件,实际上我想交叉编译它 我知道将--hostparam添加到autogenargs中会起作用,但我希望这样做时不必触及下面的jhbuild.modules文件 <?xml version="1.0"?> <!DOCTYPE moduleset SYSTEM "moduleset.dtd"> <?xml-stylesheet type="text/xsl" href="moduleset.xsl"?> <

我有一个如下jhbuild.modulesxml文件,实际上我想交叉编译它

我知道将--hostparam添加到autogenargs中会起作用,但我希望这样做时不必触及下面的jhbuild.modules文件

<?xml version="1.0"?>
<!DOCTYPE moduleset SYSTEM "moduleset.dtd">
<?xml-stylesheet type="text/xsl" href="moduleset.xsl"?>
<moduleset>

  <metamodule id="test">
    <dependencies>
      <dep package="cairo"/>
    </dependencies>
  </metamodule>

  <repository type="tarball" name="cairographics.org"
      href="http://cairographics.org"/>
  <repository type="tarball" name="freedesktop.org"
      href="http://www.freedesktop.org"/>

  <autotools id="cairo" autogen-sh="configure">
    <dependencies>
      <dep package="fontconfig"/>
      <dep package="pixman"/>
    </dependencies>
    <branch module="releases/cairo-1.12.8.tar.xz" version="1.12.8"
            repo="cairographics.org"
            hash="sha256:8fbb6fc66117ab4100bad830cb4479497e53c6f3facb98bf05c8d298554ebdd9"/>
  </autotools>

    <autotools id="fontconfig" autogen-sh="configure">
    <dependencies>
      <dep package="freetype6"/>
    </dependencies>
    <branch module="software/fontconfig/release/fontconfig-2.8.0.tar.gz" version="2.8.0"
            repo="freedesktop.org"
            hash="sha256:fa2a1c6eea654d9fce7a4b1220f10c99cdec848dccaf1625c01f076b31382335"/>
  </autotools>

  <autotools id="pixman" autogen-sh="configure"
            autogenargs="--enable-gtk=no">
    <branch module="snapshots/pixman-0.29.2.tar.gz" version="0.29.2"
            repo="cairographics.org"
            hash="sha256:4c4e92143a4557a4617b80caf0a58ccb012d8293741e75389037cd5133b335db"/>
  </autotools>
</moduleset>

autogenargs='--host'
添加到您的
~/.jhbuildrc
配置文件中。

一些库(如fontconfig)也需要使用arch=parameter,但其他库不需要它。模块autogenargs['fontconfig']=“--with cpu=ppc”可以吗?我想你可能不得不说
模块autogenargs['fontconfig']='--host--with cpu=ppc'
。谢谢你的回答!
checking whether we are cross compiling... configure: error: in `/builds/unix':
configure: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.