Skip to contentSkip to conversation

opkg: Fix error when recompiled

PATCH In review Gary Thomas 3 participants 4 messages Mar 5, 2015 – Mar 6, 2015

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 opkg: Fix error when recompiled

If this package were ever recompiled, i.e. do_compile is rerun
as a result of a compiler change, etc., the 'opkg.conf' file
would be incorrectly updated, leading to an error:
* opkg_conf_set_option: Duplicate option lists_dir, using first seen value "/var/lib/opkg".

v2: Move the update of the opkg.conf file into 'do_install' which will prevent any erroneous [multiple] options to be added to 'opkg.conf'

---
 meta/recipes-devtools/opkg/opkg_0.2.4.bb | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)
meta/recipes-devtools/opkg/opkg_0.2.4.bb +1 -4
index 8455eac..447f3f6 100644
@@ -47,13 +47,10 @@ do_configure_prepend() {
 	sed -i -e s:-Werror::g ${S}/libopkg/Makefile.am
 }
 
-do_compile_append () {
-	echo "option lists_dir ${OPKGLIBDIR}/opkg" >>${WORKDIR}/opkg.conf
-}
-
 do_install_append () {
 	install -d ${D}${sysconfdir}/opkg
 	install -m 0644 ${WORKDIR}/opkg.conf ${D}${sysconfdir}/opkg/opkg.conf
+	echo "option lists_dir ${OPKGLIBDIR}/opkg" >>${D}${sysconfdir}/opkg/opkg.conf
 
 	# We need to create the lock directory
 	install -d ${D}${OPKGLIBDIR}/opkg
Signature · 1 line
1.9.1
#1 lore raw

Hi Gary,

Quoted 3 lines · Gary Thomas

v2: Move the update of the opkg.conf file into 'do_install' which will prevent any erroneous [multiple] options to be added to 'opkg.conf'

Don't put commentary about v2 in the commit message, as when it's merged the content of v1 isn't relevant.

(I've removed it and merged to mut)

Ross

#2 lore raw
Quoted 9 lines · Ross

Hi Gary,

On 5 March 2015 at 15:48, Gary Thomas <[email protected] <mailto:[email protected]>> wrote:

v2: Move the update of the opkg.conf file into 'do_install' which will prevent any erroneous [multiple] options to be added to 'opkg.conf'

Don't put commentary about v2 in the commit message, as when it's merged the content of v1 isn't relevant.

Noted.

Quoted 1 line

(I've removed it and merged to mut)

Thanks

Signature · 4 lines
------------------------------------------------------------
Gary Thomas                 |  Consulting for the
MLB Associates              |    Embedded world
------------------------------------------------------------
#3 lore raw
Quoted 9 lines · Gary Thomas
Quoted 6 lines · Ross

On 5 March 2015 at 15:48, Gary Thomas <[email protected] <mailto:[email protected]>> wrote:

v2: Move the update of the opkg.conf file into 'do_install' which will prevent any erroneous [multiple] options to be added to 'opkg.conf'

Quoted 4 lines
Quoted 2 lines

Don't put commentary about v2 in the commit message, as when it's merged the content of v1 isn't relevant.

Noted.

But for single patches, please keep it in the e-mail by putting it below the first --- line. I.e. just before the list of all changed files.

It's really nice to see a changelog together with a v2, v3, v... patch.

Cheers,
Anders

Signature · 2 lines
Anders Darander
ChargeStorm AB / eStorm AB