From patchwork Fri Oct 25 12:15:20 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gustavo Zacarias X-Patchwork-Id: 286132 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from fraxinus.osuosl.org (fraxinus.osuosl.org [140.211.166.137]) by ozlabs.org (Postfix) with ESMTP id A68672C00CC for ; Fri, 25 Oct 2013 23:15:51 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id D88E68BD5D; Fri, 25 Oct 2013 12:15:50 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id kTiVImLM5kRY; Fri, 25 Oct 2013 12:15:49 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id 2955F8BD38; Fri, 25 Oct 2013 12:15:49 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (whitealder.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id BDAAB1BFA35 for ; Fri, 25 Oct 2013 12:15:47 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id B80938CE25 for ; Fri, 25 Oct 2013 12:15:47 +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 xQ+td94suHZn for ; Fri, 25 Oct 2013 12:15:47 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from loknar.toptech.com.ar (loknar.toptech.com.ar [78.46.79.162]) by whitealder.osuosl.org (Postfix) with ESMTPS id CF3F08CDE6 for ; Fri, 25 Oct 2013 12:15:46 +0000 (UTC) Received: from asgard (host58.190-231-106.telecom.net.ar [190.231.106.58]) (authenticated bits=0) by loknar.toptech.com.ar (8.14.7/8.14.7) with ESMTP id r9PCFe8l029974 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Fri, 25 Oct 2013 12:15:42 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=zacarias.com.ar; s=dkey; t=1382703344; bh=nps0lx+NiMVqBv8ON/I6oJCbL22ly5M8Y5PWqQL4mPs=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=NiD7zdPUs9FboR3pIGJP1GWbWpV86EVaCM/vyJAKL191wPg0XsZqXmMbso+gjB3VA MrWTJArPVn/qciebyw11MTDN8w9nD9hii0ORB03Ca5mTJQ64twGBYXyRH8KqysuYx8 wJq/LsbNd2s+4kuIuFcN+9gGS5pcI1F3ARQQUZBg= Received: by asgard (sSMTP sendmail emulation); Fri, 25 Oct 2013 09:15:34 -0300 From: Gustavo Zacarias To: buildroot@busybox.net Date: Fri, 25 Oct 2013 09:15:20 -0300 Message-Id: <1382703323-31038-2-git-send-email-gustavo@zacarias.com.ar> X-Mailer: git-send-email 1.8.1.5 In-Reply-To: <1382703323-31038-1-git-send-email-gustavo@zacarias.com.ar> References: <1382703323-31038-1-git-send-email-gustavo@zacarias.com.ar> X-Virus-Scanned: clamav-milter 0.97.8 at loknar X-Virus-Status: Clean Subject: [Buildroot] [PATCH 2/5] boost: add host variant X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: buildroot-bounces@busybox.net Signed-off-by: Gustavo Zacarias --- package/boost/boost.mk | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/package/boost/boost.mk b/package/boost/boost.mk index b0b3352..8a1a8f7 100644 --- a/package/boost/boost.mk +++ b/package/boost/boost.mk @@ -11,11 +11,19 @@ BOOST_SITE = http://downloads.sourceforge.net/project/boost/boost/$(BOOST_VERSIO BOOST_INSTALL_STAGING = YES TARGET_CC_VERSION = $(shell $(TARGET_CC) -dumpversion) +HOST_CC_VERSION = $(shell $(HOSTCC) -dumpversion) BOOST_DEPENDENCIES = BOOST_FLAGS = +# keep host variant as minimal as possible +HOST_BOOST_FLAGS = --without-icu \ + --without-libraries=$(subst $(space),$(comma),atomic chrono context \ + coroutine date_time exception filesystem graph graph_parallel \ + iostreams locale log math mpi program_options python random regex \ + serialization signals system test thread timer wave) + # atomic library compile only with upstream version, wait for next release # coroutine breaks on some weak toolchains and it's new for 1.54+ # log breaks with some toolchain combinations and it's new for 1.54+ @@ -54,6 +62,9 @@ ifeq ($(BR2_PACKAGE_BOOST_IOSTREAMS),y) BOOST_DEPENDENCIES += bzip2 zlib endif +HOST_BOOST_OPT += toolset=gcc threading=multi variant=release link=shared \ + runtime-link=shared + BOOST_OPT += toolset=gcc \ threading=multi \ variant=$(if $(BR2_ENABLE_DEBUG),debug,release) \ @@ -78,6 +89,12 @@ define BOOST_CONFIGURE_CMDS echo "" >> $(@D)/user-config.jam endef +define HOST_BOOST_CONFIGURE_CMDS + (cd $(@D) && ./bootstrap.sh $(HOST_BOOST_FLAGS)) + echo "using gcc : $(HOST_CC_VERSION) : $(HOSTCXX) : \"$(HOST_CXXFLAGS)\" \"$(HOST_LDFLAGS)\" ;" > $(@D)/user-config.jam + echo "" >> $(@D)/user-config.jam +endef + define BOOST_INSTALL_TARGET_CMDS (cd $(@D) && ./b2 -j$(PARALLEL_JOBS) -q -d+1 \ --user-config=$(@D)/user-config.jam \ @@ -86,6 +103,21 @@ define BOOST_INSTALL_TARGET_CMDS --layout=system install ) endef +define HOST_BOOST_BUILD_CMDS + (cd $(@D) && ./b2 -j$(PARALLEL_JOBS) -q -d+1 \ + --user-config=$(@D)/user-config.jam \ + $(HOST_BOOST_OPT) \ + --prefix=$(HOST_DIR)/usr ) +endef + +define HOST_BOOST_INSTALL_CMDS + (cd $(@D) && ./b2 -j$(PARALLEL_JOBS) -q -d+1 \ + --user-config=$(@D)/user-config.jam \ + $(HOST_BOOST_OPT) \ + --prefix=$(HOST_DIR)/usr \ + --layout=system install ) +endef + define BOOST_INSTALL_STAGING_CMDS (cd $(@D) && ./bjam -j$(PARALLEL_JOBS) -d+1 \ --user-config=$(@D)/user-config.jam \ @@ -95,3 +127,4 @@ define BOOST_INSTALL_STAGING_CMDS endef $(eval $(generic-package)) +$(eval $(host-autotools-package))