games-emulation/sdlmame: improve makefile munging (bug #583044)
authorMichael Sterrett <mr_bones_@gentoo.org>
Sun, 15 May 2016 04:26:13 +0000 (00:26 -0400)
committerMichael Sterrett <mr_bones_@gentoo.org>
Sun, 15 May 2016 04:26:49 +0000 (00:26 -0400)
Package-Manager: portage-2.2.28

games-emulation/sdlmame/sdlmame-0.173.ebuild

index edac5fe3c2a3c452b555a739308b9fd4e45aa87a..0c3368e48a192377ccdb09ff6e187c52174f388c 100644 (file)
@@ -53,12 +53,12 @@ S=${WORKDIR}
 
 # Function to disable a makefile option
 disable_feature() {
-       sed -i -e "/$1.*=/s:^:# :" makefile || die
+       sed -i -e "/^[  ]*$1.*=/s:^:# :" makefile || die
 }
 
 # Function to enable a makefile option
 enable_feature() {
-       sed -i -e "/^#.*$1.*=/s:^#::"  makefile || die
+       sed -i -e "/^#.*$1.*=/s:^#[     ]*::"  makefile || die
 }
 
 pkg_setup() {