1. Introduction to Open Source Software

You have created an awesome program, and now you want to make it available to the public. Now comes an important decision to make: what license to apply to your software.

This decision will have several important impacts, including the following:

How users can use your software

Whether the code is visible to others or “hidden” from plain sight

Whether other developers can use the code to create their own programs

Whether others can sell (or resell) the program


Disclaimer

License issues can be complex and have a significant impact on how your software is used. The discussion in this book is designed to provide you with a basic understanding of different licenses but is not intended to provide any legal advice. The author of this book does not intend to provide any legal advice. Always consider consulting proper legal advice before making a decision regarding software licenses.


Defining Source Code

Most likely the first question you need to answer is, “Will this be closed source software or open source software?” To answer this question, you first need to understand what source code is.

Software consists of a collection of instructions that are written in a programming language. Dozens of different languages exist, including C, C++, Java, Perl, Python, and many others. This collection of instructions is referred to as source code. See Figure 1.1 for a demonstration of source code written in C.

Figure 1.1 Source code written in C

Typically, you can’t use this source code directly to run your program. Most languages require a compile process in which the source code is converted into instructions that the operating system can understand. The result is data that looks like garbage to a human but makes sense to the operating system. See Figure 1.2 for a demonstration of source code that is converted into compiled code.

Figure 1.2 Example of source code converted to compiled code

If you choose to license your software as closed source, then you only provide the compiled code to customers. Software open source licenses include access to the original source code.

Closed Source

Also called proprietary software, the purpose of closed source software is to keep the source code a closely guarded secret. The idea is that if others can see the source code, then the source code may be copied and illegally used. As a result, competitors of the organization that created the software might end up having a negative impact on the financials of the organization that created the software. As you can imagine, copying someone else’s software is much cheaper than creating your own software.

Often the term closed source is used in place of the term commercial software, but this isn’t accurate. Commercial software must be purchased in order to use it. Both closed and open source software can be commercialized; the specific license determines whether the software is commercial or “free.”1

Examples of closed source software include:

Microsoft Windows

Adobe Photoshop

Apple macOS

Open Source

Software is considered open source when both the compiled and source versions of the code are made available.2 The software license from the copyright holder grants certain rights to view, modify, and distribute the software. A variety of open source licenses are available that enable you to pick which rights are granted.

Although some open source software is free, in the economic sense, that isn’t a requirement for open source software to be considered open source. Open source refers to the capability to access the source code, not how the software can be used or any costs associated with the software.

Common examples of open source software include:

Linux3

Apache HTTP Server

Firefox

Git

Openoffice.org

“Free” Software

The concept of free in regards to software is not necessarily agreed upon by all. Some people might consider free software to be software without cost. In other words, it doesn’t cost you anything to obtain and use the software.

However, what does it mean to use software? Does this mean that the software can be used in any way that the user wants, or are there some restrictions? Can this software be used anywhere in the world, or are there geographic limitations? Are you free to modify the software and distribute free copies of the modified format, or are these actions prohibited? As you can see, free in terms of software isn’t so clear cut.

One way of defining the term free is to use the definition created by Richard Stallman and published by Free Software Foundation (FSF):

“The word ‘free’ in our name does not refer to price; it refers to freedom. First, the freedom to copy a program and redistribute it to your neighbors, so that they can use it as well as you. Second, the freedom to change a program, so that you can control it instead of it controlling you; for this, the source code must be made available to you.”

Note that the preceding definition mandates that free software also be open source software. Not everyone agrees with this, and you will find some closed source freeware on the market.

Another way to define the term free is by the Four Freedoms, as defined by the Free Software Foundation:

Freedom 0: “The freedom to run the program as you wish, for any purpose.”

Freedom 1: “The freedom to study how the program works and change it so it does your computing as you wish. Access to the source code is a precondition for this.”

Freedom 2: “The freedom to redistribute copies so you can help your neighbor.”

Freedom 3: “The freedom to distribute copies of your modified versions to others. By doing this you can give the whole community a chance to benefit from your changes. Access to the source code is a precondition for this.”

These Four Freedoms are at the heart of what is referred to as FOSS (Free and Open Source Software).4 FOSS attempts to address the challenge of defining what constitutes “free software.” Note that the definition highlights the fact that not all free software is open source. Conversely, not all open source software is licensed with the Four Freedoms.

Understanding the complex world of open source software and what part “freedom” plays takes some time. See Figure 1.3 for a graphic that includes the various components of open source software.

Figure 1.3 Visualize the Open Source community

The graphic in Figure 1.3 highlights the complex combination of elements that make up open source software. You can see that the developers write the source code, create documentation, and provide support. However, the users of the software are often major components in this process as well. In fact, some open source software includes little or no support or documentation from the developer, but rather relies on a strong user base (the community) to provide these critical elements.

Note that the freedoms to modify, distribute, and utilize are also depicted in the diagram in Figure 1.3. Additionally, the software license is what provides these freedoms.

Choosing Open Source Licensing

Ultimately you need to decide whether to license your software as closed source or open source. Part of that decision will be based on specifics regarding licenses, a topic that this chapter covers further. However, you should consider some general benefits to creating open source software:

Open source tends to invoke trust. The reason is that others can see exactly what the software does by looking at the source code.

Open source can result in better code and less development time. With other developers reviewing your code and providing feedback, bug fixes, and improvements are created more rapidly, often at no cost to you.

Open source that is “free” can increase the scope of the user base. More users are willing to try software that is free rather than paying money to test out new software.

You can still make money from “free” open source software. Other available sources of revenue include training, support contracts, and additional services.

Options

Dozens of standard open source licenses and a large number of custom licenses are available. Typically, they fall into one of the following four categories:

Standard—Regular licenses that are often reused for other software products. Typically, these are specific to a country and many of them center around United States or European laws.

International—Regular licenses that are often reused for other software products. Unlike the standard licenses, these licenses are designed to be used throughout the world.

Special purpose—Licenses that are written for specific cases.

Nonreusable—Licenses that are not permitted to be used for any software product besides the product the license was written for.

Key Terms

Regarding open source software licenses, you should understand a couple of key terms. One term is copyleft, which ensures intellectual property (IP) can be copied or distributed as open source software. The two forms of copyleft are

Strong—All derived works must maintain original copyleft.

Weak—Derived works don’t need to follow the original restrictions.

Another important open source license term is permissiveness. This term is related to derived works and whether mixed licenses are allowed. The two forms of permissiveness are

Strict—Limited mixed licenses (no closed source or more permissive licenses)

Permissive—Allows mixed licenses

Examples

The following list describes some of the more popular open source licenses:

Apache License 2.0:

Very permissive

Non-copyleft

Use for any purpose

Distribute and modify

Allows derived works

MIT License:

Also known as X11 license

Similar to Apache license 2.0

Very permissive

Non-copyleft

Use for any purpose

Must keep copyright message

User must agree that no warranty is provided

GNU General Public License (GPL):

Strong copyleft

Strict permissiveness

All derived works must be GPL

Two versions: v2 and v3

BSD License:

Very permissive

Non-copyleft

Three types:

Two-clause—Same as MIT

Three-clause—Derived work not endorsed by original holder

Four-clause—Advertising must acknowledge original holder

Useful Links

Hopefully, you now have a basic understanding of open source software and licenses. Clearly, the topic is not a simple one, and spending additional time researching which license is the best for your project and organization is important. In addition to consulting a legal expert, you should find the following URL resources helpful:

http://choosealicense.com—This tool uses a series of questions to help you determine which license works best for your situation. It provides a good start, but you should also consult a legal expert before making a final decision.

http://fsf.org—The website for the Free Software Foundation offers a great deal of useful information regarding open source software and licenses.

http://opensource.orgThis is another great resource to learn more about open source licenses.


Open Source Humor

Open source: free as in “free speech,” not as in “free beer.” —Anonymous


Summary

In this chapter you learned the differences between closed and open source software. The concept of free software was also explored. Lastly, you learned about some of the basics of open source licenses. At this point you should be able to start the process of determining what type of license under which to release your software. However, remember that you want to put a lot of time, effort, and thought into this decision before releasing your software because these licenses can have a powerful effect on how your software will be used by the community.

1 There is a reason why I put free in quotes. As you will soon read, the term free must be legally defined in regards to software use.

2 Actually, some open source projects only provide the source code and leave it to the people who use the software to compile it. Additionally, some languages don’t have a compile process, so a program written in such a language would only include the source code.

3 Technically, Linux refers to the Linux kernel, which is the heart of the Linux operating system. Most of the software found on Linux operating systems is also open source, but this isn’t a requirement for inclusion in the OS.

4 Often used interchangeably with the term FLOSS (Free/Libre and Open Source Software).

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.22.61.187