Encyclopedia > Sourcecode

  Article Content

Source code

Redirected from Sourcecode

Source code refers to any series of statements written in some human readable computer programming language. In modern programming languages, the source code which constitutes a software program is usually in several computer files, but the same source code may be printed in a book or recorded on tape (usually without a filesystem). The term is typically used in the context of a particular piece of computer software. A computer program's source code is the collection of files that can be converted from human-readable form to an equivalent computer-executable form. The conversion is done by a compiled or assembled into object code for a particular computer architecture, or executed from the human readable form with the aid of an interpreter.

Table of contents

Purposes

The primary purpose of source code is for the description of software. However, source code has a number of other uses. It can be used as a tool of learning; beginning programmers often find it helpful to review existing source code to learn about programming techniques and methodology. It is also used as a communication tool between experienced programmers, due to its (ideally) concise and unambiguous nature. The sharing of source code between developers is frequently cited as a contributing factor to the maturation of their programming skills. Source code can be an expressive artistic medium; consider, for example, obfuscated code or PerlMonks.Org (http://www.perlmonks.org).

Source code is a vital component in the activity of porting software to alternative computer platforms. Without the source code for a particular piece of software, portability is generally so difficult to be impractical and even impossible. Programmers frequently borrow source code from one piece of software to use in other projects, a concept which is known as Software reusability[?].

Organization

The source code for a particular piece of software may be contained in a single file or many files. A program's source code is not necessarily all written in the same programming language; for example, it is common for a program to be written primarily in the C programming language, with some portions written in Assembly language for optimization purposes. It is also possible for some components of a piece of software to be written and compiled separately, in an arbitrary programming language, and later integrated into the software using a technique called library linking.

Moderately complex software customarily requires the compilation or assembly of several, sometimes dozens or even hundreds, of different source code files. This complexity is reduced considerably by the inclusion of a Makefile with the source code, which describes the relationships among the source code files, and contains information about how they are to be compiled. The Revision control system is another tool frequently used by developers for source code maintenance.

Licensing

Software, and its accompanying source code, typically falls within one of two licensing paradigms: Free software and Proprietary software. Generally speaking, software is free if the source code is freely available, and proprietary if the source code is kept secret, or is privately owned and restricted. The provisions of the various copyright laws are often used for this purpose, though trade secrecy is also relied upon. For a further discussion of the differences between these paradigms, and the divisions within them, see software license.

Legal Issues

As of 2002, court systems are in the process of deciding whether source code should be considered a Constitutionally protected form of free speech in the United States. Proponents of the free speech argument claim that because source code conveys information to programmers, is written in a language, and can be used to share humour and other artistic pursuits, it is a protected form of communication. The opposing view is that source code is functional, more than artistic speech, and is thus not protected by First Amendment Rights of the U.S. Constitution.

In 2000, in one of the most famous court cases in recent history, this issue was brought under some scrutiny when the Motion Picture Association of America (MPAA) sued the 'hacker' magazine 2600 and a number of other websites for distributing the source code to DeCSS, an algorithm capable of allowing protected DVD discs to be played under conditions not allowed for by the producer. In the original Norwegian situation, a legally purchased DVD could be played under Linux on the purchaser's computer because the distributor had neglected to support that operating system. The DeCSS software was first developed for the purpose of playing that DVD under Linux. The US District court decision favored the MPAA; 2600 magazine was prohibited from posting or linking to the source code on their website. This ruling was widely considered a victory for the supporters of the Digital Millennium Copyright Act, as it established a legal precedent for the notion that source code is not Constitutionally protected free speech. It was affirmed by the Appeals Court and at this writing is being appealed to the US Supreme Court.

Contrast the case of Bernstein who was prohibited from publishing (on paper) some cryptographic software (under a munitions control regulation of the US Federal Government). Bernstein sued and the Court held that the publication of that source code was a matter of free speech under the US Constitution.

See also Programming language



All Wikipedia text is available under the terms of the GNU Free Documentation License

 
  Search Encyclopedia

Search over one million articles, find something about almost anything!
 
 
  
  Featured Article
Brazil

... Sergipe Tocantins Geography Main article: Geography of Brazil Brazil is characterised by the extensive low-lying Amazon Rainforest in the north, and a more ...

 
 
 
This page was created in 25.3 ms