From patchwork Mon Jun 17 13:49:21 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anisse Astier X-Patchwork-Id: 2733501 Return-Path: X-Original-To: patchwork-linux-kbuild@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 471E59F39E for ; Mon, 17 Jun 2013 13:49:40 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 0B99020333 for ; Mon, 17 Jun 2013 13:49:39 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 1B94C20324 for ; Mon, 17 Jun 2013 13:49:34 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755284Ab3FQNtd (ORCPT ); Mon, 17 Jun 2013 09:49:33 -0400 Received: from mail-wi0-f181.google.com ([209.85.212.181]:33040 "EHLO mail-wi0-f181.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750880Ab3FQNtd (ORCPT ); Mon, 17 Jun 2013 09:49:33 -0400 Received: by mail-wi0-f181.google.com with SMTP id hq4so2194318wib.8 for ; Mon, 17 Jun 2013 06:49:31 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=date:from:to:cc:subject:message-id:in-reply-to:references:x-mailer :mime-version:content-type:content-transfer-encoding :x-gm-message-state; bh=mOHvg4vNvR4BP5fYlFS4hiqKvAacYng91FD8CJ+P7kY=; b=WvRxs47mtWAFr5Q67hy5uCCeb10pUn7apn5SNb9EE2Q05vi61l82UIYz/NksQZSCX0 j3LnmPVydRvLbE8T5vbeE3jAG20W7JZ8EWa9V6pa3NbL3PZ6GhGiFzCuguuedqVW0L56 P999B5wDAk1Xz5Ypp32vWUmg7tNPndRUw0COwD06ejqUR2jXQ+BOc5eUIewWTP8sXg0/ epSM3FAW2fFlpSFXHyV4jucC7wUpKKUXH/GKhpjZCDVN52WdnokWGcHn6rvJ6SHHvRfH Zmo8p6adJ5xEi1ehnPyBZF4v9v9c7BrIkjzEVJjYrm1/GXfpQ0PeQOZ7/SBnbivUMrFW 7K6A== X-Received: by 10.180.210.137 with SMTP id mu9mr4848265wic.38.1371476971551; Mon, 17 Jun 2013 06:49:31 -0700 (PDT) Received: from serenity (mar92-17-78-228-214-160.fbx.proxad.net. [78.228.214.160]) by mx.google.com with ESMTPSA id x13sm22228026wib.3.2013.06.17.06.49.28 for (version=SSLv3 cipher=RC4-SHA bits=128/128); Mon, 17 Jun 2013 06:49:31 -0700 (PDT) Date: Mon, 17 Jun 2013 15:49:21 +0200 From: Anisse Astier To: Ben Hutchings Cc: linux-kbuild@vger.kernel.org, debian-kernel@lists.debian.org, kernel-team@lists.ubuntu.com, Michal Marek , maximilian attems Subject: Re: [PATCH v5 1/4] deb-pkg: use KCONFIG_CONFIG instead of .config file directly Message-ID: <20130617154921.221997cd@serenity> In-Reply-To: <1371265896.3776.2.camel@deadeye.wl.decadent.org.uk> References: <1371203217-19572-1-git-send-email-anisse@astier.eu> <1371203217-19572-2-git-send-email-anisse@astier.eu> <1371265896.3776.2.camel@deadeye.wl.decadent.org.uk> X-Mailer: Claws Mail 3.8.1 (GTK+ 2.24.10; x86_64-pc-linux-gnu) Mime-Version: 1.0 X-Gm-Message-State: ALoCoQkgvXDcDpJHZjhkGEc/KuimZeSCYR4gEZSes7jkd1cGs1RpVv4fHc3hSzMCIIP8VUGaGFvM Sender: linux-kbuild-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kbuild@vger.kernel.org X-Spam-Status: No, score=-8.0 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP On Sat, 15 Jun 2013 04:11:36 +0100, Ben Hutchings wrote : > On Fri, 2013-06-14 at 11:46 +0200, Anisse Astier wrote: > > Signed-off-by: Anisse Astier > > Cc: Ben Hutchings > [...] > > @@ -245,7 +245,7 @@ fi > > # Build header package > > (cd $srctree; find . -name Makefile\* -o -name Kconfig\* -o -name \*.pl > "$objtree/debian/hdrsrcfiles") > > (cd $srctree; find arch/$SRCARCH/include include scripts -type f >> "$objtree/debian/hdrsrcfiles") > > -(cd $objtree; find arch/$SRCARCH/include .config Module.symvers include scripts -type f >> "$objtree/debian/hdrobjfiles") > > +(cd $objtree; find arch/$SRCARCH/include $KCONFIG_CONFIG Module.symvers include scripts -type f >> "$objtree/debian/hdrobjfiles") > [...] > > I think $KCONFIG_CONFIG needs to be handled specially here - it should > be installed as .config in the linux-headers package, since you can't > assume the environment variable is set when that package is used. > > Ben. > You're right. New version below. From: Anisse Astier Subject: [PATCH] deb-pkg: use KCONFIG_CONFIG instead of .config file directly Signed-off-by: Anisse Astier Cc: Ben Hutchings Reviewed-by: Ben Hutchings --- scripts/package/builddeb | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/scripts/package/builddeb b/scripts/package/builddeb index acb8650..a8662ef 100644 --- a/scripts/package/builddeb +++ b/scripts/package/builddeb @@ -41,9 +41,9 @@ create_package() { parisc*) debarch=hppa ;; mips*) - debarch=mips$(grep -q CPU_LITTLE_ENDIAN=y .config && echo el) ;; + debarch=mips$(grep -q CPU_LITTLE_ENDIAN=y $KCONFIG_CONFIG && echo el) ;; arm*) - debarch=arm$(grep -q CONFIG_AEABI=y .config && echo el) ;; + debarch=arm$(grep -q CONFIG_AEABI=y $KCONFIG_CONFIG && echo el) ;; *) echo "" >&2 echo "** ** ** WARNING ** ** **" >&2 @@ -106,12 +106,12 @@ fi if [ "$ARCH" = "um" ] ; then $MAKE linux cp System.map "$tmpdir/usr/lib/uml/modules/$version/System.map" - cp .config "$tmpdir/usr/share/doc/$packagename/config" + cp $KCONFIG_CONFIG "$tmpdir/usr/share/doc/$packagename/config" gzip "$tmpdir/usr/share/doc/$packagename/config" cp $KBUILD_IMAGE "$tmpdir/usr/bin/linux-$version" else cp System.map "$tmpdir/boot/System.map-$version" - cp .config "$tmpdir/boot/config-$version" + cp $KCONFIG_CONFIG "$tmpdir/boot/config-$version" # Not all arches include the boot path in KBUILD_IMAGE if [ -e $KBUILD_IMAGE ]; then cp $KBUILD_IMAGE "$tmpdir/boot/vmlinuz-$version" @@ -120,7 +120,7 @@ else fi fi -if grep -q '^CONFIG_MODULES=y' .config ; then +if grep -q '^CONFIG_MODULES=y' $KCONFIG_CONFIG ; then INSTALL_MOD_PATH="$tmpdir" $MAKE KBUILD_SRC= modules_install rm -f "$tmpdir/lib/modules/$version/build" rm -f "$tmpdir/lib/modules/$version/source" @@ -245,11 +245,12 @@ fi # Build header package (cd $srctree; find . -name Makefile\* -o -name Kconfig\* -o -name \*.pl > "$objtree/debian/hdrsrcfiles") (cd $srctree; find arch/$SRCARCH/include include scripts -type f >> "$objtree/debian/hdrsrcfiles") -(cd $objtree; find arch/$SRCARCH/include .config Module.symvers include scripts -type f >> "$objtree/debian/hdrobjfiles") +(cd $objtree; find arch/$SRCARCH/include Module.symvers include scripts -type f >> "$objtree/debian/hdrobjfiles") destdir=$kernel_headers_dir/usr/src/linux-headers-$version mkdir -p "$destdir" (cd $srctree; tar -c -f - -T "$objtree/debian/hdrsrcfiles") | (cd $destdir; tar -xf -) (cd $objtree; tar -c -f - -T "$objtree/debian/hdrobjfiles") | (cd $destdir; tar -xf -) +(cd $objtree; cp $KCONFIG_CONFIG $destdir/.config) # copy .config manually to be where it's expected to be ln -sf "/usr/src/linux-headers-$version" "$kernel_headers_dir/lib/modules/$version/build" rm -f "$objtree/debian/hdrsrcfiles" "$objtree/debian/hdrobjfiles" arch=$(dpkg --print-architecture)