diff mbox

[v10,1/8] package: add base dependency to every package

Message ID 1387363007-19846-2-git-send-email-fabio.porcedda@gmail.com
State Superseded
Headers show

Commit Message

Fabio Porcedda Dec. 18, 2013, 10:36 a.m. UTC
Move "dependencies" "dirs" "prepare" dependencies from "toolchain" to
every package.
This way we can build correctly every package right after the clean
stage.
As example with this commit we can build successfully the glibc right
after the clean stage:
	make clean glibc

This is also a step forward supporting top-level parallel make.

Signed-off-by: Fabio Porcedda <fabio.porcedda@gmail.com>
Acked-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
---
 package/pkg-generic.mk           | 5 +++++
 toolchain/toolchain/toolchain.mk | 3 +--
 2 files changed, 6 insertions(+), 2 deletions(-)

Comments

Arnout Vandecappelle Jan. 9, 2014, 5:30 p.m. UTC | #1
On 18/12/13 11:36, Fabio Porcedda wrote:
> Move "dependencies" "dirs" "prepare" dependencies from "toolchain" to
> every package.
> This way we can build correctly every package right after the clean
> stage.
> As example with this commit we can build successfully the glibc right
> after the clean stage:
> 	make clean glibc
>
> This is also a step forward supporting top-level parallel make.
>
> Signed-off-by: Fabio Porcedda<fabio.porcedda@gmail.com>
> Acked-by: Arnout Vandecappelle (Essensium/Mind)<arnout@mind.be>

  Peter,

  This one is fixing a problem reported by a user and has already gone 
through 10 iterations. Can it be committed?

  Regards,
  Arnout
Fabio Porcedda Jan. 10, 2014, 10:28 a.m. UTC | #2
On Thu, Jan 9, 2014 at 6:30 PM, Arnout Vandecappelle <arnout@mind.be> wrote:
> On 18/12/13 11:36, Fabio Porcedda wrote:
>>
>> Move "dependencies" "dirs" "prepare" dependencies from "toolchain" to
>> every package.
>> This way we can build correctly every package right after the clean
>> stage.
>> As example with this commit we can build successfully the glibc right
>> after the clean stage:
>>         make clean glibc
>>
>> This is also a step forward supporting top-level parallel make.
>>
>> Signed-off-by: Fabio Porcedda<fabio.porcedda@gmail.com>
>> Acked-by: Arnout Vandecappelle (Essensium/Mind)<arnout@mind.be>
>
>
>  Peter,
>
>  This one is fixing a problem reported by a user and has already gone
> through 10 iterations. Can it be committed?

I've sent a rebased version, so now are 11 iterations...

Best regards
diff mbox

Patch

diff --git a/package/pkg-generic.mk b/package/pkg-generic.mk
index 45b808a..668c7da 100644
--- a/package/pkg-generic.mk
+++ b/package/pkg-generic.mk
@@ -426,6 +426,11 @@  $(1)-install-host:      $(1)-build $$($(2)_TARGET_INSTALL_HOST)
 $(1)-build:		$(1)-configure \
 			$$($(2)_TARGET_BUILD)
 
+$$($(2)_TARGET_SOURCE) $$($(2)_TARGET_RSYNC): | dirs prepare
+ifeq ($(filter $(1),$(DEPENDENCIES_HOST_PREREQ)),)
+$$($(2)_TARGET_SOURCE) $$($(2)_TARGET_RSYNC): | dependencies
+endif
+
 ifeq ($$($(2)_OVERRIDE_SRCDIR),)
 # In the normal case (no package override), the sequence of steps is
 #  source, by downloading
diff --git a/toolchain/toolchain/toolchain.mk b/toolchain/toolchain/toolchain.mk
index 44ed629..8559ac9 100644
--- a/toolchain/toolchain/toolchain.mk
+++ b/toolchain/toolchain/toolchain.mk
@@ -14,5 +14,4 @@  endif
 
 $(eval $(generic-package))
 
-toolchain-source: prepare dirs dependencies $(HOST_DIR)/usr/share/buildroot/toolchainfile.cmake
-
+toolchain: $(HOST_DIR)/usr/share/buildroot/toolchainfile.cmake