The function library under Linux has static library and dynamic library. There are certain differences between the two. The main reason is that the code loading time is different. The following small series introduces you to the Linux static library and Create a dynamic library, let's learn together.
static and dynamic library creation and use
1. Basic concepts
static library: link, packaged together with the library compiled .o files Go to the executable. The extensions under linux /windows are: .a /.lib
Dynamic library: When linking, it will not be packaged into the executable file, and the dynamic library will be dynamically loaded during execution. The extensions under linux /windows are: .so /.dll
The difference is mainly reflected in:
a, maintainability.
Join the update. To incorporate updates to the dynamic library, just replace the library. However, if you join static, you need to relink, generate a new executable, and update it in full.
Environmental dependence. If you include a static library, it does not depend on the environment after successful compilation. Dynamic libraries have dependencies and require corresponding dynamic libraries in the environment.
b, size
space utilization. If you rely on the same static library, there are multiple copies.
Executable file size. The static library file is large.
c, dynamic library can achieve resource sharing between processes, so it is also called shared library.
Previous12Next Total 2 Pages
Linux system kernel upgrade, the network card driver will be re-installed once, then what is the sim
There are many commands for monitoring the Linux system. The pidstat command is one
GIT has replaced SVN for most Linux users because of its more convenient operation. However, in the
In order to more convenient Internet access, we usually let our computer bind the network card. Howe
How to bind CPU process in Ubuntu?
Techniques for setting up multiple network cards as virtual network cards under Linux
Linux System Process Management Introduction
Linux How to use userdel to delete users
How to quickly switch the old server IP to the new server under Linux
Linux uptime command operation example
Ubuntu steps to install PlayOnLinux
What should I do if I install a graphics card driver error on Ubuntu 13.10?
Suggestions for Linux system desktops
Solution for NFS version incompatibility in CentOS/Debian system
RedHat/CentOS 7 Steps to Manage the Network Through the nmcli Command
What can I do if arm-linux-insight cannot set target under Linux?
Windows Mobile Center can not open the solution
What should I do if the desktop does not display after the Win7 system is turned on?
Alipay tips for the risk of the account
WIN7 Ultimate system prompts unidentified network without Internet access How to solve
Windows 10 Build 10159 release download brings more than 300 fixes
Is your computer suitable for installing Windows 7 system?
Win8 system Google browser can not open the prompt does not register class