-
C언어에서 gcc -Wall -save-temps main.c 하면 나오는 파일들main.o / main.i / main.s코딩Coding/make★gcc★&g++★clang★compiler 2022. 1. 27. 10:54728x90
10분59초에 나옴
gcc -Wall -save-temps main.c -o harry
하면
파일이
main.o
main.i
main.s
파일들에 대해서
https://youtu.be/5SIBB589fAg
다른 출처 stackoverflow
https://stackoverflow.com/questions/25137743/where-do-we-use-i-files-and-how-do-we-generate-themWhere do we use .i files and how do we generate them?
I was going through the GCC man page, I found the following line: file.i C source code that should not be preprocessed. I know that running gcc -E foo.c stops the compiler after
stackoverflow.com
foo # compiled binary program (AKA: combined "object file",
# "executable", "binary", "program", or "machine code")
foo.i # intermediate, preprocessed C file
foo.o # individual object file
foo.s # assembly file
https://stackoverflow.com/questions/25137743/where-do-we-use-i-files-and-how-do-we-generate-them
main.o
A file ending in .o is an object file. The compiler creates an object file for each source file, before linking them together, into the final executable.
# individual object file
main.i
foo.i
# intermediate, preprocessed C file
main.s
.S files are source code files written in assembly
어셈블리어 파일
# assembly file
https://www.geeksforgeeks.org/types-of-c-files-after-its-compilation/Types of C files after its compilation - GeeksforGeeks
A Computer Science portal for geeks. It contains well written, well thought and well explained computer science and programming articles, quizzes and practice/competitive programming/company interview Questions.
www.geeksforgeeks.org
What are .o files?
https://stackoverflow.com/questions/2186246/what-is-o-fileWhat is *.o file?
I'm compiling own project. And it halted by this error: LINK||fatal error LNK1181: cannot open input file 'obj\win\release\src\lua\bindings.o'| Compiling using Code::Blocks with VS 2005/2008
stackoverflow.com
What are .i files?
https://pvs-studio.com/en/blog/terms/0076/Preprocessed *.i file
A preprocessed *.i file is an output of the C or C++ preprocessor. It is usually this extension which is characteristic of files created as the preprocessor output. The preprocessor performs primary transformations of the source program text using only lex
pvs-studio.com
.s
.S files are source code files written in assembly
https://stackoverflow.com/questions/10285410/what-are-s-files/51110745What are .S files?
I've seen .S files in various projects such as in the Linux Kernel, FreeBSD kernel, or in some other projects. What do these files do and why can't we have .c files instead ?
stackoverflow.com
반응형'코딩Coding > make★gcc★&g++★clang★compiler' 카테고리의 다른 글
GCC - compilation en C/C++(프랑스어라 자동번역 해야함) (0) 2022.02.18 how to use c++20 / g++ -std=c++11 -o test test.cpp (build.sh❤️파일 만드는법) (0) 2022.02.18 GCC 오류 설명서 (0) 2022.02.18 ln: g++: File exists /(이렇게 에러나면)What is a "failed to create a symbolic link: file exists" error? (0) 2022.02.18 gcc-g memory.c -o memory ./valgrind .memory (bash) (0) 2022.02.05 Ubuntu]GCC를 사용하여 C프로그램 캄파일 후 실행 하기& Upgrade gcc and g++ in Ubuntu (0) 2021.12.20 Installing the GCC(C++ Compiler in macOS)& ❤️Apple M1 프로세서가 탑재된 최신 MacBook의 경우(경로 (0) 2021.12.20 C++]gcc로 컴파일 하는 방법(./ a.out 검색하다가 알게 됨) (0) 2021.11.29