












































Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Advanced Programming in the UNIX environment
Typology: Thesis
1 / 52
This page cannot be seen from the preview
Don't miss anything!













































CS631 - Advanced Programming in the UNIX Environment
Department of Computer Science Stevens Institute of Technology
Jan Schaumann
http://www.cs.stevens.edu/~jschauma/631/
Lecture 01: Introduction, UNIX history, UNIX Programming Basics
August 28, 2017
CS631 - Advanced Programming in the UNIX Environment
Lecture 01: Introduction, UNIX history, UNIX Programming Basics
August 28, 2017
CS631 - Advanced Programming in the UNIX Environment
not
an introduction to C an introduction to programming an introduction to Unix
Lecture 01: Introduction, UNIX history, UNIX Programming Basics
August 28, 2017
CS631 - Advanced Programming in the UNIX Environment
http://cm.bell-labs.com/who/dmr/chist.html
Lecture 01: Introduction, UNIX history, UNIX Programming Basics
August 28, 2017
CS631 - Advanced Programming in the UNIX Environment
August 28, 2017
CS631 - Advanced Programming in the UNIX Environment
understand fundamental OS concepts (with focus on UNIX family): gain (systems) programming experience gain an understanding of the UNIX operating systems
basic network programming using a client/server model interprocess communication process relationships basic and advanced I/O multi-user concepts
Lecture 01: Introduction, UNIX history, UNIX Programming Basics
August 28, 2017
CS631 - Advanced Programming in the UNIX Environment
if (isatty(STDOUT_FILENO)) {/* Terminal defaults to -Cq, non-terminal defaults to -1. */setlocale(LC_ALL, "");setprogname(argv[0]);const char *p;int kflag = 0;int ch, fts_options;struct winsize win; static char dot[] = ".", *dotav[] = { dot, NULL };
if (ioctl(STDOUT_FILENO, TIOCGWINSZ, &win) == 0 &&
termwidth = win.ws_col;win.ws_col > 0)
f_column = f_nonprint = 1;
} else
f_singlecol = 1;
if (!getuid())/* Root is -A automatically. */
f_listdot = 1;
while ((ch = getopt(argc, argv, "1ABCFLRSTWabcdfghiklmnopqrstuwx")) != -1) {fts_options = FTS_PHYSICAL;
/switch (ch) { / shell aliasing works correctly. The -1, -C, -l, -m and -x options all override each other so
case '1':
f_singlecol = 1;
Lecture 01: Introduction, UNIX history, UNIX Programming Basics
August 28, 2017
CS631 - Advanced Programming in the UNIX Environment
August 28, 2017
CS631 - Advanced Programming in the UNIX Environment
August 28, 2017
CS631 - Advanced Programming in the UNIX Environment
August 28, 2017
CS631 - Advanced Programming in the UNIX Environment
0xbbbc676a in __findenv () from /usr/lib/libc.so.
Lecture 01: Introduction, UNIX history, UNIX Programming Basics(gdb)
August 28, 2017
CS631 - Advanced Programming in the UNIX Environment
https://i.imgur.com/WnpMFjX.jpg https://i.imgur.com/ZyeCO.jpg
Lecture 01: Introduction, UNIX history, UNIX Programming Basics
August 28, 2017
CS631 - Advanced Programming in the UNIX Environment
Review Code reading, coding style, best practices Encryption Advanced I/O: Nonblocking I/O, Polling, and Record Locking Daemon Processes, shared libraries Interprocess Communication Process Groups, Sessions, Signals Process Environment, Process Control UNIX tools: make(1), gdb(1), revision control, etc. Filesystems, System Data Files, Time & Date Files and Directories File I/O, File Sharing Introduction, UNIX history, UNIX Programming Basics
Lecture 01: Introduction, UNIX history, UNIX Programming Basics
August 28, 2017
CS631 - Advanced Programming in the UNIX Environment
Lecture 01: Introduction, UNIX history, UNIX Programming Basics
August 28, 2017