Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package gnustep-make for openSUSE:Factory checked in at 2023-01-07 17:17:39 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/gnustep-make (Old) and /work/SRC/openSUSE:Factory/.gnustep-make.new.1563 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "gnustep-make" Sat Jan 7 17:17:39 2023 rev:6 rq:1056701 version:2.9.1 Changes: -------- --- /work/SRC/openSUSE:Factory/gnustep-make/gnustep-make.changes 2022-06-28 15:21:26.925859673 +0200 +++ /work/SRC/openSUSE:Factory/.gnustep-make.new.1563/gnustep-make.changes 2023-01-07 17:19:27.906066727 +0100 @@ -1,0 +2,7 @@ +Fri Jan 6 19:41:18 UTC 2023 - Fred kiefer <fredkie...@gmx.de> + +- update to version 2.9.1 + * Add workaround for Clang bug on Windows MSVC when tests contain no Objective-C constructs. + * Various fixes for minor issues introduced in the test framework by parallelisation mof testcase execution. + +------------------------------------------------------------------- Old: ---- gnustep-make-2.9.0.tar.gz gnustep-make-2.9.0.tar.gz.sig New: ---- gnustep-make-2.9.1.tar.gz gnustep-make-2.9.1.tar.gz.sig ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ gnustep-make.spec ++++++ --- /var/tmp/diff_new_pack.fcP2lP/_old 2023-01-07 17:19:28.410069734 +0100 +++ /var/tmp/diff_new_pack.fcP2lP/_new 2023-01-07 17:19:28.414069758 +0100 @@ -24,7 +24,7 @@ # Disable debug package as rpm > 4.13 does not allow for empty debug file list. %global debug_package %{nil} Name: gnustep-make -Version: 2.9.0 +Version: 2.9.1 Release: 0 Summary: GNUstep Makefile package License: GPL-3.0-or-later AND LGPL-2.1-or-later ++++++ gnustep-make-2.9.0.tar.gz -> gnustep-make-2.9.1.tar.gz ++++++ ++++ 15429 lines of diff (skipped) ++++ retrying with extended exclude list diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/gnustep-make-2.9.0/ChangeLog new/gnustep-make-2.9.1/ChangeLog --- old/gnustep-make-2.9.0/ChangeLog 2021-03-21 22:56:13.000000000 +0100 +++ new/gnustep-make-2.9.1/ChangeLog 2022-12-28 11:18:03.000000000 +0100 @@ -1,3 +1,49 @@ +2022-12-28 Richard Frith-Macdonald <r...@gnu.org> + + * ANNOUNCE: + * NEWS: + * RELEASENOTES: + * Documentation/news.texi: + * Documentation/releasenotes.texi: + Update announcement and release notes for 2.9.1. + * Version: Bump version to 2.9.1. + +2022-12-05 Richard Frith-Macdonald <r...@gnu.org> + + * TestFramework/gnustep-tests.in: use the -a option to force grep + to treat log files as text rather than binary. If treated as binary + it would not extract the information we need. + * TestFramework/Testing.h: fix uninitialised variable in the macro + to test for a regexp match. + +2022-03-01 Richard Frith-Macdonald <r...@gnu.org> + + * TestFramework/gnustep-tests.in: + When using TestInfo send stdout and stderr to /dev/null so that + thy don't interfere with the test output. + +2022-02-16 Richard Frith-Macdonald <r...@gnu.org> + + * TestFramework/gnustep-tests.in: + Fix bug introduced in rewrite for parallelisation: we were getting + immediate end of testing when one file failed, but that behavior + should only occur when --failfast is specified. + +2022-01-26 Richard Frith-Macdonald <r...@gnu.org> + + * TestFramework/README: + * TestFramework/TestInfo: + * TestFramework/gnustep-tests.in: + Add support for controlling test execution using SEQUENCE and PARALLEL + in TestInfo to control the order of seuntial tests and the running of + concurrent tests. + +2021-03-28 Frederik Seiffert <frede...@algoriddim.com> + + * TestFramework/Testing.h: + Add workaround for Clang bug on Windows MSVC when tests contain no + Objective-C constructs. + 2021-03-21 Ivan Vucica <i...@vucica.net> * ANNOUNCE: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/gnustep-make-2.9.0/Documentation/GNUmakefile new/gnustep-make-2.9.1/Documentation/GNUmakefile --- old/gnustep-make-2.9.0/Documentation/GNUmakefile 2021-03-21 22:56:13.000000000 +0100 +++ new/gnustep-make-2.9.1/Documentation/GNUmakefile 2022-12-28 11:18:03.000000000 +0100 @@ -83,7 +83,7 @@ # normal gnustep-make GNUmakefile for documentation. # We normally install into System -GNUSTEP_INSTALLATION_DOMAIN = SYSTEM +GNUSTEP_INSTALLATION_DOMAIN = LOCAL include $(GNUSTEP_MAKEFILES)/common.make diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/gnustep-make-2.9.0/Documentation/gnustep-config.1 new/gnustep-make-2.9.1/Documentation/gnustep-config.1 --- old/gnustep-make-2.9.0/Documentation/gnustep-config.1 2021-03-21 22:56:13.000000000 +0100 +++ new/gnustep-make-2.9.1/Documentation/gnustep-config.1 2022-12-28 11:18:03.000000000 +0100 @@ -13,7 +13,7 @@ can print information about the currently installed GNUstep system. Output is generated dynamically based on environment variables such as GNUSTEP_CONFIG_FILE and GNUSTEP_MAKEFILES, -though default values for these are generated when the tool is configured/installed. Output is primarily the locations in which various GNUstep resources are installed, but also provide flags used to build differnt types of GNUstep project. +though default values for these are generated when the tool is configured/installed. Output is primarily the locations in which various GNUstep resources are installed, but also provide flags used to build different types of GNUstep project. .SH OPTIONS .TP .BI \-\-variable= variable diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/gnustep-make-2.9.0/Documentation/library-combo.7 new/gnustep-make-2.9.1/Documentation/library-combo.7 --- old/gnustep-make-2.9.0/Documentation/library-combo.7 2021-03-21 22:56:13.000000000 +0100 +++ new/gnustep-make-2.9.1/Documentation/library-combo.7 2022-12-28 11:18:03.000000000 +0100 @@ -17,7 +17,7 @@ .PP If you installed your .B GNUstep -system in a non-flattened way all system dependend binaries are installed in subdirectories with +system in a non-flattened way all system dependent binaries are installed in subdirectories with .I cpu/os/library-combo information. That means for instance that the .I gnustep-base diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/gnustep-make-2.9.0/Documentation/news.texi new/gnustep-make-2.9.1/Documentation/news.texi --- old/gnustep-make-2.9.0/Documentation/news.texi 2021-03-21 22:56:13.000000000 +0100 +++ new/gnustep-make-2.9.1/Documentation/news.texi 2022-12-28 11:18:03.000000000 +0100 @@ -9,6 +9,18 @@ The currently released version is @samp{@value{GNUSTEP-MAKE-VERSION}}. @end ifclear +@section Changes in version @samp{2.9.1} + +@itemize + +@item Add workaround for Clang bug on Windows MSVC when tests contain no Objective-C constructs. + +@item Various fixes for minor issues introduced in the test framework by parallelisation mof testcase execution. + +@end itemize + +@ifclear ANNOUNCE-ONLY + @section Changes in version @samp{2.9.0} @itemize @@ -38,8 +50,6 @@ @end itemize -@ifclear ANNOUNCE-ONLY - @section Changes in version @samp{2.8.0} @itemize diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/gnustep-make-2.9.0/Documentation/releasenotes.texi new/gnustep-make-2.9.1/Documentation/releasenotes.texi --- old/gnustep-make-2.9.0/Documentation/releasenotes.texi 2021-03-21 22:56:13.000000000 +0100 +++ new/gnustep-make-2.9.1/Documentation/releasenotes.texi 2022-12-28 11:18:03.000000000 +0100 @@ -4,6 +4,16 @@ changes and other information that might help developers and users migrate to using a newer version of the make system. +@section Version 2.9.1 + +Test framework has workaround for clang issues when building with MSCV. + +A few minor test framework issues inroduced by the parallelisation rewrite are fixed. + +A bug in the PASS_MATCH macro is fixed. + +The test framework makefiles now automatically add the framework header directory to the compiler flags, so testcases can be more reliably built by invoking make directly (rather than via the gnustep-tests script). + @section Version 2.9.0 We have improved support for newer GCC versions (GCC9 and newer). diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/gnustep-make-2.9.0/Instance/framework.make new/gnustep-make-2.9.1/Instance/framework.make --- old/gnustep-make-2.9.0/Instance/framework.make 2021-03-21 22:56:13.000000000 +0100 +++ new/gnustep-make-2.9.1/Instance/framework.make 2022-12-28 11:18:03.000000000 +0100 @@ -299,6 +299,11 @@ # as under Unix. LIB_LINK_DLL_FILE = $(DLL_PREFIX)$(GNUSTEP_INSTANCE)-$(subst .,_,$(INTERFACE_VERSION))$(DLL_LIBEXT) +# LIB_LINK_PDB_FILE is the PDB symbol file. The program database (PDB) +# includes instructions for formatting trace messages so that they +# can be presented in a human-readable display. +LIB_LINK_PDB_FILE = $(DLL_PREFIX)$(GNUSTEP_INSTANCE)-$(subst .,_,$(INTERFACE_VERSION))$(DLL_PDBEXT) + FRAMEWORK_OBJ_EXT = $(DLL_LIBEXT) endif # BUILD_DLL diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/gnustep-make-2.9.0/Instance/library.make new/gnustep-make-2.9.1/Instance/library.make --- old/gnustep-make-2.9.0/Instance/library.make 2021-03-21 22:56:13.000000000 +0100 +++ new/gnustep-make-2.9.1/Instance/library.make 2022-12-28 11:18:03.000000000 +0100 @@ -200,15 +200,9 @@ else # BUILD_DLL # When you build a DLL, you have to install it in a directory which is -# in your PATH. On Windows MSVC we use the library directory that will -# also contain other libraries like objc.dll. Otherwise (i.e. on MinGW) -# we use the tools directory. +# in your PATH. ifeq ($(DLL_INSTALLATION_DIR),) - ifeq ($(GNUSTEP_TARGET_OS), windows) - DLL_INSTALLATION_DIR = $(FINAL_LIBRARY_INSTALL_DIR) - else - DLL_INSTALLATION_DIR = $(GNUSTEP_TOOLS)/$(GNUSTEP_TARGET_LDIR) - endif + DLL_INSTALLATION_DIR = $(GNUSTEP_TOOLS)/$(GNUSTEP_TARGET_LDIR) endif # When we build a DLL, we also pass -DBUILD_lib{library_name}_DLL=1 to diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/gnustep-make-2.9.0/TestFramework/GNUmakefile.in new/gnustep-make-2.9.1/TestFramework/GNUmakefile.in --- old/gnustep-make-2.9.0/TestFramework/GNUmakefile.in 2021-03-21 22:56:13.000000000 +0100 +++ new/gnustep-make-2.9.1/TestFramework/GNUmakefile.in 2022-12-28 11:18:03.000000000 +0100 @@ -8,6 +8,8 @@ TEST_TOOL_NAME = @TESTNAMES@ +ADDITIONAL_CPPFLAGS += -I$(GNUSTEP_MAKEFILES)/TestFramework + ifeq ($(gcov),yes) ADDITIONAL_OBJCFLAGS += -ftest-coverage -fprofile-arcs ADDITIONAL_OBJCCFLAGS += -ftest-coverage -fprofile-arcs @@ -24,5 +26,6 @@ after-clean:: rm -f core core.* *.core \ + test_*.out test_*.err \ tests.log tests.sum oldtests.log oldtests.sum diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/gnustep-make-2.9.0/TestFramework/README new/gnustep-make-2.9.1/TestFramework/README --- old/gnustep-make-2.9.0/TestFramework/README 2021-03-21 22:56:13.000000000 +0100 +++ new/gnustep-make-2.9.1/TestFramework/README 2022-12-28 11:18:03.000000000 +0100 @@ -288,6 +288,11 @@ number of simultaneous builds you want to be permitted (or you can simply use 'gnustep-tests --sequential' to force building of one test at a time). +Running of the tests is, by default, done sequentially in alphabetical order, +but this may be overridden to change the order of sequential tests and to run +tests concurrently. The mechanism for this is to set values in the TestInfo +file. + For total control, the framework checks to see if a 'GNUmakefile.tests' file exists in the directory, and if it does it uses that file as a template to create the GNUmakefile rather than using its own make file. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/gnustep-make-2.9.0/TestFramework/TestInfo new/gnustep-make-2.9.1/TestFramework/TestInfo --- old/gnustep-make-2.9.0/TestFramework/TestInfo 2021-03-21 22:56:13.000000000 +0100 +++ new/gnustep-make-2.9.1/TestFramework/TestInfo 2022-12-28 11:18:03.000000000 +0100 @@ -2,3 +2,15 @@ # regression testing framework should attempt to find and run testcases. # This is sourced by the shell script running the tests and may be used # to set up the environment variables for the test etc. +# Special variable declarations are used by the regression testing: +# PARALLEL may be used to specify a space separated list of tests to be +# executed concurrently. +# SEQUENCE may be used to specify a space separated list of tests to be +# executed sequentially. +# The SEQUENCE tests are executed before the PARALLEL tests. +# Any occurrence of an asterisk in either variable is expanded to a space +# delimited list of all the available tests in the directory. +# If neither variable is specified the system assumes SEQUENCE="*" so that +# all available tests are executed sequentially. +# Test names may occur more than once, in which case those tests will be +# executed more than once. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/gnustep-make-2.9.0/TestFramework/Testing.h new/gnustep-make-2.9.1/TestFramework/Testing.h --- old/gnustep-make-2.9.0/TestFramework/Testing.h 2021-03-21 22:56:13.000000000 +0100 +++ new/gnustep-make-2.9.1/TestFramework/Testing.h 2022-12-28 11:18:03.000000000 +0100 @@ -33,6 +33,21 @@ #import <Foundation/NSRegularExpression.h> #import <Foundation/NSString.h> +#if defined(__OBJC__) && defined(__clang__) && defined(_MSC_VER) +/* Work around Clang bug on Windows MSVC when tests contain no + * Objective-C constructs: https://bugs.llvm.org/show_bug.cgi?id=49681 + */ +id __work_around_clang_bug = @"__unused__"; +#endif + +/* strncpy is deprecated on Windows MSVC. Use strncpy_s instead. + */ +#if defined(_MSC_VER) + #define STRNCPY(dest, size_dest, src, size_src) strncpy_s(dest, size_dest, src, size_src); +#else + #define STRNCPY(dest, size_dest, src, size_src) strncpy(dest, src, size_dest); +#endif + /* A flag indicating that the testsuite is currently processing tests * which are actually not expected to pass, but where we hope someone * might have committed a bugfix. @@ -325,19 +340,16 @@ _pat = (id)(testExpect__);\ _exp = [[[NSRegularExpression alloc] initWithPattern: _pat \ options: 0 error: 0] autorelease];\ + _cond = 0; \ if (nil != _dsc && nil != _exp) \ { \ NSRange r = NSMakeRange(0, [_dsc length]);\ r = [_exp rangeOfFirstMatchInString: _dsc options: 0 range: r];\ if (r.length > 0)\ { \ - _cond = YES; \ + _cond = 1; \ } \ } \ - else \ - { \ - _cond = NO; \ - } \ pass(_cond, "%s:%d ... " testFormat__, __FILE__, \ __LINE__, ## __VA_ARGS__); \ if (0 == _cond) \ @@ -466,8 +478,9 @@ BOOL _save_hopeful = testHopeful; \ unsigned _save_indentation = testIndentation; \ int _save_line = __LINE__; \ - char *_save_set = (char*)malloc(strlen(setName) + 1); \ - strncpy(_save_set, setName, strlen(setName) + 1); \ + size_t _save_set_size = strlen(setName) + 1; \ + char *_save_set = (char*)malloc(_save_set_size); \ + STRNCPY(_save_set, _save_set_size, setName, _save_set_size); \ fprintf(stderr, "Start set: "); \ testIndent(); \ fprintf(stderr, "%s:%d ... %s\n", __FILE__, __LINE__, _save_set); \ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/gnustep-make-2.9.0/TestFramework/gnustep-tests.in new/gnustep-make-2.9.1/TestFramework/gnustep-tests.in --- old/gnustep-make-2.9.0/TestFramework/gnustep-tests.in 2021-03-21 22:56:13.000000000 +0100 +++ new/gnustep-make-2.9.1/TestFramework/gnustep-tests.in 2022-12-28 11:18:03.000000000 +0100 @@ -287,11 +287,17 @@ shift while test $# != 0 do - grep "$1" "$f" + grep -a "$1" "$f" shift done } +# Get the name of a test from its file name +getname() +{ + TESTNAME=`echo $1 | sed -e"s/^\(test^.]*\)$/\1.obj./;s/\.[^.]*//g"` +} + # Function for platforms where grep can't search for multiple patterns. present() { @@ -299,7 +305,7 @@ shift while test $# != 0 do - grep "$1" "$f" >/dev/null + grep -a "$1" "$f" >/dev/null if test $? = "0" then return 0 @@ -309,20 +315,25 @@ return 1 } -# Low level function to build and run the Objective-C program $TESTFILE -# in the current directory. The TEMPLATE variable must already be set -# to the name of the make file template if gnustep-make is to do the -# building. +# Low level function to build the Objective-C program $TESTFILE +# in the current directory. The TEMPLATE variable must already +# be set to the name of the make file template if gnustep-make +# is to do the building. # -build_and_run () +build_test () { + # The argument to this function is the name of a test file. # Remove the extension, if there is one. If there is no extension, add # .obj . - TESTNAME=`echo $TESTFILE | sed -e"s/^\(test^.]*\)$/\1.obj./;s/\.[^.]*//g"` + local TESTFILE=$1 + local TESTNAME=`echo $TESTFILE | sed -e"s/^\(test^.]*\)$/\1.obj./;s/\.[^.]*//g"` + local BUILD_STATUS + local BUILD_CMD + local tmp - # Run the test. + # Build the test. + echo "Building $TESTNAME" - RUN_CMD="./obj/$TESTNAME" if test x"$TEMPLATE" = x then # The very simple case, we just need to compile a single file @@ -358,32 +369,42 @@ fi fi - # Compile it if necessary. # Redirect errors to stdout so it shows up in the log, # but not in the summary. - if test "$NEEDBUILD" = "yes" + echo "Building $dir/$TESTFILE" + echo "$BUILD_CMD" + if test -r ./make-check.env then - echo "Building $dir/$TESTFILE" - echo "$BUILD_CMD" - if test -r ./make-check.env - then - ( . ./make-check.env; . ./TestInfo; $BUILD_CMD) 2>&1 - else - ( . ./TestInfo; $BUILD_CMD) 2>&1 - fi - BUILDSTATUS=$? + ( . ./make-check.env; . ./TestInfo > /dev/null 2>&1; $BUILD_CMD) 2>&1 else - BUILDSTATUS=0 + ( . ./TestInfo > /dev/null 2>&1; $BUILD_CMD) 2>&1 fi - if test $BUILDSTATUS != 0 + if test $? != 0 then + rm -f ./obj/$TESTNAME echo "Failed build: $1" >&2 if test "$GSTESTMODE" = "failfast" then return 1 fi - else + fi + return 0 +} + +run_test () +{ + # Remove the extension, if there is one. If there is no extension, add + # .obj . + local TESTFILE=$1 + local TESTNAME=$2 + + # Run the test. + + local RUN_CMD="./obj/$TESTNAME" + + if test -x $RUN_CMD + then # We want aggressive memory checking. # Tell glibc to check for malloc errors, and to crash if it detects @@ -408,13 +429,14 @@ else if test -r ./make-check.env then - ( . ./make-check.env; . ./TestInfo; $RUN_CMD ) + ( . ./make-check.env; . ./TestInfo > /dev/null 2>&1; $RUN_CMD ) else - ( . ./TestInfo; $RUN_CMD ) + ( . ./TestInfo > /dev/null 2>&1; $RUN_CMD ) fi fi - if test $? != 0 + result=$? + if test $result != 0 then if test -r $TESTFILE.abort then @@ -429,62 +451,88 @@ else echo "Completed file: $TESTFILE" >&2 fi + else + echo "Skipped (not built) file: $TESTFILE" >&2 fi return 0 } -# Function to build and run $TESTFILE in the current directory. -# This actually manages the logging process and calls build_and_run -# to perform the work. -# -run_test_file () -{ - RUNEXIT=0 - echo >> $GSTESTLOG - echo Testing $TESTFILE... >> $GSTESTLOG - echo >> $GSTESTSUM +run_test_log () +{ + local TESTFILE=$1 + local TESTNAME=$2 + local TESTLOG=$3 + local TESTVRB=$4 + + # Create temporary files + touch $TESTVRB + echo Testing $TESTFILE... > $TESTLOG if test x"$GSVERBOSE" = xyes then - build_and_run 2>&1 | tee $GSTESTLOG.tmp + run_test $TESTFILE $TESTNAME 2>&1 | tee -a $TESTLOG >> $TESTVRB else - build_and_run > $GSTESTLOG.tmp 2>&1 + run_test $TESTFILE $TESTNAME >> $TESTLOG 2>&1 fi - RUNEXIT=$? + result=$? + if test "$result" != "0" + then + if test "$GSTESTMODE" = "failfast" + then + RUNEXIT=1 + fi + fi +} - # Add the information to the detailed log. - cat $GSTESTLOG.tmp >> $GSTESTLOG +proc_test_log () +{ + local TESTFILE=$1 + local TESTNAME=$2 + local TESTLOG=$3 + local TESTVRB=$4 # Extract the summary information and add it to the summary file. - extract $GSTESTLOG.tmp "^Passed test:" "^Failed test:" "^Failed build:" "^Completed file:" "^Failed file:" "^Dashed hope:" "^Failed set:" "^Skipped set:" > $GSTESTSUM.tmp + extract $TESTLOG "^Passed test:" "^Failed test:" "^Failed build:" "^Completed file:" "^Failed file:" "^Dashed hope:" "^Failed set:" "^Skipped set:" > $GSTESTSUM.tmp cat $GSTESTSUM.tmp >> $GSTESTSUM + cat $TESTLOG >> $GSTESTLOG + rm -f $TESTLOG + cat $TESTVRB + rm -f $TESTVRB + # If there were failures or skipped tests then report them... if present $GSTESTSUM.tmp "^Failed build:" "^Failed file:" "^Failed set:" "^Failed test:" "^Skipped set:" then echo echo $dir/$TESTFILE: extract $GSTESTSUM.tmp "^Failed build:" "^Failed file:" "^Failed set:" "^Failed test:" "^Skipped set:" + if test "$GSTESTMODE" = "failfast" + then + RUNEXIT=1 + fi + else + RUNEXIT=0 fi if test x"$GSTESTDBG" != x then + DEBUGGER=`gnustep-config --variable=DEBUGGER` + EXT=`gnustep-config --variable=EXEEXT` if present "$GSTESTSUM.tmp" "^Failed test:" then - grep '^Failed test:' "$GSTESTLOG.tmp" | sed -e 's/^Failed test:[^:]*:\([0-9][0-9]*\).*/break testStart if testLineNumber==\1/' > "$GSTESTDBG" - gdb "./obj/$TESTNAME" -x "$GSTESTDBG" + grep -a '^Failed test:' "$GSTESTLOG.tmp" | sed -e 's/^Failed test:[^:]*:\([0-9][0-9]*\).*/break testStart if testLineNumber==\1/' > "$GSTESTDBG" + $DEBUGGER "./obj/$TESTNAME"$EXT -x "$GSTESTDBG" rm -f "$GSTESTDBG" elif present "$GSTESTSUM.tmp" "^Failed file:" then - gdb "./obj/$TESTNAME" + $DEBUGGER "./obj/$TESTNAME"$EXT fi fi - return $RUNEXIT + return 0 } - # Replace the old files. if test -f tests.log then @@ -560,7 +608,7 @@ then $MAKE_CMD clean >/dev/null 2>&1 fi - rm -rf core core.* *.core obj GNUmakefile gdb.cmds tests.log tests.sum oldtests.log oldtests.sum tests.tmp tests.sum.tmp tests.log.tmp make-check.mak make-check.env + rm -rf core core.* *.core obj GNUmakefile gdb.cmds test_*.err test_*.out tests.log tests.sum oldtests.log oldtests.sum tests.tmp tests.sum.tmp tests.log.tmp make-check.mak make-check.env else echo "--- Running tests in $dir ---" @@ -622,7 +670,6 @@ TEMPLATE=$GSTESTTOP/GNUmakefile.in fi - NEEDBUILD=yes if test x"$TEMPLATE" = x then rm -rf core core.* *.core obj GNUmakefile gdb.cmds @@ -659,33 +706,121 @@ sed -e "s/@TESTNAMES@/$TESTNAMES/;s^@TESTOPTS@^$GSTESTOPTS^;s/@TESTRULES@/$TESTRULES/" < "$TEMPLATE" > GNUmakefile $MAKE_CMD clean >/dev/null 2>&1 - # Try building all the test files in the directory in parallel. - # If that works, set NEEDBUILD to 'no' so that we do not build - # each individual test file later. - echo "" >>$GSTESTLOG - echo "Building in $dir" >>$GSTESTLOG - if test -r ./make-check.env + if test x"$GSSEQUENTIAL" = xyes then - ( . ./make-check.env; . ./TestInfo; $MAKE_CMD -j 4 debug=yes) >>$GSTESTLOG 2>&1 + build_state=1 else - ( . ./TestInfo; $MAKE_CMD -j 4 debug=yes) >>$GSTESTLOG 2>&1 + # Try building all the test files in the directory in parallel. + # If that fails, try building them individually. + echo "" >>$GSTESTLOG + echo "Building in $dir" >>$GSTESTLOG + if test -r ./make-check.env + then + ( . ./make-check.env; . ./TestInfo > /dev/null 2>&1; $MAKE_CMD -j 4 debug=yes) >>$GSTESTLOG 2>&1 + else + ( . ./TestInfo > /dev/null 2>&1; $MAKE_CMD -j 4 debug=yes) >>$GSTESTLOG 2>&1 + fi + build_state=$? fi - if test $? = 0 + if test $build_state != 0 then - NEEDBUILD=no + for TESTFILE in $TESTS + do + build_test "$TESTFILE" + done fi fi - # Now we process each test file in turn. - # When cleaning, we only need to do one clean per directory. + # Build up a list of the names of all the tests available. + declare -A TESTMAP + ALLTESTS="" for TESTFILE in $TESTS do - run_test_file - if test "$RUNEXIT" != "0" + getname $TESTFILE + TESTMAP["$TESTNAME"]="$TESTFILE" + if test "$ALLTESTS" = "" + then + ALLTESTS="$TESTNAME" + else + ALLTESTS="$ALLTESTS $TESTNAME" + fi + done + + # Get the values defined for PARALLEL and PARALLEL in TestInfo + # These variables should specify the names of sets of tests to + # be executed in parallel or sequentially respectively. + GSPAR=`( . ./TestInfo > /dev/null 2>&1; echo "$PARALLEL") 2>&1` + GSSEQ=`( . ./TestInfo > /dev/null 2>&1; echo "$SEQUENCE") 2>&1` + + # When PARALLEL and SEQUENCE are both missing or empty, we treat + # it as if SEQUENCE had been set to contain an asterisk so that + # all the tests are executed in order. + if test "$GSPAR" = "" -a "$GSSEQ" = "" + then + GSSEQ="*" + fi + + # Any occurrence of an asterisk in PARALLEL or SEQUENCE is replaced + # by the names of all the tests separated by white space. + GSPAR=`echo "$GSPAR" | sed -e "s/\*/ $ALLTESTS /g"` + GSSEQ=`echo "$GSSEQ" | sed -e "s/\*/ $ALLTESTS /g"` + + # NB. we check the map to see that a file exists for each test name + # because the names we have been given may not exist in the set of + # tests being run (ie specified at the cvommand line). + + # Now we process sequence test file in turn. + i=0 + for TESTNAME in $GSSEQ + do + TESTFILE=${TESTMAP[$TESTNAME]} + if test "$TESTFILE" != "" + then + if test x"$GSVERBOSE" = xyes + then + echo "Sequence perform $TESTNAME" + fi + run_test_log $TESTFILE $TESTNAME test_$i.out test_$i.err + proc_test_log $TESTFILE $TESTNAME test_$i.out test_$i.err + if test "$RUNEXIT" != "0" + then + break + fi + ((i+=1)) + fi + done + + # And process all parallel test files together + i=0 + for TESTNAME in $GSPAR + do + TESTFILE=${TESTMAP[$TESTNAME]} + if test "$TESTFILE" != "" then - break + if test x"$GSVERBOSE" = xyes + then + echo "Parallel startup $TESTNAME" + fi + run_test_log $TESTFILE $TESTNAME test_$i.out test_$i.err & + ((i+=1)) + fi + done + wait + i=0 + for TESTNAME in $GSPAR + do + TESTFILE=${TESTMAP[$TESTNAME]} + if test "$TESTFILE" != "" + then + proc_test_log $TESTFILE $TESTNAME test_$i.out test_$i.err + if test "$RUNEXIT" != "0" + then + break + fi + ((i+=1)) fi done + else echo "Start.sh failed in '$TESTDIR' ... tests abandoned." for TESTFILE in $TESTS @@ -744,7 +879,7 @@ if test "$GSTESTMODE" = "clean" then - rm -rf core core.* *.core obj GNUmakefile.tmp gdb.cmds tests.tmp tests.sum.tmp tests.log.tmp tests.log tests.sum oldtests.log oldtests.sum + rm -rf core core.* *.core obj GNUmakefile.tmp gdb.cmds test_*.err test_*.out tests.tmp tests.sum.tmp tests.log.tmp tests.log tests.sum oldtests.log oldtests.sum else # Make some stats. if test -r tests.sum @@ -783,7 +918,7 @@ FAILS=$? # Delete the temporary file. -rm -f tests.tmp tests.sum.tmp tests.log.tmp +rm -f test_*.err test_*.out tests.tmp tests.sum.tmp tests.log.tmp # Our exit status is 0 unless some test failed. if test -r "$GSTESTSUM" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/gnustep-make-2.9.0/Version new/gnustep-make-2.9.1/Version --- old/gnustep-make-2.9.0/Version 2021-03-21 22:56:13.000000000 +0100 +++ new/gnustep-make-2.9.1/Version 2022-12-28 11:18:03.000000000 +0100 @@ -4,6 +4,6 @@ # The version number of this release. GNUSTEP_MAKE_MAJOR_VERSION=2 GNUSTEP_MAKE_MINOR_VERSION=9 -GNUSTEP_MAKE_SUBMINOR_VERSION=0 +GNUSTEP_MAKE_SUBMINOR_VERSION=1 GNUSTEP_MAKE_VERSION=${GNUSTEP_MAKE_MAJOR_VERSION}.${GNUSTEP_MAKE_MINOR_VERSION}.${GNUSTEP_MAKE_SUBMINOR_VERSION} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/gnustep-make-2.9.0/configure.ac new/gnustep-make-2.9.1/configure.ac --- old/gnustep-make-2.9.0/configure.ac 2021-03-21 22:56:13.000000000 +0100 +++ new/gnustep-make-2.9.1/configure.ac 2022-12-28 11:18:03.000000000 +0100 @@ -21,7 +21,7 @@ # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. AC_INIT -AC_PREREQ(2.65) +AC_PREREQ([2.71]) AC_CONFIG_SRCDIR([application.make]) AC_CONFIG_MACRO_DIRS([m4]) @@ -85,6 +85,15 @@ # We may use egrep for some tests further down below AC_PROG_EGREP +# Search for a debugger. We try 'gdb' then 'lldb'. If +# we can't find it, we set it to 'gdb', even if that will fail later +# on. +AC_CHECK_PROGS(DEBUGGER, [gdb lldb], gdb) + +# Used by gnustep-config to output the debugger variable and +# gnustep-tests. +AC_SUBST(DEBUGGER) + #-------------------------------------------------------------------- # Check if we are using Apple cc #-------------------------------------------------------------------- @@ -1152,86 +1161,67 @@ AC_MSG_CHECKING(whether objc has thread support) if test "$OBJC_THREAD" != ""; then LIBS="$OBJCRT $LIBS $OBJC_THREAD" - AC_TRY_RUN([#include "config_thread.m"], - objc_threaded="$OBJC_THREAD", - objc_threaded="", objc_threaded="") + AC_RUN_IFELSE([AC_LANG_SOURCE([[#include "config_thread.m"]])],[objc_threaded="$OBJC_THREAD"],[objc_threaded=""],[objc_threaded=""]) elif test "$host_os" = linux-gnu; then LIBS="$OBJCRT -lpthread" - AC_TRY_RUN([#include "config_thread.m"], objc_threaded="-lpthread", - objc_threaded="", objc_threaded="-lpthread") + AC_RUN_IFELSE([AC_LANG_SOURCE([[#include "config_thread.m"]])],[objc_threaded="-lpthread"],[objc_threaded=""],[objc_threaded="-lpthread"]) + if test x"$objc_threaded" = x""; then + LIBS="$OBJCRT" + AC_RUN_IFELSE([AC_LANG_SOURCE([[#include "config_thread.m"]])],[objc_threaded="works"],[objc_threaded=""],[objc_threaded="works"]) + fi +elif test "$host_os" = linux-musl; then + LIBS="$OBJCRT -lpthread" + AC_RUN_IFELSE([AC_LANG_SOURCE([[#include "config_thread.m"]])],[objc_threaded="-lpthread"],[objc_threaded=""],[objc_threaded="-lpthread"]) if test x"$objc_threaded" = x""; then LIBS="$OBJCRT" - AC_TRY_RUN([#include "config_thread.m"], - objc_threaded="works", - objc_threaded="", objc_threaded="works") + AC_RUN_IFELSE([AC_LANG_SOURCE([[#include "config_thread.m"]])],[objc_threaded="works"],[objc_threaded=""],[objc_threaded="works"]) fi elif test "`echo $host_os|sed 's/[[0-9]].*//'|sed s/elf//`" = freebsd; then LIBS="-pthread $OBJCRT" - AC_TRY_RUN([#include "config_thread.m"], objc_threaded="-pthread", - objc_threaded="", objc_threaded="-pthread") + AC_RUN_IFELSE([AC_LANG_SOURCE([[#include "config_thread.m"]])],[objc_threaded="-pthread"],[objc_threaded=""],[objc_threaded="-pthread"]) if test x"$objc_threaded" = x""; then LIBS="-lpthread $OBJCRT" - AC_TRY_RUN([#include "config_thread.m"], objc_threaded="-lpthread", - objc_threaded="", objc_threaded="-lpthread") + AC_RUN_IFELSE([AC_LANG_SOURCE([[#include "config_thread.m"]])],[objc_threaded="-lpthread"],[objc_threaded=""],[objc_threaded="-lpthread"]) fi if test x"$objc_threaded" = x""; then LIBS="$OBJCRT -lpcthread" - AC_TRY_RUN([#include "config_thread.m"], objc_threaded="-lpcthread", - objc_threaded="", objc_threaded="-lpcthread") + AC_RUN_IFELSE([AC_LANG_SOURCE([[#include "config_thread.m"]])],[objc_threaded="-lpcthread"],[objc_threaded=""],[objc_threaded="-lpcthread"]) fi if test x"$objc_threaded" = x""; then LIBS="$OBJCRT" - AC_TRY_RUN([#include "config_thread.m"], - objc_threaded="works", - objc_threaded="", objc_threaded="works") + AC_RUN_IFELSE([AC_LANG_SOURCE([[#include "config_thread.m"]])],[objc_threaded="works"],[objc_threaded=""],[objc_threaded="works"]) fi elif test "$MINGW32" = yes; then # Mingw doesn't need anything extra for threads LIBS="$OBJCRT $LIBS" - AC_TRY_RUN([#include "config_thread.m"], - objc_threaded="works", - objc_threaded="", objc_threaded="works") + AC_RUN_IFELSE([AC_LANG_SOURCE([[#include "config_thread.m"]])],[objc_threaded="works"],[objc_threaded=""],[objc_threaded="works"]) elif test "$MINGW64" = yes; then # Mingw doesn't need anything extra for threads LIBS="$OBJCRT $LIBS" - AC_TRY_RUN([#include "config_thread.m"], - objc_threaded="works", - objc_threaded="", objc_threaded="works") + AC_RUN_IFELSE([AC_LANG_SOURCE([[#include "config_thread.m"]])],[objc_threaded="works"],[objc_threaded=""],[objc_threaded="works"]) elif test "$OBJC_RUNTIME_LIB" = "apple"; then # Apple doesn't need anything extra for threads LIBS="$OBJCRT $LIBS" - AC_TRY_RUN([#include "config_thread.m"], - objc_threaded="works", - objc_threaded="", objc_threaded="works") + AC_RUN_IFELSE([AC_LANG_SOURCE([[#include "config_thread.m"]])],[objc_threaded="works"],[objc_threaded=""],[objc_threaded="works"]) else LIBS="$OBJCRT $LIBS" - AC_TRY_RUN([#include "config_thread.m"], - objc_threaded="works", - objc_threaded="", objc_threaded="") + AC_RUN_IFELSE([AC_LANG_SOURCE([[#include "config_thread.m"]])],[objc_threaded="works"],[objc_threaded=""],[objc_threaded=""]) if test x"$objc_threaded" = x""; then LIBS="$OBJCRT $saved_LIBS -lpthread " - AC_TRY_RUN([#include "config_thread.m"], - objc_threaded="-lpthread", - objc_threaded="", objc_threaded="") + AC_RUN_IFELSE([AC_LANG_SOURCE([[#include "config_thread.m"]])],[objc_threaded="-lpthread"],[objc_threaded=""],[objc_threaded=""]) fi if test x"$objc_threaded" = x""; then # Solaris, OpenBSD/sparc LIBS="$OBJCRT $saved_LIBS -lpthread -lposix4" - AC_TRY_RUN([#include "config_thread.m"], - objc_threaded="-lpthread -lposix4", - objc_threaded="", objc_threaded="") + AC_RUN_IFELSE([AC_LANG_SOURCE([[#include "config_thread.m"]])],[objc_threaded="-lpthread -lposix4"],[objc_threaded=""],[objc_threaded=""]) fi if test x"$objc_threaded" = x""; then LIBS="$OBJCRT $saved_LIBS -lthread " - AC_TRY_RUN([#include "config_thread.m"], - objc_threaded="-lthread", - objc_threaded="", objc_threaded="") + AC_RUN_IFELSE([AC_LANG_SOURCE([[#include "config_thread.m"]])],[objc_threaded="-lthread"],[objc_threaded=""],[objc_threaded=""]) fi if test x"$objc_threaded" = x""; then LIBS="$OBJCRT" - AC_TRY_RUN([#include "config_thread.m"], - objc_threaded="works", - objc_threaded="", objc_threaded="works") + AC_RUN_IFELSE([AC_LANG_SOURCE([[#include "config_thread.m"]])],[objc_threaded="works"],[objc_threaded=""],[objc_threaded="works"]) fi fi if test x"$objc_threaded" = x""; then diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/gnustep-make-2.9.0/gnustep-config.in new/gnustep-make-2.9.1/gnustep-config.in --- old/gnustep-make-2.9.0/gnustep-config.in 2021-03-21 22:56:13.000000000 +0100 +++ new/gnustep-make-2.9.1/gnustep-config.in 2022-12-28 11:18:03.000000000 +0100 @@ -70,6 +70,8 @@ echo " --variable=CXX" echo " --variable=OBJCXX" echo " --variable=LDFLAGS" + echo " --variable=EXEEXT" + echo " --variable=DEBUGGER" echo " --variable=GNUMAKE" echo " --variable=GNUSTEP_MAKEFILES" echo " --variable=GNUSTEP_USER_DEFAULTS_DIR" @@ -184,6 +186,10 @@ exit 0;; --variable=LDFLAGS) echo "@LDFLAGS@" exit 0;; + --variable=EXEEXT) echo "@EXEEXT@" + exit 0;; + --variable=DEBUGGER) echo "@DEBUGGER@" + exit 0;; --variable=GNUSTEP_MAKEFILES) echo "$GNUSTEP_MAKEFILES" exit 0;; --variable=GNUMAKE) echo "@GNUMAKE@" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/gnustep-make-2.9.0/target.make new/gnustep-make-2.9.1/target.make --- old/gnustep-make-2.9.0/target.make 2021-03-21 22:56:13.000000000 +0100 +++ new/gnustep-make-2.9.1/target.make 2022-12-28 11:18:03.000000000 +0100 @@ -24,6 +24,9 @@ # the 'shared' variable, because we have not set it up yet when this # file is processed! +# variable to for all OSs treated as Linux and Linux-like +IS_LINUX = no + # # Host and target specific settings # @@ -497,12 +500,23 @@ #################################################### # -# Linux ELF or GNU/Hurd +# Linux ELF with GNU or GNU/HURD # # The following ifeq matches both 'linux-gnu' (which is GNU/Linux ELF) # and 'gnu0.3' (I've been told GNUSTEP_TARGET_OS is 'gnu0.3' on -# GNU/Hurd at the moment). We want the same code in both cases. +# GNU/Hurd at the moment). +# We treat GNU/HURD as GNU/Linux for now ifeq ($(findstring gnu, $(GNUSTEP_TARGET_OS)), gnu) +IS_LINUX = yes +endif + +# The following ifeq matches 'linux-musl' but does not re-match 'linux-gnu' +# We treat is as GNU/Linux +ifeq ($(findstring linux-musl, $(GNUSTEP_TARGET_OS)), linux-musl) +IS_LINUX = yes +endif + +ifeq ($(IS_LINUX), yes) HAVE_SHARED_LIBS = yes SHARED_LIB_LINK_CMD = \ $(LD) $(SHARED_LD_PREFLAGS) -shared -Wl,-soname,$(LIB_LINK_SONAME_FILE) \ @@ -1009,6 +1023,10 @@ # On Windows MSVC, class name symbols start with '__' EXTRACT_CLASS_NAMES_COMMAND = $(NM) -Pg $$object_file | sed -n -e '/^._OBJC_CLASS_[A-Za-z0-9_.]* [^U]/ {s/^._OBJC_CLASS_\([A-Za-z0-9_.]*\) [^U].*/\1/p;}' -e '/^__objc_class_name_[A-Za-z0-9_.]* [^U]/ {s/^__objc_class_name_\([A-Za-z0-9_.]*\) [^U].*/\1/p;}' +# Suppress Clang warning in Base when including "GNUstepBase/GSConfig.h": +# #include resolved using non-portable Microsoft search rules as: ././GNUstepBase/GSConfig.h +ADDITIONAL_FLAGS += -Wno-microsoft-include + endif # end Windows MSVC