From patchwork Fri Aug 14 09:58:42 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?UTF-8?q?No=C3=A9=20Rubinstein?= X-Patchwork-Id: 507331 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ozlabs.org (Postfix) with ESMTP id 96D04140216 for ; Fri, 14 Aug 2015 19:58:57 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b=HQQ00gSC; dkim-atps=neutral Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id D840692D90; Fri, 14 Aug 2015 09:58:55 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id OJT-gZBLkSmB; Fri, 14 Aug 2015 09:58:54 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by whitealder.osuosl.org (Postfix) with ESMTP id 96E7992D91; Fri, 14 Aug 2015 09:58:54 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id 1D9B71C107C for ; Fri, 14 Aug 2015 09:58:53 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id 1A83F96855 for ; Fri, 14 Aug 2015 09:58:53 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 5gH0Gs6AvnqV for ; Fri, 14 Aug 2015 09:58:52 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wi0-f169.google.com (mail-wi0-f169.google.com [209.85.212.169]) by hemlock.osuosl.org (Postfix) with ESMTPS id 3BAE29684A for ; Fri, 14 Aug 2015 09:58:52 +0000 (UTC) Received: by wijp15 with SMTP id p15so14019554wij.0 for ; Fri, 14 Aug 2015 02:58:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:mime-version:content-type :content-transfer-encoding; bh=3I3cbixT8qpkdETfhOkLGuMm+X5hfs3cXzMJpMG0iMs=; b=HQQ00gSCLKlgKAkTFmiCLEwTGR/zWXOwnk98DE+4bZB0UNTyp4Zg/X5Ujn2Tnj588E 03ID5/AehlrkXw6kIYN+DurMN6M5UjevaibVsMfUH91JLoOmMMJO4GiV6HYdfV+NfpIg u8SCN5XyWDOlQjOG0SnAtWPdq3zHOxMvAKPM8EFx16cZtx8adFCrHBcIMpm+DXJBy76T ubcRzDuvUijAkbCXpvkprvsm9Q3AhhzZK9TPWjG9agpWQhI00J83/qZMhw114R87oW31 VTEQyKSTRJaW82htNp6FtqpfCo9JNZvKpgea+VJ6Yub+P/+OORpA4ZcmltQt+hri9s2V MQQA== X-Received: by 10.180.184.168 with SMTP id ev8mr5350575wic.28.1439546330599; Fri, 14 Aug 2015 02:58:50 -0700 (PDT) Received: from nrubinstein-de.aldebaran.lan ([195.190.86.18]) by smtp.gmail.com with ESMTPSA id o9sm7403897wja.29.2015.08.14.02.58.49 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 14 Aug 2015 02:58:49 -0700 (PDT) From: "=?UTF-8?q?No=C3=A9=20Rubinstein?=" X-Google-Original-From: =?UTF-8?q?No=C3=A9=20Rubinstein?= To: buildroot@uclibc.org Date: Fri, 14 Aug 2015 11:58:42 +0200 Message-Id: <1439546322-21504-1-git-send-email-nrubinstein@aldebaran.com> X-Mailer: git-send-email 2.1.4 MIME-Version: 1.0 Subject: [Buildroot] [PATCH] pkg-kernel-module: Die when kernel modules are disabled X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" Test the config of the kernel to see if loadable module support is enabled, and error out otherwise. This makes the build failure less confusing. Signed-off-by: NoƩ Rubinstein --- package/pkg-kernel-module.mk | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/package/pkg-kernel-module.mk b/package/pkg-kernel-module.mk index 5fb19be..e7dc33e 100644 --- a/package/pkg-kernel-module.mk +++ b/package/pkg-kernel-module.mk @@ -60,6 +60,10 @@ $(2)_MODULE_SUBDIRS ?= . # includes and other support files (Booo!) define $(2)_KERNEL_MODULES_BUILD @$$(call MESSAGE,"Building kernel module(s)") + @if ! grep -Fqx 'CONFIG_MODULES=y' $(LINUX_DIR)/.config; then \ + echo ERROR: Kernel does not support loadable modules; \ + false; \ + fi $$(foreach d,$$($(2)_MODULE_SUBDIRS), \ $$(LINUX_MAKE_ENV) $$($$(PKG)_MAKE) \ -C $$(LINUX_DIR) \