Skip to content

Instantly share code, notes, and snippets.

Created July 21, 2015 05:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/8b4868870690d9af7c77 to your computer and use it in GitHub Desktop.
Save anonymous/8b4868870690d9af7c77 to your computer and use it in GitHub Desktop.
cat str1.cc
#include <iostream>
#include <string>
using std::cin;
using std::cout;
using std::endl;
using std::string;
int main()
{
string word;
while (cin >> word)
cout << word << endl;
return 0;
}
g++ str1.cc -o str1 -v
使用内建 specs。
COLLECT_GCC=g++
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/lto-wrapper
目标:x86_64-unknown-linux-gnu
配置为:/build/gcc/src/gcc-5-20150623/configure --prefix=/usr --libdir=/usr/lib --libexecdir=/usr/lib --mandir=/usr/share/man --infodir=/usr/share/info --with-bugurl=https://bugs.archlinux.org/ --enable-languages=c,c++,ada,fortran,go,lto,objc,obj-c++ --enable-shared --enable-threads=posix --enable-libmpx --with-system-zlib --with-isl --enable-__cxa_atexit --disable-libunwind-exceptions --enable-clocale=gnu --disable-libstdcxx-pch --disable-libssp --enable-gnu-unique-object --enable-linker-build-id --enable-lto --enable-plugin --enable-install-libiberty --with-linker-hash-style=gnu --enable-gnu-indirect-function --disable-multilib --disable-werror --enable-checking=release --with-default-libstdcxx-abi=c++98
线程模型:posix
gcc 版本 5.1.0 (GCC)
COLLECT_GCC_OPTIONS='-o' 'str1' '-v' '-shared-libgcc' '-mtune=generic' '-march=x86-64'
/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/cc1plus -quiet -v -D_GNU_SOURCE str1.cc -quiet -dumpbase str1.cc -mtune=generic -march=x86-64 -auxbase str1 -version -o /tmp/ccXbss8T.s
GNU C++ (GCC) 版本 5.1.0 (x86_64-unknown-linux-gnu)
由 GNU C 版本 5.1.0 编译,GMP 版本 6.0.0,MPFR 版本 3.1.3,MPC 版本 1.0.3
GGC 准则:--param ggc-min-expand=100 --param ggc-min-heapsize=131072
忽略不存在的目录“/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/../../../../x86_64-unknown-linux-gnu/include”
#include "..." 搜索从这里开始:
#include <...> 搜索从这里开始:
/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/../../../../include/c++/5.1.0
/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/../../../../include/c++/5.1.0/x86_64-unknown-linux-gnu
/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/../../../../include/c++/5.1.0/backward
/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/include
/usr/local/include
/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/include-fixed
/usr/include
搜索列表结束。
GNU C++ (GCC) 版本 5.1.0 (x86_64-unknown-linux-gnu)
由 GNU C 版本 5.1.0 编译,GMP 版本 6.0.0,MPFR 版本 3.1.3,MPC 版本 1.0.3
GGC 准则:--param ggc-min-expand=100 --param ggc-min-heapsize=131072
Compiler executable checksum: bef244f5ce8228ea2394aa2f911d34e3
COLLECT_GCC_OPTIONS='-o' 'str1' '-v' '-shared-libgcc' '-mtune=generic' '-march=x86-64'
as -v --64 -o /tmp/ccSir5Ga.o /tmp/ccXbss8T.s
GNU assembler version 2.25.0 (x86_64-unknown-linux-gnu) using BFD version (GNU Binutils) 2.25.0
COMPILER_PATH=/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/:/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/:/usr/lib/gcc/x86_64-unknown-linux-gnu/:/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/:/usr/lib/gcc/x86_64-unknown-linux-gnu/
LIBRARY_PATH=/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/:/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/../../../../lib/:/lib/../lib/:/usr/lib/../lib/:/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/../../../:/lib/:/usr/lib/
COLLECT_GCC_OPTIONS='-o' 'str1' '-v' '-shared-libgcc' '-mtune=generic' '-march=x86-64'
/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/collect2 -plugin /usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/liblto_plugin.so -plugin-opt=/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/lto-wrapper -plugin-opt=-fresolution=/tmp/ccOUQ1Er.res -plugin-opt=-pass-through=-lgcc_s -plugin-opt=-pass-through=-lgcc -plugin-opt=-pass-through=-lc -plugin-opt=-pass-through=-lgcc_s -plugin-opt=-pass-through=-lgcc --build-id --eh-frame-hdr --hash-style=gnu -m elf_x86_64 -dynamic-linker /lib64/ld-linux-x86-64.so.2 -o str1 /usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/../../../../lib/crt1.o /usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/../../../../lib/crti.o /usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/crtbegin.o -L/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0 -L/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/../../../../lib -L/lib/../lib -L/usr/lib/../lib -L/usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/../../.. /tmp/ccSir5Ga.o -lstdc++ -lm -lgcc_s -lgcc -lc -lgcc_s -lgcc /usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/crtend.o /usr/lib/gcc/x86_64-unknown-linux-gnu/5.1.0/../../../../lib/crtn.o
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment