Operating System/System Programming(Arif Butt) 30

Lec11) Design and Code of UNIX more utility

notice it is just displaying only the first file. let's fix this issue. we add while loop and used "argv[i]" instead of "argv[1]" . this way we can iteratively stdout files. now it works fine. #include #include #definePAGELEN20 #defineLINELEN512 void do_more(FILE *); int get_input(); int main(int argc , char *argv[]) { int i=0; if (argc == 1){ printf("This is the help page\n"); exit (0); } FILE ..

Lec03) Working of Linkers: Creating your own Libraries

every .o file start with 0 memory address. relocate symbols from thier relative locations in the .o files to their final absolute memory location in the executables. Global symbol = that are defined in one module and can be reference by other module. External symbol = Gobal symbol that are referenced by a module but are defined in some other module. declared with 'external' keyword Local symbol ..

Lec02) C Compilation: A System Programmer Perspective

-E = Stop after the preprocessing stage. the output is form of preprocessed soruce code. -S = Stop after the stage of compilation proper. don't assemble. form of an assembler code file for each non-assembler input file specified. basically just do compilation -c = Compile or assemble the source files, but don't link. output is form of an object file for each source file. -ggdb = Produce debuggin..

Lec1) Introduction to System Programming

Application progamming = aims to produce software which provides services to the user, e.g., word processors, browsers, multi-media applications System programming = aims to produce software which provides services to computer hardware , disk defragmenter. The next step is writing kernel code to manage main memory , disk space management, cpu scheduling and management of I/O devices through devi..

1 2 3