File make-testall.patch of Package ufoai

From: Alexey Svistunov <svalx@svalx.net>
Date: 2025-04-29 11:11:27 +0300
Subject: fix testing error when ufo2map is not built yet
References:
Upstream: submitted

During testing, the ufo2map utility is needed to build maps,
but in the Makefile dependencies it is specified in parallel
and its call occurs before its building.

Index: code/build/modules/testall.mk
===================================================================
--- code.orig/build/modules/testall.mk
+++ code/build/modules/testall.mk
@@ -134,11 +134,11 @@ $(TARGET)_SRCS = $(sort $($(TARGET)_SRCS
 
 TESTMAPSRC := $(wildcard unittest/maps/*.map)
 TESTBSPS := $(TESTMAPSRC:.map=.bsp)
-$(TESTBSPS): %.bsp: %.map
+$(TESTBSPS): %.bsp: %.map ufo2map
 	./$(UFO2MAP)$(EXE_EXT) -gamedir unittest $(UFO2MAPFLAGS) $(<:unittest/%=%)
 
 $(TARGET)_OBJS     := $(call ASSEMBLE_OBJECTS,$(TARGET))
 $(TARGET)_CXXFLAGS := $($(TARGET)_CFLAGS)
 $(TARGET)_CCFLAGS  := $($(TARGET)_CFLAGS)
 
-testall: ufo2map unittest/maps/test_routing.bsp unittest/maps/test_game.bsp
+testall: unittest/maps/test_routing.bsp unittest/maps/test_game.bsp
openSUSE Build Service is sponsored by