build automake packages into multiarch paths and make sure the commands we run don...
[auto-debuild.git] / auto_debuild.py
index 08a9a79fc62c1e3f4c4917d39bc0241d35770fa5..0db538871e70e43fb814c2bfcb0c506ffff05c87 100755 (executable)
@@ -35,7 +35,13 @@ def automakeRules(config):
        r = RulesFile()
        r.dh += ["--buildsystem=autoconf"]
        r.rules['auto_configure'] = [
-               './configure --build=$$(dpkg-architecture -qDEB_BUILD_GNU_TYPE) --prefix=/usr --sysconfdir=/etc --localstatedir=/var ' +
+               '@dpkg-architecture -qDEB_BUILD_GNU_TYPE > /dev/null', # make sure this command runs successfully (and hope it does so again)
+               '@dpkg-architecture -qDEB_BUILD_MULTIARCH > /dev/null', # make sure this command runs successfully (and hope it does so again)
+               './configure --build=$$(dpkg-architecture -qDEB_BUILD_GNU_TYPE) ' +
+                       '--prefix=/usr --includedir=/usr/include --mandir=/usr/share/man --infodir=/usr/share/info ' +
+                       '--libdir=/usr/lib/$$(dpkg-architecture -qDEB_BUILD_MULTIARCH) '+
+                       '--libexecdir=/usr/lib/$$(dpkg-architecture -qDEB_BUILD_MULTIARCH) '+
+                       '--sysconfdir=/etc --localstatedir=/var ' +
                        ' '.join(config.get('automakeParameters', []))
        ]
        r.rules['auto_clean'] = ['rm -f config.status'] # do not re-use old configuration