public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* Question regarding min reqd dejagnu version
@ 2022-10-01  0:18 Indu Bhagat
  2022-10-03 10:23 ` Nick Clifton
  0 siblings, 1 reply; 9+ messages in thread
From: Indu Bhagat @ 2022-10-01  0:18 UTC (permalink / raw)
  To: binutils

Hello,

When testing out the SFrame implementation patches (not yet in trunk) on 
an i686-linux machine with gcc-4.9.2 and dejagnu-1.5.1, I believe I run 
into the following issue:
https://lists.gnu.org/archive/html/dejagnu/2014-10/msg00011.html

It shows as following when you run make check in libsframe folder:

...
gcc -std=gnu99 -DHAVE_CONFIG_H -I. 
-I/<SFRAME-TEST>/binutils-gdb/libsframe/testsuite/libsframe.decode 
-I../..  -I/<SFRAME-TEST>/binutils-gdb/libsframe/../include -Wall   -g 
-O2     -MT frecnt_1-frecnt_1.o -MD -MP -MF .deps/frecnt_1-frecnt_1.Tpo 
-c -o frecnt_1-frecnt_1.o `test -f 'frecnt_1.c' || echo 
'/<SFRAME-TEST>/binutils-gdb/libsframe/testsuite/libsframe.decode/'`frecnt_1.c
mv -f .deps/frecnt_1-frecnt_1.Tpo .deps/frecnt_1-frecnt_1.Po
/bin/bash ../../libtool  --tag=CC   --mode=link gcc -std=gnu99  -g -O2 
     -o frecnt_1 frecnt_1-frecnt_1.o ../../libsframe.la
libtool: link: gcc -std=gnu99 -g -O2 -o .libs/frecnt_1 
frecnt_1-frecnt_1.o  ../../.libs/libsframe.so -Wl,-rpath 
-Wl,/<SFRAME-TEST>/install/lib
frecnt_1-frecnt_1.o: In function `main':
/<SFRAME-TEST>/binutils-gdb/libsframe/testsuite/libsframe.decode/frecnt_1.c:80: 
undefined reference to `fail'
/<SFRAME-TEST>/binutils-gdb/libsframe/testsuite/libsframe.decode/frecnt_1.c:83: 
undefined reference to `pass'
...

libsframe testsuite depends on dejagnu.h (patch link 
https://sourceware.org/pipermail/binutils/2022-September/123172.html).

I am wondering what should be the expectation here. Is there a minimum 
version of dejagnu that can be expected from the users ?

Thanks
Indu

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Question regarding min reqd dejagnu version
  2022-10-01  0:18 Question regarding min reqd dejagnu version Indu Bhagat
@ 2022-10-03 10:23 ` Nick Clifton
  2022-10-03 17:55   ` Indu Bhagat
  0 siblings, 1 reply; 9+ messages in thread
From: Nick Clifton @ 2022-10-03 10:23 UTC (permalink / raw)
  To: Indu Bhagat, binutils

Hi Indu,

> I am wondering what should be the expectation here. Is there a minimum version of dejagnu that can be expected from the users ?

At the moment, no.  There nearest thing that I could find was this text in
gdb/README:

    Running the testsuite requires the prior installation of DejaGNU,
    which is generally available via ftp.  The directory
    ftp://sources.redhat.com/pub/dejagnu/ will contain a recent snapshot.

There is a function to test for dejagnu.h in config/acinclude.m4, but as
far as I can tell it is never used.

Based upon what you have discovered I would guess that a minimum of
Dejagnu 1.5.3 is required, do you agree ?  (I was going to suggest 1.5.2
but it appears that the 1.5.3 release came out a month later, which
suggests that it was issued in order to fix an important bug).

Cheers
   Nick


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Question regarding min reqd dejagnu version
  2022-10-03 10:23 ` Nick Clifton
@ 2022-10-03 17:55   ` Indu Bhagat
  2022-10-04  9:52     ` Nick Clifton
  0 siblings, 1 reply; 9+ messages in thread
From: Indu Bhagat @ 2022-10-03 17:55 UTC (permalink / raw)
  To: Nick Clifton, binutils

On 10/3/22 03:23, Nick Clifton wrote:
> Hi Indu,
> 
>> I am wondering what should be the expectation here. Is there a minimum 
>> version of dejagnu that can be expected from the users ?
> 
> At the moment, no.  There nearest thing that I could find was this text in
> gdb/README:
> 
>     Running the testsuite requires the prior installation of DejaGNU,
>     which is generally available via ftp.  The directory
>     ftp://sources.redhat.com/pub/dejagnu/ will contain a recent snapshot.
> 
> There is a function to test for dejagnu.h in config/acinclude.m4, but as
> far as I can tell it is never used.
> 
> Based upon what you have discovered I would guess that a minimum of
> Dejagnu 1.5.3 is required, do you agree ?  (I was going to suggest 1.5.2
> but it appears that the 1.5.3 release came out a month later, which
> suggests that it was issued in order to fix an important bug).
> 

You're right - with dejagnu 1.5.2, libsframe testsuite works well. The 
specific commit that fixes this issue should be:

ad36659 Steve Ellcey    2014-10-24    * dejagnu.h (pass): Make function 
static as well as inline.

 From the release notes, the following two commits which made to 1.5.3 
seem relevant (perhaps especially the first one) -

5256bd8 H.J. Lu 2015-02-26  * lib/target.exp (default_target_compile): 
Prepend multilib_flags, instead of appending it.
3249854 Stephen Tridgell 2015-02-18 * lib/framework.exp (log_and_exit): 
Set tool to "testrun" if unset.

Thanks

> Cheers
>    Nick
> 


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Question regarding min reqd dejagnu version
  2022-10-03 17:55   ` Indu Bhagat
@ 2022-10-04  9:52     ` Nick Clifton
  2022-10-04 10:05       ` Jan Beulich
  0 siblings, 1 reply; 9+ messages in thread
From: Nick Clifton @ 2022-10-04  9:52 UTC (permalink / raw)
  To: Indu Bhagat, binutils

[-- Attachment #1: Type: text/plain, Size: 311 bytes --]

Hi Guys,

   I am checking in the attached patch to update the README-maintainer-mode
   file so that it also lists a minimum version of dejagnu required to run
   the testsuites.  Whilst I was at it I noticed that the URLs needed a https:
   prefix rather than ftp:, so I changed that as well.

Cheers
   Nick

[-- Attachment #2: maintainer-mode.patch --]
[-- Type: text/x-patch, Size: 2107 bytes --]

diff --git a/README-maintainer-mode b/README-maintainer-mode
index 6d65d289c8e..fdafa692c0c 100644
--- a/README-maintainer-mode
+++ b/README-maintainer-mode
@@ -5,10 +5,10 @@ Note that if you configure with --enable-maintainer-mode, you will need
 special versions of automake, autoconf, libtool and gettext. You will
 find the sources for these in the respective upstream directories:
 
-  ftp://ftp.gnu.org/gnu/autoconf
-  ftp://ftp.gnu.org/gnu/automake
-  ftp://ftp.gnu.org/gnu/libtool
-  ftp://ftp.gnu.org/gnu/gettext
+  https://ftp.gnu.org/gnu/autoconf
+  https://ftp.gnu.org/gnu/automake
+  https://ftp.gnu.org/gnu/libtool
+  https://ftp.gnu.org/gnu/gettext
 
 The required versions of the tools for this tree are:
 
@@ -24,3 +24,12 @@ Makefiles in the parent directories before running the Makefiles in
 the child directories.  There is no easy way around this (short of
 changing the automake macros) as these dependencies need to exist in
 order to correctly build the NLS files.
+
+When running the testsuites a minimum version of dejagnu is also needed.
+Dejagnu can be found here:
+
+  https://ftp.gnu.org/gnu/dejagnu/
+
+The minimum version required is:
+
+  dejagnu 1.5.3
diff --git a/src-release.sh b/src-release.sh
index 079b545ae7c..de1f98a70bb 100755
--- a/src-release.sh
+++ b/src-release.sh
@@ -184,9 +184,15 @@ do_tar()
     ver=$2
     echo "==> Making $package-$ver.tar"
     rm -f $package-$ver.tar
+    # The sort command and --mtime, --group and --owner options are
+    # used in order to create consistent, reproducible tarballs.
+    # BUILD_DATE is set to SOURCE_DATE_EPOCH if defined, or the
+    # modification date of this file otherwise.  cf:
+    # https://reproducible-builds.org/docs/source-date-epoch/
+    BUILD_DATE="$(date --utc --date="@${SOURCE_DATE_EPOCH:-$(date -r src-release.sh +%s)}" +%Y-%m-%d)"
     find $package-$ver -follow \( $CVS_NAMES \) -prune \
-	-o -type f -print \
-	| tar cTfh - $package-$ver.tar
+	-o -type f -print | LC_ALL=C sort \
+	| tar cTfh - $package-$ver.tar --mtime=$BUILD_DATE --group=0 --owner=0
 }
 
 # Compress the output with bzip2

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Question regarding min reqd dejagnu version
  2022-10-04  9:52     ` Nick Clifton
@ 2022-10-04 10:05       ` Jan Beulich
  2022-10-04 10:20         ` Nick Clifton
  0 siblings, 1 reply; 9+ messages in thread
From: Jan Beulich @ 2022-10-04 10:05 UTC (permalink / raw)
  To: Nick Clifton; +Cc: Indu Bhagat, binutils

On 04.10.2022 11:52, Nick Clifton via Binutils wrote:
> Hi Guys,
> 
>    I am checking in the attached patch to update the README-maintainer-mode
>    file so that it also lists a minimum version of dejagnu required to run
>    the testsuites.  Whilst I was at it I noticed that the URLs needed a https:
>    prefix rather than ftp:, so I changed that as well.

I'm concerned: We support building with pretty old gcc. The minimum
dejagnu version is now much newer, which will require me to see if I
can sensibly build myself a newer version of it on some of my older
systems, not even thinking of yet whether it'll be possible to
install the newer version side by side with the distro provided one.

Also - is this patch really meant to also change src-release.sh?

Jan

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Question regarding min reqd dejagnu version
  2022-10-04 10:05       ` Jan Beulich
@ 2022-10-04 10:20         ` Nick Clifton
  2022-10-04 10:27           ` Jan Beulich
  0 siblings, 1 reply; 9+ messages in thread
From: Nick Clifton @ 2022-10-04 10:20 UTC (permalink / raw)
  To: Jan Beulich; +Cc: Indu Bhagat, binutils

Hi Jan,

>>     I am checking in the attached patch to update the README-maintainer-mode
>>     file so that it also lists a minimum version of dejagnu required to run
>>     the testsuites.

> I'm concerned: We support building with pretty old gcc. The minimum
> dejagnu version is now much newer, which will require me to see if I
> can sensibly build myself a newer version of it on some of my older
> systems, not even thinking of yet whether it'll be possible to
> install the newer version side by side with the distro provided one.

Well the intent of the change was to ensure that we are using a version
of dejagnu that will work with gcc version 5 or later, which seems pretty
old to me.  Do you have a suggestion for a better minimum version, or do
you think that instead tests that do require newer versions of dejagnu
should check for that before they run ?


> Also - is this patch really meant to also change src-release.sh?

Did that go in ?  I thought that I had managed to keep it out.  I will check.

Cheers
   Nick



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Question regarding min reqd dejagnu version
  2022-10-04 10:20         ` Nick Clifton
@ 2022-10-04 10:27           ` Jan Beulich
  2022-10-04 11:40             ` Nick Clifton
  0 siblings, 1 reply; 9+ messages in thread
From: Jan Beulich @ 2022-10-04 10:27 UTC (permalink / raw)
  To: Nick Clifton; +Cc: Indu Bhagat, binutils

On 04.10.2022 12:20, Nick Clifton wrote:
>>>     I am checking in the attached patch to update the README-maintainer-mode
>>>     file so that it also lists a minimum version of dejagnu required to run
>>>     the testsuites.
> 
>> I'm concerned: We support building with pretty old gcc. The minimum
>> dejagnu version is now much newer, which will require me to see if I
>> can sensibly build myself a newer version of it on some of my older
>> systems, not even thinking of yet whether it'll be possible to
>> install the newer version side by side with the distro provided one.
> 
> Well the intent of the change was to ensure that we are using a version
> of dejagnu that will work with gcc version 5 or later, which seems pretty
> old to me.  Do you have a suggestion for a better minimum version, or do
> you think that instead tests that do require newer versions of dejagnu
> should check for that before they run ?

I think checking for features before use would be the preferred way to go.
What I could see (albeit personally I'd dislike it) is the setting of a
coherent baseline of tools needed to build the tree (which would in
particular include a baseline gcc version).

>> Also - is this patch really meant to also change src-release.sh?
> 
> Did that go in ?  I thought that I had managed to keep it out.  I will check.

My reply was solely based on the attachment in your mail.

Jan

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Question regarding min reqd dejagnu version
  2022-10-04 10:27           ` Jan Beulich
@ 2022-10-04 11:40             ` Nick Clifton
  2022-10-05 18:28               ` Indu Bhagat
  0 siblings, 1 reply; 9+ messages in thread
From: Nick Clifton @ 2022-10-04 11:40 UTC (permalink / raw)
  To: Jan Beulich, Indu Bhagat; +Cc: binutils

Hi Indu,

On 10/4/22 11:27, Jan Beulich wrote:
>> Do you have a suggestion for a better minimum version, or do
>> you think that instead tests that do require newer versions of dejagnu
>> should check for that before they run ?
> 
> I think checking for features before use would be the preferred way to go.
Would that work for you ?  Ie could you test for a minimum dejangu version
before attempting to compile your test source files ?

Cheers
   Nick


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Question regarding min reqd dejagnu version
  2022-10-04 11:40             ` Nick Clifton
@ 2022-10-05 18:28               ` Indu Bhagat
  0 siblings, 0 replies; 9+ messages in thread
From: Indu Bhagat @ 2022-10-05 18:28 UTC (permalink / raw)
  To: Nick Clifton, Jan Beulich; +Cc: binutils

On 10/4/22 04:40, Nick Clifton wrote:
> Hi Indu,
> 
> On 10/4/22 11:27, Jan Beulich wrote:
>>> Do you have a suggestion for a better minimum version, or do
>>> you think that instead tests that do require newer versions of dejagnu
>>> should check for that before they run ?
>>
>> I think checking for features before use would be the preferred way to 
>> go.
> Would that work for you ?  Ie could you test for a minimum dejangu version
> before attempting to compile your test source files ?
> 

That should work as well. I will try it out.

Thanks


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2022-10-05 18:28 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-01  0:18 Question regarding min reqd dejagnu version Indu Bhagat
2022-10-03 10:23 ` Nick Clifton
2022-10-03 17:55   ` Indu Bhagat
2022-10-04  9:52     ` Nick Clifton
2022-10-04 10:05       ` Jan Beulich
2022-10-04 10:20         ` Nick Clifton
2022-10-04 10:27           ` Jan Beulich
2022-10-04 11:40             ` Nick Clifton
2022-10-05 18:28               ` Indu Bhagat

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).