Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.kernel > #63398

Re: [PATCH v2] deb-pkg: generate correct build dependencies

From Masahiro Yamada <yamada.masahiro@socionext.com>
Newsgroups linux.debian.kernel
Subject Re: [PATCH v2] deb-pkg: generate correct build dependencies
Date 2019-02-18 17:40 +0100
Message-ID <xsU7w-2ko-13@gated-at.bofh.it> (permalink)
References <xbMSK-61U-1@gated-at.bofh.it> <xbWIq-3yQ-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Hi Riku,


On Thu, Jan 3, 2019 at 6:28 AM Masahiro Yamada
<yamada.masahiro@socionext.com> wrote:
>
> Hi Riku,
>
>
>
> On Wed, Jan 2, 2019 at 6:28 PM <riku.voipio@linaro.org> wrote:
> >
> > From: Riku Voipio <riku.voipio@linaro.org>
> >
> > bison/flex is now needed always for building for kconfig. Some build
> > dependencies depend on kernel configuration, enable them as needed:
> >
> > - libelf-dev when UNWINDER_ORC is set
> > - libssl-dev for SYSTEM_TRUSTED_KEYRING
> >
> > Since the libssl-dev is needed for extract_cert binary, denote with
> > :native to install the libssl-dev for the build machines architecture,
> > rather than for the architecture of the kernel being built.
> >
> > Tested-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
> > Signed-off-by: Riku Voipio <riku.voipio@linaro.org>
> > ---
> > v2: commit message updated
> > ---
>
>
> $ make defconfig && make bindeb-pkg
>
> worked for me, but
>
> $ make allnoconfig && make bindeb-pkg
>
> failed with
>
> dpkg-checkbuilddeps: error: Unmet build dependencies: flex
>
>
> I do not know why.



I looked into this build error.

This happens depending on 'debian/arch'.

My host machine is x86_64.


When I run "make defconfig; make bindeb-pkg",

$ cat debian/arch
amd64



When I run "make allnoconfig; make bindeb-pkg",

$ cat debian/arch
i386



$ head -n 6 debian/control
Source: linux-5.0.0-rc7+
Section: kernel
Priority: optional
Maintainer: Masahiro Yamada <yamada.masahiro@socionext.com>
Build-Depends: bc, kmod, cpio, bison, flex , ,
Homepage: http://www.kernel.org/

$ dpkg-buildpackage -r"fakeroot -u" -ai386 -b -nc
-ucdpkg-buildpackage: source package linux-5.0.0-rc7+
dpkg-buildpackage: source version 5.0.0-rc7+-1
dpkg-buildpackage: source distribution xenial
dpkg-buildpackage: source changed by Masahiro Yamada
<yamada.masahiro@socionext.com>
dpkg-architecture: warning: specified GNU system type i686-linux-gnu
does not match CC system type x86_64-linux-gnu, try setting a correct
CC environment variable
dpkg-buildpackage: host architecture i386
 dpkg-source --before-build linux
dpkg-checkbuilddeps: error: Unmet build dependencies: flex
dpkg-buildpackage: warning: build dependencies/conflicts unsatisfied; aborting
dpkg-buildpackage: warning: (Use -d flag to override.)


After I applied the following patch,
I was able to build "make allnoconfig; make bindeb-pkg".



diff --git a/scripts/package/Makefile b/scripts/package/Makefile
index 453fece..6793642 100644
--- a/scripts/package/Makefile
+++ b/scripts/package/Makefile
@@ -72,11 +72,11 @@ deb-pkg: FORCE
        $(call cmd,src_tar,$(KDEB_SOURCENAME))
        origversion=$$(dpkg-parsechangelog -SVersion |sed 's/-[^-]*$$//');\
                mv $(KDEB_SOURCENAME).tar.gz
../$(KDEB_SOURCENAME)_$${origversion}.orig.tar.gz
-       +dpkg-buildpackage -r$(KBUILD_PKG_ROOTCMD) -a$$(cat
debian/arch) -i.git -us -uc
+       +dpkg-buildpackage -r$(KBUILD_PKG_ROOTCMD) --target-arch
$$(cat debian/arch) -i.git -us -uc

 bindeb-pkg: FORCE
        $(CONFIG_SHELL) $(srctree)/scripts/package/mkdebian
-       +dpkg-buildpackage -r$(KBUILD_PKG_ROOTCMD) -a$$(cat
debian/arch) -b -nc -uc
+       +dpkg-buildpackage -r$(KBUILD_PKG_ROOTCMD) --target-arch
$$(cat debian/arch) -b -nc -uc

 intdeb-pkg: FORCE
        +$(CONFIG_SHELL) $(srctree)/scripts/package/builddeb





--
Best Regards
Masahiro Yamada

Back to linux.debian.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v2] deb-pkg: generate correct build dependencies riku.voipio@linaro.org - 2019-01-02 12:30 +0100
  Re: [PATCH v2] deb-pkg: generate correct build dependencies Ben Hutchings <ben@decadent.org.uk> - 2019-01-02 20:50 +0100
    Re: [PATCH v2] deb-pkg: generate correct build dependencies maximilian attems <maks@stro.at> - 2019-01-02 21:30 +0100
  Re: [PATCH v2] deb-pkg: generate correct build dependencies Masahiro Yamada <yamada.masahiro@socionext.com> - 2019-01-02 23:00 +0100
    Re: [PATCH v2] deb-pkg: generate correct build dependencies Masahiro Yamada <yamada.masahiro@socionext.com> - 2019-02-18 17:40 +0100
      Re: [PATCH v2] deb-pkg: generate correct build dependencies Masahiro Yamada <yamada.masahiro@socionext.com> - 2019-02-18 18:30 +0100
        Re: [PATCH v2] deb-pkg: generate correct build dependencies Ben Hutchings <ben@decadent.org.uk> - 2019-02-18 19:00 +0100
          Re: [PATCH v2] deb-pkg: generate correct build dependencies Ben Hutchings <ben@decadent.org.uk> - 2019-02-18 19:00 +0100
          Re: [PATCH v2] deb-pkg: generate correct build dependencies Masahiro Yamada <yamada.masahiro@socionext.com> - 2019-02-19 03:40 +0100
            Re: [PATCH v2] deb-pkg: generate correct build dependencies Masahiro Yamada <yamada.masahiro@socionext.com> - 2019-02-20 05:10 +0100

csiph-web