CS 215 - Fundamentals of Programming II
Spring 2008 - Submission Instructions


While there are a plethora of software development environments for the C++ programming language that are implemented on many different platforms, for consistency and experience, programming assignments in CS 215 are to be completed using the GNU C++ compiler (g++) on the CS project server, csserver.evansville.edu. Having everyone using the same compiler will contain any potential compiler bugs and keep the language semantics consistent (by requiring certain semantic switches-see below). Although there has been an ISO standard for C++ since December 1999, different compilers still interpret and implement the newer language constructs differently, and they each have their quirks (though it is getting much better). Having a common compiler will help in containing these quirks. Also, occasionally include files may be given as part of the assignments. These files may be platform dependent and/or refer to precompiled libraries. Access to these files will be aided by having everyone on the same platform and using the same compiler.


Compiler and Compilation

Programming assignments must compile on csserver using the g++ compiler for minimal credit to be given for the project. This does not mean that some (or even all) of the programming assignment must be developed on the csserver. Those of you that have other development systems can complete some or all of an assignment on that system. However, when the program is turned in, it must compile using g++ without any intervention from the instructor. A program that works "perfectly" using, say, the Visual C++ compiler will be returned for resubmission for late credit if it does not compile on csserver- using g++. (Also note that the lab practical exam will require that programs be written using the tools on csserver.)


All source files will use the following conventional suffix indication:


.cpp

User-defined C++ source files

.h

User-defined C++ header files


To compile C++ code you are to use:


g++ <compiler options> <source files>


Common compiler options include:


-o <executable name>

creates executable file of given name; default is a.out otherwise

-c

compile only; creates .o object file(s) of same name(s) as source file(s)

-Wall

compile with all warnings turned on; this is required to produce the most conforming code possible

-g

compile for symbolic debugging


Generally, you will submit a makefile in addition to source and header files that will invoke g++ appropriately. See the handout Very Basic make for an explanation of makefiles. Note: when you do run the compiler from the command line, be very careful that you put the executable name after the -o option, otherwise the compiler will overwrite the first source file.


Turning in Assignments

Assignments will submitted both on-line via the automated submission system at submission.evansville.edu and in hard-copy printout. To receive a minimal grade the source code must compile as noted above.


For the on-line submission, all files necessary for a project must be archived together using the tar facility. The tarfile should include all of the files required for the assignment as specified. These may include makefiles, header files, source files, input files, and output files you might have written. Your tarfile should be named as follows:


   YourUsernameAssignmentNumber.tar


The tar facility is invoked using:


   tar -cvf <tarfile> <files to archive>


where the options -cvf mean create a tarfile, report in verbose mode, and put the archive in file <tarfile>. If you want to check whether all your files got included in your tarfile, you can list the tarfile contents (option -t) using:


   tar -tf <tarfile>


You can also try extracting the files from the archive (in a different directory! - option -x) using:


   tar -xvf <tarfile>


For example, suppose A. Good Student's (username ags) 6th project for CS 215 includes the following files:


   Makefile.proj6
   stack.h
   stack.cpp
   sim.cpp


Then A. Good would tar these files as follows:


   tar -cvf agsProject6.tar Makefile.proj6 stack.h stack.cpp sim.cpp


Note: Be very careful that you put the tarfile name after the -cvf, otherwise this will overwrite the first file in the file list as the tarfile.


Then A. Good would submit the file agsProject6.tar to the submission system as follows:


The output of your program is compared with the expected output for the program for various tests. The result of a submission is all or nothing. Either your program produced the exact expected output (including whitespace) or it does not. Ignore the score given by the system. All assignments will be set to 10 points in the system regardless of the point value of the assignment. (The grade on an assignment is based on more than whether the program produced the correct results as explained in the syllabus. Also, not all functionality can be tested automatically.)


There are 4 possible results of a submission. They are:


Result

Description

Did not extract

There was an error extracting the submitted tarfile

Timeout

Program compiled, but ran too long. Usually means there is an infinite loop or the program is waiting for unneeded user input.

Failure

Program did not compile (e.g. incorrectly named makefile). Program compiled, but did not run (e.g., incorrectly named executable). Program ran, but one or more expected results were incorrect and/or it crashed.

Success

Program output matched all expected results.


You may submit your assignment multiple times. Only the last submission will be graded. The submission system will accept submissions up to 3 days after the due date and time.


To conserve paper, the hard-copy printouts done on csserver should be printed 2-up in landscape mode using


   a2ps <file names>


This will print in the CS Project Lab (nowhere else!) with two pages of source code on each piece of paper. (If you print your files somewhere else, you can print them however you like.) If you are using vi tabs, you may need to print C++ source code using the -T3 option (but not makefiles), so that the tabs are printed as 3 spaces rather than the normal 8 spaces. Only those files specified in the assignment are to be submitted in hard-copy.

01/14/08 3 of 3