How to install an application on Linux?

How do I install an application on Linux? Because there are many operating systems, there is more than one answer to this question. Applications can come from many sources - almost impossible to clear, and each development team can provide software in the way they think is best. Knowing how to install the software you get is part of becoming an advanced user of the operating system.

warehouse

For more than a decade, Linux has been using software libraries to distribute software. In this case, the "warehouse" is a public server that hosts installable packages. The Linux distribution provides a command and a graphical interface to the command to get the software from the server and install it on your computer. This is a very simple concept, it has become the model of all major mobile operating systems, and recently, this model has become the "app store" of the two closed-source computer operating systems.

Not an app store

Installing from a depot is the primary method of installing an application on Linux, and it should be the preferred place to find any application you want to install.

Installing from a depot usually requires a command such as:

$sudo dnf install inkscape

The actual commands used depend on the Linux distribution you are using. Fedora uses dnf, OpenSUSE uses zypper, Debian and Ubuntu use apt, Slackware uses sbopkg, FreeBSD uses pkg_add, and lllumos-based Openlndiana uses pkg. Regardless of what you use, the command usually searches for the correct name for the application you want to install, because sometimes the name of the software you think is not its official or unique name:

$sudo dnf search pyqt

PyQt.x86_64 : Python bindings forQt3

PyQt4.x86_64 : Python bindings forQt4

Python-qt5.x86_64 : PyQt5 isPython bindings forQt5

Once you have found the name of the package you want to install, use the install subcommand to perform the actual download and autoinstall:

$sudo dnf install python-qt5

For specific information on installing from a depot, see the documentation for your Linux distribution.

The same is true for graphical tools. Search for what you think you want and then install it.

As with the underlying commands, the name of the graphical installer depends on the Linux distribution you are running. Related applications are usually tagged with keywords such as "software" or "package", so search for them in your startup or menu and you will find what you need. Since open source is all chosen by the user, if you don't like the graphical user interface (GUI) provided by your distribution, then you can choose to install alternatives. You know how to do this.

Extra warehouse

Your Linux distribution provides a standard repository for its packaged software, often with additional repositories. For example, EPEL serves Red Hat Enterprise Linux and CentOS, RPMFusion serves Fedora, Ubuntu has various levels of support and Personal Package Archive (PPA), Packman provides additional software for OpenSUSE, and SlackBuilds.org provides community build scripts for Slackware.

By default, your Linux operating system is set to view only its official repository, so if you want to use other software collections, you must add additional libraries yourself. You can usually install a repository just like installing a package. In fact, when you install many software such as GNU Ring video chat, Vivaldi web browser, Google Chrome, etc., your actual installation is to access their private repository, from which the latest version of the application is installed on your machine.

Installation warehouse

You can also manually add the repository to your package manager's configuration directory by editing the text file, or run the command to add the add repository. As always, the exact command you use depends on the Linux distribution. For example, this is a dnf command that adds a repository to the system:

$sudo dnf config-manager --add-repo=http://example.com/pub/centos/7

Do not use the repository to install the application

The warehouse model is very popular because it provides a link between the user (you) and the developer. After the important update is released, you will be prompted to accept the update and you can accept all updates from a centralized location.

However, sometimes a package is not yet in the repository. These installation packages come in several forms.

Linux package

Sometimes developers distribute software in a common Linux package format, such as RPM, DEB, or the newer but very popular FlatPak or Snap format. You are not accessing the repository to download, you just got this package.

For example, the video editor Lightworks provides a .deb file for APT users and an .rpm file for RPM users. When you want to update, you can go to the website to download the latest suitable files.

These one-time packages can be installed using the same tools used to install from the warehouse. If you double-click the downloaded package, the graphical installer will launch and step through the installation process.

Alternatively, you can install from the terminal. The difference here is that the individual package files you download from the Internet are not from the repository. This is a "local" installation, which means your software installation package does not need to be downloaded for installation. Most package managers are transparent:

$sudo dnf install ~/Downloads/lwks-14.0.0-amd64.rpm

In some cases, you will need to take extra steps to get the application running, so please read the documentation about the software you are installing.

Generic installation script

Some developers publish their packages in several common formats. Common extensions include .run and .sh. NVIDIA graphics drivers, Foundry visual FX packages like Nuke and Mari, and many non-DRM games from GOG use this installer. (LCTT Annotation: DRM is digital rights management.)

This installation mode relies on the developer providing a "wizard" for installation. Some installers are graphical, while others are only run in the terminal.

There are two ways to run these types of installers.

1. You can run the installer directly from the terminal:

$sh./game/gog_warsow_x.yzsh

2. Alternatively, you can run it by marking it as an executable. To mark the installer executable, right click on its icon and select its properties.

Give the installer executable permissions

Once you allow it to run, double-click the icon to install it.

GOG installer

For the rest of the installer, just follow the instructions on the screen.

AppImage portable app

The AppImage format is relatively new to Linux, although its concept is based on NeXT and Rox. The idea is simple: everything needed to run an application should be placed in a directory, which is then treated as an "application." To run the application, simply double-click on the icon to run it. You don't need to install the application in a traditional sense; it runs from anywhere on your hard drive.

Although it can be run as a standalone application, AppImage usually provides some system integration.

AppImage system integration

If you accept this condition, install a local .desktop file into your home directory. The .desktop file is an application menu for the Linux desktop and a small configuration file used by the mimetype system. Essentially, just place the desktop configuration file in the application list in the home directory to "install" the application without actually installing it. You get all the benefits of installing something, and the benefit of being able to run something locally, the "portable app."

Application directory

Sometimes the developer just compiles an application and then publishes the results to the download, without the installation script, and without packaging. Usually, this means that you downloaded a TAR file, then unzipped it, then double-clicked on the executable (usually the name of the software you downloaded).

Download Twine

When using this software delivery, you can place it where you downloaded it, you can start it manually when you need it, or you can do it yourself for a quick but cumbersome installation. This includes two simple steps:

Save the directory to a standard location and start it manually when needed.

Save the directory to a standard location and create a .desktop file to integrate into your system.

If you just install the application for yourself, then traditionally put a bin (short for "binary binary") in your home directory as the storage location for locally installed applications and scripts. If there are other users on your system that need to access these applications, the binary is traditionally placed in /opt. Finally, it depends on where you store your application.

Downloads are usually made in a directory with a version name, such as twine_2.13 or pcgen-v6.07.04. Since it is assumed that you will update the application at some point, it is a good idea to remove the version number or create a symbolic link to the directory. This way, even if you update the application itself, the launcher created for the application can remain unchanged.

To create a .desktop startup file, open a text editor and create a file called twine.desktop. The desktop entry specification is defined by FreeDesktop.org. Below is a simple launcher for a game development IDE called Twine, installed in the system-wide /opt directory:

[Desktop Entry]

Encoding=UTF-8

Name=Twine

GenericName=Twine

Comment=Twine

Exec=/opt/twine/Twine

Icon=/usr/share/icons/oxygen/64x64/categories/applications-games.png

Terminal=false

Type=Application

Categories=Development;IDE;

The tricky line is the Exec line. It must contain a valid command to launch the application. Usually, it's just the full path to what you're downloading, but in some cases it's more complicated. For example, a Java application might need to be started as a parameter to Java itself.

Exec=java -jar /path/to/foo.jar

Sometimes a project contains a wrapper script that can be run so you don't have to figure out the correct command:

Exec=/opt/foo/foo-launcher.sh

In this Twine example, there is no icon bundled with the downloaded software, so the example .desktop file specifies the generic game icon that comes with the KDE desktop. You can use a similar solution, but if you are more artistic, you can create your own icon, or you can search for a good icon on the Internet. As long as the Icon line points to a valid PNG or SVG file, your application will be represented by this icon.

The sample script also sets the application category primarily to Development, so in KDE, GNOME, and most other application menus, Twine appears under the development category.

To make this example appear in the application menu, put the twine.desktop file in one of two places:

If you store your application in your own home directory, put it in ~/.local/share/applications.

If you store your application in the /opt directory or other system-wide location and want it to appear in all users' application menus, place it in the /usr/share/applications directory.

The application is now installed because it needs to be integrated with other parts of the system.

Compile from source code

Finally, there is a true universal format installation format: source code. Compiling an application from source code is a great way to learn how to build an application, how to interact with the system, and how to customize the application. Still, it is by no means a click-and-click process. It requires a build environment, usually requires the installation of dependencies and header files, and sometimes some debugging.

Now you understand

Some people think that installing software is a magical process that only the developer understands, or they think it "activates" the application, as if the binary executable was not valid before "installation." Learning many different installation methods will tell you that the installation is actually just a shorthand for "copying files from one place to the right place in the system." Nothing is mysterious. As long as you get to know each installation, not expecting how it should happen, and looking for what the developer has set up for the installation process, it's usually easy, even if it's different from your habits.

The important thing is that the installer should be honest with you. If you encounter an installer that attempts to install additional software without your consent (or it may ask for consent in a confusing or misleading manner), or if you attempt to perform a check on the system for no apparent reason, do not proceed with the installation.

Good software is flexible, honest, and open. Now you know how to get good software on your computer.

CBD vape pen

Suizhou simi intelligent technology development co., LTD , https://www.msmvape.com

Posted on