diff options
author | Kriang Lerdsuwanakij <lerdsuwa@scf-fs.usc.edu> | 1998-09-09 02:14:55 +0000 |
---|---|---|
committer | Jason Merrill <jason@yorick.cygnus.com> | 1998-09-09 02:14:55 +0000 |
commit | d1a668097d2dc802f01c54bf961f33a43c80990d (patch) | |
tree | f743ea2d36584e5a57b4445277257f28d79d5178 /gcc/cp/g++spec.c | |
parent | 694874f436504b63a6abd5ad25fafd4daa716a37 (diff) |
* class.c (get_enclosing_class): New function.
(is_base_of_enclosing_class): Likewise.
* cp-tree.h (get_enclosing_class): Declare.
(is_base_of_enclosing_class): Likewise.
* pt.c (coerce_template_parms): Use them.
* g++spec.c (lang_specific_driver): Check whether MATH_LIBRARY is
null to decide whether to use it.
git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@22343 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cp/g++spec.c')
-rw-r--r-- | gcc/cp/g++spec.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/gcc/cp/g++spec.c b/gcc/cp/g++spec.c index 542ca06f889..22060cd222d 100644 --- a/gcc/cp/g++spec.c +++ b/gcc/cp/g++spec.c @@ -34,9 +34,6 @@ Boston, MA 02111-1307, USA. */ #ifndef MATH_LIBRARY #define MATH_LIBRARY "-lm" #endif -#ifndef NEED_MATH_LIBRARY -#define NEED_MATH_LIBRARY 1 /* Default is pass MATH_LIBRARY to linker */ -#endif extern char *xmalloc PROTO((size_t)); @@ -83,8 +80,8 @@ lang_specific_driver (fn, in_argc, in_argv, in_added_libraries) LANGSPEC, MATHLIB, or WITHLIBC. */ int *args; - /* By default, we throw on the math library. */ - int need_math = NEED_MATH_LIBRARY; + /* By default, we throw on the math library if we have one. */ + int need_math = (MATH_LIBRARY[0] != '\0'); /* The total number of arguments with the new stuff. */ int argc; @@ -128,6 +125,7 @@ lang_specific_driver (fn, in_argc, in_argv, in_added_libraries) } else if (strcmp (argv[i], "-lm") == 0 || strcmp (argv[i], "-lmath") == 0 + || strcmp (argv[i], MATH_LIBRARY) == 0 #ifdef ALT_LIBM || strcmp (argv[i], ALT_LIBM) == 0 #endif |