bug#81484: 31.0.91; semantic-gcc-test-output-parser/this-machine failure on Solaris 10
Eli Zaretskii <[email protected]>
| Newsgroups | gmane.emacs.bugs |
|---|---|
| Message-ID | <[email protected]> |
Ping! > Cc: [email protected] > Date: Sat, 25 Jul 2026 16:41:24 +0300 > From: Eli Zaretskii <[email protected]> > > > Date: Sat, 25 Jul 2026 06:24:58 -0700 > > Cc: [email protected] > > From: Paul Eggert <[email protected]> > > > > On 2026-07-25 03:05, Eli Zaretskii wrote: > > > Any idea why this test fails? The output of "gcc -v" does include > > > '--host', so why does the condition fail? > > > > As I understand it, "gcc -v" didn't start outputting "--host" until GCC > > 4 (2005), when the GCC folks switched to using Autoconf. Unfortunately > > Solaris 10's GCC predates that. Here is the output of Solaris 10 "gcc > > -v" (sent to stderr): > > > > Reading specs from /usr/sfw/lib/gcc/sparc-sun-solaris2.10/3.4.3/specs > > Configured with: > > /sfw10/builds/build/sfw10-patch/usr/src/cmd/gcc/gcc-3.4.3/configure > > --prefix=/usr/sfw --with-as=/usr/ccs/bin/as --without-gnu-as > > --with-ld=/usr/ccs/bin/ld --without-gnu-ld --enable-languages=c,c++ > > --enable-shared > > Thread model: posix > > gcc version 3.4.3 (csl-sol210-3_4-branch+sol_rpath) > > Thanks, then does the patch below fix the problem? > > diff --git a/test/lisp/cedet/semantic/bovine/gcc-tests.el b/test/lisp/cedet/semantic/bovine/gcc-tests.el > index 289f7e5..aad7a81 100644 > --- a/test/lisp/cedet/semantic/bovine/gcc-tests.el > +++ b/test/lisp/cedet/semantic/bovine/gcc-tests.el > @@ -38,7 +38,10 @@ semantic-gcc-test > ;; No longer test for prefixes. > ;; (should .--prefix) > (should .version) > - (should (or .target > + ;; "gcc -v" didn't start outputting "--host" etc. until > + ;; GCC 4 (2005), when the GCC folks switched to using Autoconf. > + (should (or (version< .version "4.0") > + .target > .--target > .--host))))) > > @@ -46,10 +49,10 @@ semantic-gcc-test > > (ert-deftest semantic-gcc-test/1 () > ;; My old box: > - (semantic-gcc-test "Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/3.2.2/specs > + (semantic-gcc-test "Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/4.2.2/specs > Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --disable-checking --with-system-zlib --enable-__cxa_atexit --host=i386-redhat-linux > Thread model: posix > -gcc version 3.2.2 20030222 (Red Hat Linux 3.2.2-5)")) > +gcc version 4.2.2 20030222 (Red Hat Linux 4.2.2-5)")) > > (ert-deftest semantic-gcc-test/2 () > ;; Alex Ott: > @@ -85,10 +88,10 @@ semantic-gcc-test/5 > > (ert-deftest semantic-gcc-test/6 () > ;; Red Hat EL4 > - (semantic-gcc-test "Reading specs from /usr/lib/gcc/x86_64-redhat-linux/3.4.6/specs > + (semantic-gcc-test "Reading specs from /usr/lib/gcc/x86_64-redhat-linux/4.4.6/specs > Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --disable-checking --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-java-awt=gtk --host=x86_64-redhat-linux > Thread model: posix > -gcc version 3.4.6 20060404 (Red Hat 3.4.6-10)")) > +gcc version 4.4.6 20060404 (Red Hat 4.4.6-10)")) > > (ert-deftest semantic-gcc-test/7 () > ;; Red Hat EL5 > diff --git a/test/src/regex-emacs-tests.el b/test/src/regex-emacs-tests.el > index 061fb73..9635f86 100644 > --- a/test/src/regex-emacs-tests.el > +++ b/test/src/regex-emacs-tests.el > @@ -105,7 +105,8 @@ regex-tests-generic-line > > `(with-temp-buffer > (modify-syntax-entry ?_ "w;; ") ; tests expect _ to be a word > - (insert-file-contents (concat regex-tests--resources-dir ,test-file)) > + (let ((coding-system-for-read 'utf-8-unix)) > + (insert-file-contents (concat regex-tests--resources-dir ,test-file))) > (let ((case-fold-search nil) > (line-number 1) > (whitelist-idx 0)) > > > >