gcc -shared விருப்பத்தேர்வு கொடி

gcc -shared பகிரப்பட்ட நூலகத்திற்காக பகிரப்பட்ட பொருள் கோப்பை உருவாக்குகிறது.

தொடரியல்

$ gcc -shared [options] [source files] [object files] [-o output file]

உதாரணமாக???

myfile.c :

// myfile.c
#include <stdio.h>

int main()
{
    printf("Program run!\n");
    int i=10;
}

 

myfile.c இன் வழக்கமான உருவாக்கம்செய்திகளை வழங்காது:

$ gcc myfile.c -o myfile
$

 

-சுவருடன் myfile.c இன் உருவாக்கம் :

$ gcc -Wall myfile.c -o myfile
myfile.c In function 'main':
myfile.c:6:6: warning: unused variable 'i'
myfile.c:7:1: warning: control reaches end of non-void function
$

 


மேலும் பார்க்கவும்

Advertising

ஜி.சி.சி
°• CmtoInchesConvert.com •°