* [PATCH] rpm: fix races over rpmqv.c in parallel builds
@ 2016-03-07 20:11 Ross Burton
2016-03-07 21:00 ` Mark Hatle
0 siblings, 1 reply; 3+ messages in thread
From: Ross Burton @ 2016-03-07 20:11 UTC (permalink / raw)
To: openembedded-core
Signed-off-by: Ross Burton <ross.burton@intel.com>
---
.../recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch | 37 +++++++++++++++-------
1 file changed, 25 insertions(+), 12 deletions(-)
diff --git a/meta/recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch b/meta/recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch
index b3c14fd..b2437a8 100644
--- a/meta/recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch
+++ b/meta/recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch
@@ -1,4 +1,7 @@
-rpm: compile rpmqv.c instead of rpmqv.cc
+From e8bae261615e19ff8a28683765c9539cfb22a086 Mon Sep 17 00:00:00 2001
+From: Joe Slater <jslater@windriver.com>
+Date: Thu, 17 Jul 2014 18:14:54 -0700
+Subject: [PATCH 1/9] rpm: compile rpmqv.c instead of rpmqv.cc
Some versions of gcc, 4.4.5 for example, will put a reference to __gxx_personality_v0
into rpm.o and rpmbuild.o. This means we must link with g++, and the Makefile we
@@ -10,28 +13,38 @@ Upstream-Status: Inappropriate [other]
When linking with g++ is really necessary, the upstream package will do that.
+Also instead of symlinking files in two places, which can and does race in
+parallel builds, simply refer to the file's full location [RB]
+
Signed-off-by: Joe Slater <joe.slater@windriver.com>
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+---
+ Makefile.am | 6 ++----
+ 1 file changed, 2 insertions(+), 4 deletions(-)
-Index: rpm/Makefile.am
-===================================================================
---- rpm.orig/Makefile.am
-+++ rpm/Makefile.am
-@@ -202,14 +202,16 @@ rpm_LDFLAGS = @LDFLAGS_STATIC@ $(LDFLAG
+diff --git a/Makefile.am b/Makefile.am
+index 1dade0a..55f8669 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -201,15 +201,13 @@ rpm_SOURCES = build.c
+ rpm_LDFLAGS = @LDFLAGS_STATIC@ $(LDFLAGS)
rpm_LDADD = rpm.o $(myLDADD)
rpm.o: $(top_srcdir)/rpmqv.c
- ln -sf $< rpmqv.cc
-+ ln -sf $< rpmqv.c
+- ln -sf $< rpmqv.cc
- $(COMPILE) -DIAM_RPMBT -DIAM_RPMDB -DIAM_RPMEIU -DIAM_RPMK -DIAM_RPMQV -o $@ -c rpmqv.cc
-+ $(COMPILE) -DIAM_RPMBT -DIAM_RPMDB -DIAM_RPMEIU -DIAM_RPMK -DIAM_RPMQV -o $@ -c rpmqv.c
++ $(COMPILE) -DIAM_RPMBT -DIAM_RPMDB -DIAM_RPMEIU -DIAM_RPMK -DIAM_RPMQV -o $@ -c $^
rpmbuild_SOURCES = build.c
rpmbuild_LDFLAGS = @LDFLAGS_STATIC@ $(LDFLAGS)
rpmbuild_LDADD = rpmbuild.o $(myLDADD)
rpmbuild.o: $(top_srcdir)/rpmqv.c
- ln -sf $< rpmqv.cc
-+ ln -sf $< rpmqv.c
+- ln -sf $< rpmqv.cc
- $(COMPILE) -DIAM_RPMBT -o $@ -c rpmqv.cc
-+ $(COMPILE) -DIAM_RPMBT -o $@ -c rpmqv.c
++ $(COMPILE) -DIAM_RPMBT -o $@ -c $^
.syntastic_c_config: Makefile
@echo $(COMPILE) | tr ' ' '\n' | sed -e '1d' > $@
+--
+2.7.0
+
--
2.7.0
^ permalink raw reply related [flat|nested] 3+ messages in thread* Re: [PATCH] rpm: fix races over rpmqv.c in parallel builds
2016-03-07 20:11 [PATCH] rpm: fix races over rpmqv.c in parallel builds Ross Burton
@ 2016-03-07 21:00 ` Mark Hatle
0 siblings, 0 replies; 3+ messages in thread
From: Mark Hatle @ 2016-03-07 21:00 UTC (permalink / raw)
To: Ross Burton, openembedded-core
On 3/7/16 2:11 PM, Ross Burton wrote:
> Signed-off-by: Ross Burton <ross.burton@intel.com>
Tested and it works.
If I need to spin a V6, I'll include this -- otherwise it should be added on
it's own.
--Mark
> ---
> .../recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch | 37 +++++++++++++++-------
> 1 file changed, 25 insertions(+), 12 deletions(-)
>
> diff --git a/meta/recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch b/meta/recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch
> index b3c14fd..b2437a8 100644
> --- a/meta/recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch
> +++ b/meta/recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch
> @@ -1,4 +1,7 @@
> -rpm: compile rpmqv.c instead of rpmqv.cc
> +From e8bae261615e19ff8a28683765c9539cfb22a086 Mon Sep 17 00:00:00 2001
> +From: Joe Slater <jslater@windriver.com>
> +Date: Thu, 17 Jul 2014 18:14:54 -0700
> +Subject: [PATCH 1/9] rpm: compile rpmqv.c instead of rpmqv.cc
>
> Some versions of gcc, 4.4.5 for example, will put a reference to __gxx_personality_v0
> into rpm.o and rpmbuild.o. This means we must link with g++, and the Makefile we
> @@ -10,28 +13,38 @@ Upstream-Status: Inappropriate [other]
>
> When linking with g++ is really necessary, the upstream package will do that.
>
> +Also instead of symlinking files in two places, which can and does race in
> +parallel builds, simply refer to the file's full location [RB]
> +
> Signed-off-by: Joe Slater <joe.slater@windriver.com>
> +Signed-off-by: Ross Burton <ross.burton@intel.com>
> +
> +---
> + Makefile.am | 6 ++----
> + 1 file changed, 2 insertions(+), 4 deletions(-)
>
> -Index: rpm/Makefile.am
> -===================================================================
> ---- rpm.orig/Makefile.am
> -+++ rpm/Makefile.am
> -@@ -202,14 +202,16 @@ rpm_LDFLAGS = @LDFLAGS_STATIC@ $(LDFLAG
> +diff --git a/Makefile.am b/Makefile.am
> +index 1dade0a..55f8669 100644
> +--- a/Makefile.am
> ++++ b/Makefile.am
> +@@ -201,15 +201,13 @@ rpm_SOURCES = build.c
> + rpm_LDFLAGS = @LDFLAGS_STATIC@ $(LDFLAGS)
> rpm_LDADD = rpm.o $(myLDADD)
> rpm.o: $(top_srcdir)/rpmqv.c
> - ln -sf $< rpmqv.cc
> -+ ln -sf $< rpmqv.c
> +- ln -sf $< rpmqv.cc
> - $(COMPILE) -DIAM_RPMBT -DIAM_RPMDB -DIAM_RPMEIU -DIAM_RPMK -DIAM_RPMQV -o $@ -c rpmqv.cc
> -+ $(COMPILE) -DIAM_RPMBT -DIAM_RPMDB -DIAM_RPMEIU -DIAM_RPMK -DIAM_RPMQV -o $@ -c rpmqv.c
> ++ $(COMPILE) -DIAM_RPMBT -DIAM_RPMDB -DIAM_RPMEIU -DIAM_RPMK -DIAM_RPMQV -o $@ -c $^
>
> rpmbuild_SOURCES = build.c
> rpmbuild_LDFLAGS = @LDFLAGS_STATIC@ $(LDFLAGS)
> rpmbuild_LDADD = rpmbuild.o $(myLDADD)
> rpmbuild.o: $(top_srcdir)/rpmqv.c
> - ln -sf $< rpmqv.cc
> -+ ln -sf $< rpmqv.c
> +- ln -sf $< rpmqv.cc
> - $(COMPILE) -DIAM_RPMBT -o $@ -c rpmqv.cc
> -+ $(COMPILE) -DIAM_RPMBT -o $@ -c rpmqv.c
> ++ $(COMPILE) -DIAM_RPMBT -o $@ -c $^
>
> .syntastic_c_config: Makefile
> @echo $(COMPILE) | tr ' ' '\n' | sed -e '1d' > $@
> +--
> +2.7.0
> +
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH] rpm: fix races over rpmqv.c in parallel builds
@ 2016-03-01 13:00 Ross Burton
0 siblings, 0 replies; 3+ messages in thread
From: Ross Burton @ 2016-03-01 13:00 UTC (permalink / raw)
To: openembedded-core
Signed-off-by: Ross Burton <ross.burton@intel.com>
---
.../recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch | 37 +++++++++++++++-------
1 file changed, 25 insertions(+), 12 deletions(-)
diff --git a/meta/recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch b/meta/recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch
index b3c14fd..b2437a8 100644
--- a/meta/recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch
+++ b/meta/recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch
@@ -1,4 +1,7 @@
-rpm: compile rpmqv.c instead of rpmqv.cc
+From e8bae261615e19ff8a28683765c9539cfb22a086 Mon Sep 17 00:00:00 2001
+From: Joe Slater <jslater@windriver.com>
+Date: Thu, 17 Jul 2014 18:14:54 -0700
+Subject: [PATCH 1/9] rpm: compile rpmqv.c instead of rpmqv.cc
Some versions of gcc, 4.4.5 for example, will put a reference to __gxx_personality_v0
into rpm.o and rpmbuild.o. This means we must link with g++, and the Makefile we
@@ -10,28 +13,38 @@ Upstream-Status: Inappropriate [other]
When linking with g++ is really necessary, the upstream package will do that.
+Also instead of symlinking files in two places, which can and does race in
+parallel builds, simply refer to the file's full location [RB]
+
Signed-off-by: Joe Slater <joe.slater@windriver.com>
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+---
+ Makefile.am | 6 ++----
+ 1 file changed, 2 insertions(+), 4 deletions(-)
-Index: rpm/Makefile.am
-===================================================================
---- rpm.orig/Makefile.am
-+++ rpm/Makefile.am
-@@ -202,14 +202,16 @@ rpm_LDFLAGS = @LDFLAGS_STATIC@ $(LDFLAG
+diff --git a/Makefile.am b/Makefile.am
+index 1dade0a..55f8669 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -201,15 +201,13 @@ rpm_SOURCES = build.c
+ rpm_LDFLAGS = @LDFLAGS_STATIC@ $(LDFLAGS)
rpm_LDADD = rpm.o $(myLDADD)
rpm.o: $(top_srcdir)/rpmqv.c
- ln -sf $< rpmqv.cc
-+ ln -sf $< rpmqv.c
+- ln -sf $< rpmqv.cc
- $(COMPILE) -DIAM_RPMBT -DIAM_RPMDB -DIAM_RPMEIU -DIAM_RPMK -DIAM_RPMQV -o $@ -c rpmqv.cc
-+ $(COMPILE) -DIAM_RPMBT -DIAM_RPMDB -DIAM_RPMEIU -DIAM_RPMK -DIAM_RPMQV -o $@ -c rpmqv.c
++ $(COMPILE) -DIAM_RPMBT -DIAM_RPMDB -DIAM_RPMEIU -DIAM_RPMK -DIAM_RPMQV -o $@ -c $^
rpmbuild_SOURCES = build.c
rpmbuild_LDFLAGS = @LDFLAGS_STATIC@ $(LDFLAGS)
rpmbuild_LDADD = rpmbuild.o $(myLDADD)
rpmbuild.o: $(top_srcdir)/rpmqv.c
- ln -sf $< rpmqv.cc
-+ ln -sf $< rpmqv.c
+- ln -sf $< rpmqv.cc
- $(COMPILE) -DIAM_RPMBT -o $@ -c rpmqv.cc
-+ $(COMPILE) -DIAM_RPMBT -o $@ -c rpmqv.c
++ $(COMPILE) -DIAM_RPMBT -o $@ -c $^
.syntastic_c_config: Makefile
@echo $(COMPILE) | tr ' ' '\n' | sed -e '1d' > $@
+--
+2.7.0
+
--
2.7.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2016-03-07 21:00 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-03-07 20:11 [PATCH] rpm: fix races over rpmqv.c in parallel builds Ross Burton
2016-03-07 21:00 ` Mark Hatle
-- strict thread matches above, loose matches on Subject: below --
2016-03-01 13:00 Ross Burton
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox