diff options
author | pfg <pfg@FreeBSD.org> | 2014-01-02 13:53:53 +0000 |
---|---|---|
committer | pfg <pfg@FreeBSD.org> | 2014-01-02 13:53:53 +0000 |
commit | 6053c493e0e2a18f4e546f35ab4b1d119a2b8baa (patch) | |
tree | 5f444ea4148b370cd2253753252a21e4e28c5e7a /contrib/gcc/cp | |
parent | 541c54820f14b6c054df1b29b785d8aca7911f23 (diff) | |
download | FreeBSD-src-6053c493e0e2a18f4e546f35ab4b1d119a2b8baa.zip FreeBSD-src-6053c493e0e2a18f4e546f35ab4b1d119a2b8baa.tar.gz |
Revert r260073; small diff reduction wrt gcc43 and Apple GCC.
Unfortunately this causes ICE on powerpc and sparc64.
Reducing these differences against upstream is not important
anymore so hopefully I have finished breaking the compiler
occasionally.
Diffstat (limited to 'contrib/gcc/cp')
-rw-r--r-- | contrib/gcc/cp/ChangeLog | 6 | ||||
-rw-r--r-- | contrib/gcc/cp/g++spec.c | 17 |
2 files changed, 8 insertions, 15 deletions
diff --git a/contrib/gcc/cp/ChangeLog b/contrib/gcc/cp/ChangeLog index a79ed04..7629e8b 100644 --- a/contrib/gcc/cp/ChangeLog +++ b/contrib/gcc/cp/ChangeLog @@ -314,12 +314,6 @@ PR c++/30895 * tree.c (cp_tree_equal): Properly handle COMPLEX_CST trees. -2007-03-02 Geoffrey Keating <geoffk@apple.com> (r122488) - - * g++spec.c (lang_specific_driver): Add -lstdc++ when compiling - Objective-C++. Don't exit early if -shared-libgcc needs to be - added. - 2007-02-22 Simon Martin <simartin@users.sourceforge.net> PR c++/29475 diff --git a/contrib/gcc/cp/g++spec.c b/contrib/gcc/cp/g++spec.c index 0d3a442..b58fdcd 100644 --- a/contrib/gcc/cp/g++spec.c +++ b/contrib/gcc/cp/g++spec.c @@ -159,19 +159,11 @@ lang_specific_driver (int *in_argc, const char *const **in_argv, arg = ""; if (library == 0 && (strcmp (arg, "c++") == 0 - || strcmp (arg, "c++-cpp-output") == 0 - || strcmp (arg, "objective-c++") == 0 - || strcmp (arg, "objective-c++-cpp-output") == 0)) + || strcmp (arg, "c++-cpp-output") == 0)) library = 1; saw_speclang = 1; } - else if (strcmp (argv[i], "-ObjC++") == 0) - { - if (library == 0) - library = 1; - saw_speclang = 1; - } /* Arguments that go directly to the linker might be .o files, or something, and so might cause libstdc++ to be needed. */ else if (strcmp (argv[i], "-Xlinker") == 0) @@ -245,6 +237,13 @@ lang_specific_driver (int *in_argc, const char *const **in_argv, if (quote) fatal ("argument to '%s' missing\n", quote); + /* If we know we don't have to do anything, bail now. */ + if (! added && library <= 0) + { + free (args); + return; + } + /* There's no point adding -shared-libgcc if we don't have a shared libgcc. */ #ifndef ENABLE_SHARED_LIBGCC |