Linux is an operating system, just like Microsoft’s Windows or Apple’s MacOS. An operating system is what makes it possible to use computer hardware. Technically, this serves as an interface between the hardware (processor, memory, sound card) and application software (Internet browser, office suite, games). Without an operating system, a computer is unusable. To be very precise, Linux is the name of the kernel of the operating system, it is the heart of it, which contains the most important programs. It is the central and almost invisible part of the system.
GNU/Linux is the name of the entire operating system, although it is often referred simply as Linux for abuse. GNU/Linux makes it possible to insist on the fact that many GNU tools are necessary for the functioning of Linux, but especially to underline its freedom: the difference between GNU/Linux and other systems such as Windows or macOS is that this system d exploitation is free. For the curious, the Linux and the GNU Project page will explain in more detail what free means and what GNU is.
A world-wide, easy-to-use, open-source option among the best operating systems
Without necessarily claiming to be the best operating system, Linux is a system renowned for its stability – it is not uncommon to meet people who have not restarted their computer running Linux for many months – its security and its multitasking side – you can format a disc, listen to music, burn a backup DVD, download files from the internet, update its distribution and type the text of your monograph on flies in the same time, really, at the same time, and without crashing.
In addition, Linux has a very diversified software library. A Linux distribution usually comes with hundreds, if not thousands, of software. Linux is highly customizable and there are several alternatives to do almost anything. At first, it is advisable to choose the most popular software and tools. If afterwards we want to change, there are many possibilities.
Linux works on an impressive number of architectures (hardware if you prefer): x86 processors (Intel Pentium, AMD Athlon and company), Alpha, ARM, Power PC (old Macintosh, G5, etc.). It is therefore found on big IBM servers (mainframes), some personal assistants (PDAs), mobile phones and tablets (Android, Firefox OS) and even parking meters. Did you know that Google and Facebook run entirely on Linux? NASA uses Linux on its computers and robots in space.
All in all, you will quickly see that Linux, although it is less prevalent on personal computers than other operating systems, is just as pleasant an environment to use as the others and not much more difficult.
Why should you start coding in Linux?
The choice to develop software in C or C ++ language on Linux actually covers two decisions. First, you choose an operating system. Using Linux as a development environment is a new option in industry. The second decision concerns the language and the libraries used. Other languages are indeed available, and you must be in line with the end goal of the application as well as the intended audience. The next paragraphs will examine the possibilities offered by the tools available under Linux for a good software realization in C or C ++ language.
Well, choosing the Linux platform to perform software development is already an important decision. Several motivations can be at the origin of this choice. First of all, Linux is probably the best operating system for distributing free software, websites like can be made thanks to free software like this. The spirit of the Linux community is such that a new project is generally well received, and the enthusiasm of the participants allows the rapid progression of software, provided the team is sufficiently motivated.
This type of choice is no longer only made by amateurs or students, but some companies have already understood the immediate interest for them in adhering to the logic of free software. This is the case, for example, with some manufacturers of computer peripherals: they distribute the technical specifications of their hardware in the development of free drivers for operation under Linux. The choice of the Linux system as a development environment can also be motivated by the quality of the tools available “freely” and the documentation available on the Internet. Upon installation, any Gnu/Linux distribution includes all the software tools needed by the programmer – editors, compilers, debuggers – for all commonly used computer languages.
In addition, porting applications to other Unix environments is often very fast, since it only requires a simple recompilation of the source files. It is then possible to have PC type development stations, which are powerful and economical. Note also that Linux, far from being limited to PCs, is available on a wide variety of machines. Applications running under this system automatically have “internal” portability across a full range of different architectures and processors.
However, the most common motivation for Linux development is simply the choice of this system as the final application platform. This solution has been used for several years in many laboratories, study centers, etc. The use of Linux as the primary environment for industrial applications is more recent, but once initial reservations have been overcome, there is usually a slow but steady increase in the number of machines running Linux within an organization.
To ensure the success of an application development under Linux, it is important to clearly target in which category the product fits: free software distributed on the Internet or reserved for internal use; application intended to be widely ported to other operating systems or conversely limited to use only under Linux. This influence both the programming tools and languages to use, and the priority goals that the team of developers should set for themselves.
How to choose the better language for my Linux development?
In the industrial world, one of the most popular strengths of the Linux system is its remarkable stability. Correctly configured stations can have very long uninterrupted uptime. The only shutdowns of the system are then due to the hardware components, and not to the software. This results in particularly high system availability rates, which is very valuable in certain types of applications.
The most frequently cited example is that of the web server. Apache free software is widely used to build efficient and inexpensive servers under Linux. To configure and customize a network server, we often use the Perl language, which allows you to quickly write small powerful scripts, to boost the content of web pages, to program software robots managing mailing lists or to sort and distribute mail or Usenet articles.
For applications requiring greater technical involvement, the most used languages are C and C ++. Portability is a bit more restricted, mainly regarding the user interface. In fact, the Linux kernel, as well as all the system utilities, are written in C. The use of this language therefore allows easy access to the low-level resources essential in certain applications (interfacing, writing a device driver, etc.). The C language offers technical advantages in terms of power and speed, particularly suitable for scientific and industrial applications. In addition, as a compiled language, it provides a stand-alone executable file, which ensures the confidentiality of the algorithms used in the sources. This aspect constitutes, in certain circumstances, a real advantage over other languages.
The graphical environment used in Linux is the XWindow system. This very powerful system is particularly interesting on networked machines, because it allows displays to be deported to remote stations. X-Window imposes very few obligations in terms of the appearance of applications. Therefore, many different graphics libraries coexist, sometimes making porting applications somewhat difficult.
Two main graphical environments currently exist: the Gnome system, from the GNU project, and the KDE system. Both are installed automatically with most current distributions, and the user chooses their preferred environment upon login. These environments affect the appearance and behavior of windows (system menu, borders, mouse reaction, etc.), but also have an important role in communication between applications.
Choosing to use the Gnome or KDE environment for an application’s user interface is therefore not an innocent action. Another possibility is to use a portable library on all Unix systems. The Motif environment has established itself as a de facto standard in industrial computer systems. There are several commercial implementations of this in Linux, as well as a free implementation called Lesstif. The use of these libraries helps to ensure portability of graphics applications, while maintaining the efficiency and performance of a compiled language close to the machine.
Development tools that will make your life easier in Linux
The development tools freely available in Linux are surprisingly powerful. At the heart of programming in C or C ++ language is naturally the compiler. The one used in Linux is called GCC. This is a compiler produced by the GNU Project, the purpose of which is to freely provide replacement software for all system utilities and development tools under Unix. The GCC compiler is nothing specific to Linux. It represents an interesting alternative to very expensive compilers, since it allows to equip easily and inexpensively all the stations of the developers of a team. GCC is available in several versions installed jointly, depending on whether you prefer to use the C language, C ++, or even the Objective C dialect. The many options available to adjust the configuration of the compiler allow you to adapt its behavior to the wishes of the programmer, particularly with regard to compliance with the most common standards (Posix, Iso C99, etc.).
Top 7 CAD Programs Available for Linux https://t.co/en2XzqxSg5 via @itsfoss2
— howtopam (@howtopam) October 24, 2020
The GCC compiler is a command line tool, which can therefore be started directly “by hand” by indicating the desired options and the source files to be compiled. This utility performs only one task, but it performs it best, without user interface considerations distracting it from its role, distractions like and many others. To improve the ergonomics of the programmer, there are however a certain number of integrated development environments, which include a text editor for entering source files, and graphic components (buttons, menus, etc.) to directly invoke the compiler in background, making sure you are using the correct options. These environments also allow the GNU debugger, named GDB. Like the compiler, this tool works by invocation from a command line, and then offers a minimal user interface. Integrated development environments frame it and present a more attractive graphical interface, allowing the execution of a program instruction by instruction, inspection of variables, and more.
The GNU project brings together a complete set of tools to support the developer’s work. These include, for example, archiving utilities for creating custom function libraries, source code covers to standardize the appearance of files created by different team members, RCS or CVS tools that provide version control and thus, allow simultaneous work by several developers on the same project while minimizing the risk of competitive modifications.
The Linux community is the biggest success of this operating system
The immense documentation available on the Linux environment is one of the features of this system that is most appealing to programmers. One can find on Internet sites gathering high quality information in all the fields interesting the developer.
With regard to the Linux environment in general, the installation and configuration of applications or the administration of the system, consult the HOW-TO documents, translated into many languages, and which gather information on most of the important subjects for the users.
Just to make sure that you didn't miss anything, this could be a good checklist for reference: https://t.co/tJaf9sMAOp
— Linux Handbook (@LinuxHandbook) October 22, 2020
The programmer can always consult the sources of the kernel or those of the C library at will, which represents not only a source of exact information regarding a precise functionality, but also powerful and often elegant examples of implementation.
The functionality offered by the Linux kernel and the higher-level routines offered by the standard C library are seldom sufficient to build a complete application. It is often necessary to use other libraries that do various tasks. Let us quote for example the existence of libraries integrating algorithms of compression, encryption, reading of graphic files in most of the usual formats. It is also possible to mention the option of accessing objects available on a Corba bus or even using gateways to other development languages such as Python, Perl or Tcl/Tk. All these libraries are available in the form of freely searchable source code and adaptable to specific needs.