* (patch) hpjyg17: gdb testsuite compiler.c(c)
@ 1999-11-09 12:23 Jimmy Guo
1999-11-10 21:19 ` Stan Shebs
0 siblings, 1 reply; 2+ messages in thread
From: Jimmy Guo @ 1999-11-09 12:23 UTC (permalink / raw)
To: gdb-patches
This patch moves compiler.c / compiler.cc to testsuite/lib/, and
modifies gdb.exp (get_compiler_info) to locate these two files from
$srcdir/lib/ instead of $srcdir/$subdir.
The reason for this change is to eliminate multiple copies of these two
files from existing (or future) test suite directories.
When applying this patch, please also remove existing compiler.c(c)
files from testsuite/gdb.* and testsuite/gdb.*/gdb.*/. Thanks.
ChangeLog
1999-11-09 Jimmy Guo <guo@cup.hp.com>
* gdb.exp (get_compiler_info): pick up compiler.c compiler.cc
from $srcdir/lib/.
* compiler.c,compiler.cc: New files, moved from gdb.base/ and
gdb.c++/.
Index: gdb/testsuite/lib/gdb.exp
/opt/gnu/bin/diff -r -c -N /view/guo.import//CLO/Components/WDB/Src/gnu/gdb/testsuite/lib/gdb.exp gdb/testsuite/lib/gdb.exp
*** /view/guo.import//CLO/Components/WDB/Src/gnu/gdb/testsuite/lib/gdb.exp Tue Nov 9 11:19:29 1999
--- gdb/testsuite/lib/gdb.exp Tue Nov 9 12:15:19 1999
***************
*** 901,913 ****
if {![istarget "hppa*-*-hpux*"]} {
if { [llength $args] > 0 } {
if {$args == "c++"} {
! if { [gdb_compile "${srcdir}/${subdir}/compiler.cc" "${binfile}.ci" preprocess {}] != "" } {
perror "Couldn't make ${binfile}.ci file"
return 1;
}
}
} else {
! if { [gdb_compile "${srcdir}/${subdir}/compiler.c" "${binfile}.ci" preprocess {}] != "" } {
perror "Couldn't make ${binfile}.ci file"
return 1;
}
--- 901,913 ----
if {![istarget "hppa*-*-hpux*"]} {
if { [llength $args] > 0 } {
if {$args == "c++"} {
! if { [gdb_compile "${srcdir}/lib/compiler.cc" "${binfile}.ci" preprocess {}] != "" } {
perror "Couldn't make ${binfile}.ci file"
return 1;
}
}
} else {
! if { [gdb_compile "${srcdir}/lib/compiler.c" "${binfile}.ci" preprocess {}] != "" } {
perror "Couldn't make ${binfile}.ci file"
return 1;
}
***************
*** 916,922 ****
if { [llength $args] > 0 } {
if {$args == "c++"} {
if { [eval gdb_preprocess \
! [list "${srcdir}/${subdir}/compiler.cc" "${binfile}.ci"] \
$args] != "" } {
perror "Couldn't make ${binfile}.ci file"
return 1;
--- 916,922 ----
if { [llength $args] > 0 } {
if {$args == "c++"} {
if { [eval gdb_preprocess \
! [list "${srcdir}/lib/compiler.cc" "${binfile}.ci"] \
$args] != "" } {
perror "Couldn't make ${binfile}.ci file"
return 1;
***************
*** 924,930 ****
}
} elseif { $args != "f77" } {
if { [eval gdb_preprocess \
! [list "${srcdir}/${subdir}/compiler.c" "${binfile}.ci"] \
$args] != "" } {
perror "Couldn't make ${binfile}.ci file"
return 1;
--- 924,930 ----
}
} elseif { $args != "f77" } {
if { [eval gdb_preprocess \
! [list "${srcdir}/lib/compiler.c" "${binfile}.ci"] \
$args] != "" } {
perror "Couldn't make ${binfile}.ci file"
return 1;
Index: gdb/testsuite/lib/compiler.c
/opt/gnu/bin/diff -r -c -N /view/guo.import//CLO/Components/WDB/Src/gnu/gdb/testsuite/lib/compiler.c gdb/testsuite/lib/compiler.c
*** /view/guo.import//CLO/Components/WDB/Src/gnu/gdb/testsuite/lib/compiler.c Tue Nov 9 12:22:00 1999
--- gdb/testsuite/lib/compiler.c Fri Oct 16 14:01:54 1998
***************
*** 0 ****
--- 1,31 ----
+ /* Often the behavior of any particular test depends upon what compiler was
+ used to compile the test. As each test is compiled, this file is
+ preprocessed by the same compiler used to compile that specific test
+ (different tests might be compiled by different compilers, particularly
+ if compiled at different times), and used to generate a *.ci (compiler
+ info) file for that test.
+
+ I.E., when callfuncs is compiled, a callfuncs.ci file will be generated,
+ which can then be sourced by callfuncs.exp to give callfuncs.exp access
+ to information about the compilation environment.
+
+ TODO: It might be a good idea to add expect code that tests each
+ definition made with 'set" to see if one already exists, and if so
+ warn about conflicts if it is being set to something else. */
+
+ /* This needs to be kept in sync with whatis.c and gdb.exp(get_compiler_info).
+ If this ends up being hairy, we could use a common header file. */
+
+ #if defined (__STDC__) || defined (_AIX)
+ set signed_keyword_not_used 0
+ #else
+ set signed_keyword_not_used 1
+ #endif
+
+ #if defined (__GNUC__)
+ set gcc_compiled __GNUC__
+ #else
+ set gcc_compiled 0
+ #endif
+
+ return 0
Index: gdb/testsuite/lib/compiler.cc
/opt/gnu/bin/diff -r -c -N /view/guo.import//CLO/Components/WDB/Src/gnu/gdb/testsuite/lib/compiler.cc gdb/testsuite/lib/compiler.cc
*** /view/guo.import//CLO/Components/WDB/Src/gnu/gdb/testsuite/lib/compiler.cc Tue Nov 9 12:22:00 1999
--- gdb/testsuite/lib/compiler.cc Tue Oct 27 17:24:59 1998
***************
*** 0 ****
--- 1,34 ----
+ /* Often the behavior of any particular test depends upon what compiler was
+ used to compile the test. As each test is compiled, this file is
+ preprocessed by the same compiler used to compile that specific test
+ (different tests might be compiled by different compilers, particularly
+ if compiled at different times), and used to generate a *.ci (compiler
+ info) file for that test.
+
+ I.E., when callfuncs is compiled, a callfuncs.ci file will be generated,
+ which can then be sourced by callfuncs.exp to give callfuncs.exp access
+ to information about the compilation environment.
+
+ TODO: It might be a good idea to add expect code that tests each
+ definition made with 'set" to see if one already exists, and if so
+ warn about conflicts if it is being set to something else. */
+
+ #if defined(__GNUC__) && __GNUC__ >= 2 && __GNUC_MINOR__ >= 6
+ set supports_template_debugging 1
+ #else
+ set supports_template_debugging 0
+ #endif
+
+ #if defined(__cplusplus)
+ set supports_template_debugging 1
+ #else
+ set supports_template_debugging 0
+ #endif
+
+ #if defined (__GNUC__)
+ set gcc_compiled __GNUC__
+ #else
+ set gcc_compiled 0
+ #endif
+
+ return 0
^ permalink raw reply [flat|nested] 2+ messages in thread* Re: (patch) hpjyg17: gdb testsuite compiler.c(c)
1999-11-09 12:23 (patch) hpjyg17: gdb testsuite compiler.c(c) Jimmy Guo
@ 1999-11-10 21:19 ` Stan Shebs
0 siblings, 0 replies; 2+ messages in thread
From: Stan Shebs @ 1999-11-10 21:19 UTC (permalink / raw)
To: guo; +Cc: gdb-patches
Date: Tue, 9 Nov 1999 12:22:47 -0800 (PST)
From: Jimmy Guo <guo@cup.hp.com>
This patch moves compiler.c / compiler.cc to testsuite/lib/, and
modifies gdb.exp (get_compiler_info) to locate these two files from
$srcdir/lib/ instead of $srcdir/$subdir.
The reason for this change is to eliminate multiple copies of these two
files from existing (or future) test suite directories.
When applying this patch, please also remove existing compiler.c(c)
files from testsuite/gdb.* and testsuite/gdb.*/gdb.*/. Thanks.
Thanks very much! I've committed this to the repository.
Stan
From shebs@cygnus.com Wed Nov 10 21:24:00 1999
From: Stan Shebs <shebs@cygnus.com>
To: guo@cup.hp.com
Cc: gdb-patches@sourceware.cygnus.com
Subject: Re: (patch) hpjyg18: derivation.exp
Date: Wed, 10 Nov 1999 21:24:00 -0000
Message-id: <199911110524.VAA28647@andros.cygnus.com>
References: <Pine.LNX.4.10.9911100932480.29436-100000@hpcll168.cup.hp.com>
X-SW-Source: 1999-q4/msg00227.html
Content-length: 271
Date: Wed, 10 Nov 1999 09:41:20 -0800 (PST)
From: Jimmy Guo <guo@cup.hp.com>
***
This patch goes with hpjyg17 -- compiler.c(c) location change.
***
Yes indeed, becomes obvious when the previous change is tested! This
one is now committed.
Stan
From taylor@cygnus.com Thu Nov 11 08:13:00 1999
From: David Taylor <taylor@cygnus.com>
To: Jimmy Guo <guo@cup.hp.com>
Cc: gdb-patches@sourceware.cygnus.com
Subject: Re: 2nd try: (patch) hpjyg03: (buildsym|language).[ch]
Date: Thu, 11 Nov 1999 08:13:00 -0000
Message-id: <199911111603.LAA20557@texas.cygnus.com>
X-SW-Source: 1999-q4/msg00228.html
Content-length: 162
The language part of this patch is approved. I'll be replacing the
call to assert with a call to internal_error. It should be committed
in the next day or two.
From taylor@cygnus.com Thu Nov 11 08:28:00 1999
From: David Taylor <taylor@cygnus.com>
To: Jimmy Guo <guo@cup.hp.com>
Cc: gdb-patches@sourceware.cygnus.com
Subject: Re: (patch) hpjyg16: valarith.c
Date: Thu, 11 Nov 1999 08:28:00 -0000
Message-id: <199911111617.LAA20566@texas.cygnus.com>
X-SW-Source: 1999-q4/msg00229.html
Content-length: 229
Relatively minor nit -- I don't like the name my_strcmp -- it doesn't
suggest to me how it differs from the regular strcmp. Since it takes
two value_ptr arguments, how about calling it value_strcmp instead?
Otherwise approved.
From guo@cup.hp.com Thu Nov 11 09:03:00 1999
From: Jimmy Guo <guo@cup.hp.com>
To: David Taylor <taylor@cygnus.com>
Cc: gdb-patches@sourceware.cygnus.com
Subject: Re: (patch) hpjyg16: valarith.c
Date: Thu, 11 Nov 1999 09:03:00 -0000
Message-id: <Pine.LNX.4.10.9911110901580.4607-100000@hpcll168.cup.hp.com>
References: <199911111617.LAA20566@texas.cygnus.com>
X-SW-Source: 1999-q4/msg00230.html
Content-length: 273
>Relatively minor nit -- I don't like the name my_strcmp -- it doesn't
>suggest to me how it differs from the regular strcmp. Since it takes
>two value_ptr arguments, how about calling it value_strcmp instead?
value_strcmp is it. Thanks!
- Jimmy
>Otherwise approved.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~1999-11-10 21:19 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-11-09 12:23 (patch) hpjyg17: gdb testsuite compiler.c(c) Jimmy Guo
1999-11-10 21:19 ` Stan Shebs
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox