Skip to contentSkip to conversation

configure.ac: Fix SDL2 typo by referencing value

PATCH In review Michał Grzelak 4 participants 5 messages Jul 18, 2023 – Aug 12, 2023

lore
Share & tools
lore
#0 lore raw

cover configure.ac: Fix SDL2 typo by referencing value

Hi all,

Today I have found out that my previous commit b9b9705fb (configure.ac:
Fix typo by adding missing $) was incomplete, and I missed that the same typo occurs when configuring SDL2 with variable enable_grub_emu_sdl2. Since previous patch has already been upstreamed and thus those two patches cannot be squashed, this patch fixes the issue with SDL2.

Best regards,
Michał

Michał Grzelak (1):
configure.ac: Fix SDL2 typo by referencing value

 configure.ac | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Signature · 1 line
2.37.3
#1 lore raw

PATCH 1/1 configure.ac: Fix SDL2 typo by referencing value

During configuration of SDL2, variable enable_grub_emu_sdl2 is checked whether to throw an error message. Howerever, error could not happen because two unequal strings were compared. Fix this by referencing value of enable_grub_emu_sdl2, not name.

Fixes 17d6ac1a7 (emu: Add SDL2 support)
---
 configure.ac | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
configure.ac +1 -1
index 01500ffdf..27c5918fa 100644
@@ -1609,7 +1609,7 @@ if test "$platform" = emu; then
             AC_SUBST(HAVE_SDL2)],
             [grub_emu_sdl2_excuse="libSDL2 libraries are required to build \`grub-emu' with SDL2 support"])
   [fi]
-  if test x"enable_grub_emu_sdl2" = xyes && test x"$grub_emu_sdl2_excuse" != x ; then
+  if test x"$enable_grub_emu_sdl2" = xyes && test x"$grub_emu_sdl2_excuse" != x ; then
     AC_MSG_ERROR([SDL2 support for grub-emu was explicitly requested but can't be compiled ($grub_emu_sdl2_excuse)])
   fi
   if test x"$grub_emu_sdl2_excuse" = x ; then
Signature · 1 line
2.37.3
Reviewed-by on v1 1/1
#2 lore raw
Quoted 28 lines · Michał Grzelak

During configuration of SDL2, variable enable_grub_emu_sdl2 is checked whether to throw an error message. Howerever, error could not happen because two unequal strings were compared. Fix this by referencing value of enable_grub_emu_sdl2, not name.

Fixes 17d6ac1a7 (emu: Add SDL2 support)
---
 configure.ac | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
configure.ac +1 -1
index 01500ffdf..27c5918fa 100644
@@ -1609,7 +1609,7 @@ if test "$platform" = emu; then
             AC_SUBST(HAVE_SDL2)],
             [grub_emu_sdl2_excuse="libSDL2 libraries are required to build \`grub-emu' with SDL2 support"])
   [fi]
-  if test x"enable_grub_emu_sdl2" = xyes && test x"$grub_emu_sdl2_excuse" != x ; then
+  if test x"$enable_grub_emu_sdl2" = xyes && test x"$grub_emu_sdl2_excuse" != x ; then
     AC_MSG_ERROR([SDL2 support for grub-emu was explicitly requested but can't be compiled ($grub_emu_sdl2_excuse)])
   fi
   if test x"$grub_emu_sdl2_excuse" = x ; then
Signature · 1 line
2.37.3
Signature · 2 lines
debian developer - deb.li/jak | jak-linux.org - free software dev
ubuntu core developer                              i speak de, en
Reviewed-by
#3 lore raw
Quoted 23 lines · Julian Andres Klode
Quoted 22 lines · Michał Grzelak

During configuration of SDL2, variable enable_grub_emu_sdl2 is checked whether to throw an error message. Howerever, error could not happen because two unequal strings were compared. Fix this by referencing value of enable_grub_emu_sdl2, not name.

Fixes 17d6ac1a7 (emu: Add SDL2 support)
---
 configure.ac | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
configure.ac +1 -1
index 01500ffdf..27c5918fa 100644
@@ -1609,7 +1609,7 @@ if test "$platform" = emu; then
             AC_SUBST(HAVE_SDL2)],
             [grub_emu_sdl2_excuse="libSDL2 libraries are required to build \`grub-emu' with SDL2 support"])
   [fi]
-  if test x"enable_grub_emu_sdl2" = xyes && test x"$grub_emu_sdl2_excuse" != x ; then
+  if test x"$enable_grub_emu_sdl2" = xyes && test x"$grub_emu_sdl2_excuse" != x ; then
Quoted 8 lines
Quoted 6 lines
configure.ac +0 -1
     AC_MSG_ERROR([SDL2 support for grub-emu was explicitly requested but can't be compiled ($grub_emu_sdl2_excuse)])
   fi
   if test x"$grub_emu_sdl2_excuse" = x ; then
--

2.37.3

Daniel

_______________________________________________
Grub-devel mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/grub-devel

Reviewed-by on v1 1/1
#4 lore raw
In reply to Michał Grzelak

Dear Michał,

Thank you for your patch.

Am 19.07.23 um 00:48 schrieb Michał Grzelak:

Quoted 2 lines

During configuration of SDL2, variable enable_grub_emu_sdl2 is checked whether to throw an error message. Howerever, error could not happen

However

Quoted 15 lines

because two unequal strings were compared. Fix this by referencing value of enable_grub_emu_sdl2, not name.

Fixes 17d6ac1a7 (emu: Add SDL2 support)
---
  configure.ac | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
configure.ac +0 -0
index 01500ffdf..27c5918fa 100644

configure.ac if test "$platform" = emu; then · line 1615

Quoted 8 lines
configure.ac +1 -1
@@ -1609,7 +1609,7 @@ if test "$platform" = emu; then
              AC_SUBST(HAVE_SDL2)],
              [grub_emu_sdl2_excuse="libSDL2 libraries are required to build \`grub-emu' with SDL2 support"])
    [fi]
-  if test x"enable_grub_emu_sdl2" = xyes && test x"$grub_emu_sdl2_excuse" != x ; then
+  if test x"$enable_grub_emu_sdl2" = xyes && test x"$grub_emu_sdl2_excuse" != x ; then
      AC_MSG_ERROR([SDL2 support for grub-emu was explicitly requested but can't be compiled ($grub_emu_sdl2_excuse)])
    fi
    if test x"$grub_emu_sdl2_excuse" = x ; then

Kind regards,

Paul

_______________________________________________
Grub-devel mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/grub-devel