Global network block device, using gnbd with red hat global file system (24 pages)
Summary of Contents for Red Hat ENTERPRISE LINUX 4 - DEVELOPER TOOLS GUIDE
Page 1
Red Hat Enterprise Linux 4 Developer Tools Guide...
Page 2
All other trademarks referenced herein are the property of their respective owners. The GPG fingerprint of the security@redhat.com key is: CA 20 86 86 2B D6 9D FC 65 F6 EC C4 21 91 80 CD DB 42 A6 0E...
Table of Contents 1. Overview of Red Hat Enterprise Linux Developer Tools............1 2. Basic Principles of the Tools......................3 2.1. Compiler and Development Tools ..................3 2.2. Libraries ..........................3 2.3. Auxiliary Development Tools .................... 4 2.4. , the GNU Compiler Collection................... 4 2.5.
Using binutils, the Gnu Binary Utilities • HTML, PDF, and RPM versions of the manuals are available on the Documentation CD and online at http://www.redhat.com/docs/. For more information on the tools and their history, see the following websites: http://sources.redhat.com/ •...
Page 6
Chapter 1. Overview of Red Hat Enterprise Linux Developer Tools...
Chapter 2. Basic Principles of the Tools Red Hat Enterprise Linux Developer Tools’s C and C++ compilers, macro-assembler, debugger, bi- nary utilities, libraries, and other development tools provide productivity, flexibility, performance, and portability. This chapter begins with a summary of the tools, then describes each tool in more detail. To use a tool, open your system’s terminal shell window and enter the tool’s name as a command , for instance, invokes the compiler.
Chapter 2. Basic Principles of the Tools 2.2. Libraries Library Description ANSI C runtime library libc C math subroutine library libm C++ class library libstdc++ 2.3. Auxiliary Development Tools The following components are also provided for general development: Component Description Assembler (refer to Section 2.6 , the GNU Assembler and Using as, the Gnu Assembler)
Page 9
Chapter 2. Basic Principles of the Tools GNU preprocessor that processes all the header files and macros that your target requires (refer • to Section 2.5 , the GNU Preprocessor). GNU assembler that produces binary code from assembly language code and puts it in an object •...
Chapter 2. Basic Principles of the Tools For more information on the GNU compiler and its options, refer to Using the GNU Compiler Col- lection (GCC). 2.5. , the GNU Preprocessor is a C-compatible macro preprocessor that works with the GNU compiler to direct the parsing of C preprocessor directives.
Chapter 2. Basic Principles of the Tools 2.6.1. Object Files The assembler creates object files that, by convention, have the extension. These are binary files that contain the assembled source code, information to help the linker integrate the object file into an executable program, debugging information and tables of all of the symbols used in the source code.
Chapter 2. Basic Principles of the Tools The linker is controlled by a linker script which is a text file containing commands in a simple lan- guage. The main purpose of the script is to describe how sections in the input files should be mapped into sections in the output file and to control memory layout of the output file.
Chapter 2. Basic Principles of the Tools . The has rules which explain how and when to remake certain files that are the makefile makefile targets of a particular rule. A simple rule has the following form: makefile target... : dependency... command target is usually the name of a file that a program generates;...
Chapter 2. Basic Principles of the Tools depends on eight object files; the object file, , depends on the source file, , and on main.o main.c header file. A shell command follows each line that contains a target and dependencies, defs.h saying how to update the target file;...
2.13. Learn More About the Tools There are many sources to teach you more about GNU tools: For general information about the tools, see: http://www.redhat.com/docs/manuals/gnupro/ • For help with using the tools, see Chapter 3 Developing with Red Hat Enterprise Linux Developer •...
Page 16
Chapter 2. Basic Principles of the Tools...
Developer Tools Use the tutorials in this chapter to learn about standard native development with the tools. See http://www.redhat.com/docs/manuals/gnupro/ for details about the tools. 3.1. Create Source Code To start, create the following sample source code file and save it as .
Chapter 3. Developing with Red Hat Enterprise Linux Developer Tools 3.3. Run the Executable To run the program, use the following example: ./hello The program generates hello world! 3 + 4 = 7 and returns when the program exits. 3.4. Debug the Executable To start GDB, use the following commands: gdb hello After the initial copyright and configuration information, GDB returns its own prompt,...
Page 19
Chapter 3. Developing with Red Hat Enterprise Linux Developer Tools The following output displays: main (void) int b; a = 3; b = 4; printf ("Hello, world!\n"); foo (b); return 0; 7. To list a specific function code, use the command with the name of the function to be list display.
Chapter 3. Developing with Red Hat Enterprise Linux Developer Tools #1 0x15c in main () at hello.c:18 13. To exit the program and quit the debugger, type: quit 3.5. Assembler Listings The compiler normally turns a text based source file into a binary object file. It is possible however to instruct it to just convert the source code into assembler and stop there.
Page 21
Chapter 3. Developing with Red Hat Enterprise Linux Developer Tools You could also use the option to produce a dissassembly of all of the sections in an object file, not only those that have been marked as containing instructions, and to tell to disassemble objdump...
Page 22
Chapter 3. Developing with Red Hat Enterprise Linux Developer Tools...
Need help?
Do you have a question about the ENTERPRISE LINUX 4 - DEVELOPER TOOLS GUIDE and is the answer not in the manual?
Questions and answers