Bonjour,

Je dois compiler un programme C++ et j'utilise le makefile suivant :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# =====================================================================
 
TARGETLIB       = api.exe
CODESRC         = api.cpp
TARGETOBJ       = api.o
 
CC          = /usr/vacpp/bin/xlC_r
CCOPTIONS   =  -+ -O -g  -I/produits/include
LIBCC       = $(CC)
LDOPTIONS   = -G -qmkshrobj=1000 -L/applis/dsgu/data/cpp -lvmdsapi
 
.SUFFIXES: .cpp .c .o
 
# ---------------------------------------------------------------------
# Rules
# ---------------------------------------------------------------------
 
all: $(TARGETLIB)
 
$(TARGETLIB):   $(TARGETOBJ)
        $(LIBCC) $(LDOPTIONS) $(TARGETOBJ) -o $(TARGETLIB)
 
$(TARGETOBJ): $(CODESRC)
        $(CC) $(CCOPTIONS) -c $(CODESRC) -o $(TARGETOBJ)
 
clean:
        @rm -f $(TARGETOBJ) $(TARGETLIB)
 
# ---------------------------------------------------------------------
# End of makefile
# ---------------------------------------------------------------------
J'obtiens avec le make :

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
ld: 0711-224 WARNING: Duplicate symbol: .bcopy
ld: 0711-224 WARNING: Duplicate symbol: .memcpy
ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain more information.
Target "all" is up to date.
Quand je lance la programme api.exe j'ai l'erreur suivante :

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
exec(): 0509-036 Cannot load program api.exe because of the following errors:
        0509-151 The program does not have an entry point or
                   the o_snentry field in the auxiliary header is invalid.
        0509-194 Examine file headers with the 'dump -ohv' command.