How to create a static library in c

Code examples

0
0

ar rc libutil.a util_file.o util_net.o util_math.o
#This command creates a static library named 'libutil.a' and puts
#copies of the object files "util_file.o", "util_net.o" and "util_math.o" in it.
#If the library file already exists, it has the object files added to it, or replaced,
#if they are newer than those inside the library.
#The 'c' flag tells ar to create the library if it doesn't already exist.
#The 'r' flag tells it to replace older object files in the library, with the new object files.

In other languages

This page is in other languages

Русский
..................................................................................................................
Italiano
..................................................................................................................
Polski
..................................................................................................................
Română
..................................................................................................................
한국어
..................................................................................................................
हिन्दी
..................................................................................................................
Français
..................................................................................................................
Türk
..................................................................................................................
Česk
..................................................................................................................
Português
..................................................................................................................
ไทย
..................................................................................................................
中文
..................................................................................................................
Español
..................................................................................................................
Slovenský
..................................................................................................................
Балгарскі
..................................................................................................................
Íslensk
..................................................................................................................