app-arch/unp: fix compilation without LINGUAS variable
authorHanno <hanno@gentoo.org>
Sat, 15 Oct 2016 17:20:07 +0000 (19:20 +0200)
committerHanno <hanno@gentoo.org>
Sat, 15 Oct 2016 17:20:07 +0000 (19:20 +0200)
Fixes bug #597198.

Package-Manager: portage-2.3.2

app-arch/unp/unp-2.0_pre7_p1-r1.ebuild

index 1194f7d9dc8980bac28eb573f59961fff30cffbf..97b3db7941e5165f032713f744a9bf8fa2e9ba8c 100644 (file)
@@ -28,7 +28,11 @@ PATCHES=( "${FILESDIR}/${P}-remove-deprecated-have.diff" )
 src_compile() {
        if use nls; then
                strip-linguas -i .
-               emake -C po MOFILES="${LINGUAS// /.po }.po"
+               if [ -n "$LINGUAS" ]; then
+                       emake -C po MOFILES="${LINGUAS// /.po }.po"
+               else
+                       emake -C po
+               fi
        fi
 }
 
@@ -40,6 +44,10 @@ src_install() {
        dobashcomp bash_completion.d/unp
 
        if use nls; then
-               emake -C po MOFILES="${LINGUAS// /.mo }.mo" DESTDIR="${D}" install
+               if [ -n "$LINGUAS" ]; then
+                       emake -C po MOFILES="${LINGUAS// /.mo }.mo" DESTDIR="${D}" install
+               else
+                       emake -C po DESTDIR="${D}" install
+               fi
        fi
 }