Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 498738 - www-servers/uwsgi-2.0 USE="xml json" fails because variable `xml' is assigned in a subshell
Summary: www-servers/uwsgi-2.0 USE="xml json" fails because variable `xml' is assigned...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Server (show other bugs)
Hardware: All All
: Normal normal (vote)
Assignee: Ultrabug
URL:
Whiteboard:
Keywords: PATCH
Depends on:
Blocks:
 
Reported: 2014-01-21 01:45 UTC by Zhixu Liu
Modified: 2014-01-22 17:08 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Zhixu Liu 2014-01-21 01:45:26 UTC
1. use xml && (use expat && xml="expat" || xml="libxml2" )

xml will be assigned a value in a subshell, so it's useless

2. use json && (use yajl && xml="yajl" || xml="jansson" )

typo, xml should be json

Reproducible: Always




fixed w/ following patch:

diff --git a/uwsgi-2.0.ebuild b/uwsgi-2.0.ebuild
index e2bd273..c69f4f5 100644
--- a/uwsgi-2.0.ebuild
+++ b/uwsgi-2.0.ebuild
@@ -176,8 +176,12 @@ src_configure() {
        embedded_plugins="${embedded_plugins/sqlite/sqlite3}"

        # override defaults as requested by the user
-       use xml && (use expat && xml="expat" || xml="libxml2" )
-       use json && (use yajl && xml="yajl" || xml="jansson" )
+       if use xml ; then
+               use expat && xml="expat" || xml="libxml2"
+       fi
+       if use json ; then
+               use yajl && json="yajl" || json="jansson"
+       fi
        use jemalloc && malloc_impl="jemalloc"

        # prepare the buildconf for gentoo
Comment 1 Ultrabug gentoo-dev 2014-01-22 17:08:05 UTC
Thanks a lot mate, it's fixed in tree now

+*uwsgi-2.0-r1 (22 Jan 2014)
+
+  22 Jan 2014; Ultrabug <ultrabug@gentoo.org> -uwsgi-2.0.ebuild,
+  +uwsgi-2.0-r1.ebuild:
+  Fix #498738 wrt xml and json USE flag detection thx to Zhixu Liu, rev bump
+