]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
oe-setup-builddir: Keep templateconf.cfg relative if $TEMPLATECONF is
authorPeter Kjellerstedt <peter.kjellerstedt@axis.com>
Tue, 6 Sep 2022 16:43:34 +0000 (18:43 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 8 Sep 2022 13:55:51 +0000 (14:55 +0100)
Before commit 7b96dc80 (scripts/oe-setup-builddir: write to
conf/templateconf.cfg after the build is set up), the path written to
templateconf.cfg was relative if $TEMPLATECONF was relative, but
afterwards it became absolute.

Restore the original behavior of saving the relative path to
templateconf.cfg.

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
scripts/oe-setup-builddir

index f86b8e90ed0753e804928941e5c820e942cd4dc4..7136572a4d92defd8fa4a4e50ec6307b0edd3daf 100755 (executable)
@@ -46,7 +46,10 @@ fi
 
 . "$OEROOT/.templateconf"
 
-# 
+# Keep the original TEMPLATECONF before possibly prefixing it with $OEROOT below.
+ORG_TEMPLATECONF=$TEMPLATECONF
+
+#
 # $TEMPLATECONF can point to a directory for the template local.conf & bblayers.conf
 #
 if [ -n "$TEMPLATECONF" ]; then
@@ -131,5 +134,5 @@ fi
 unset OECORENOTESCONF
 
 if [ ! -f "$BUILDDIR/conf/templateconf.cfg" ]; then
-    echo "$TEMPLATECONF" >"$BUILDDIR/conf/templateconf.cfg"
+    echo "$ORG_TEMPLATECONF" >"$BUILDDIR/conf/templateconf.cfg"
 fi