[ARDrone] Fix static compilation, synchro Makefiles
This commit is contained in:
parent
dc3ba41222
commit
2c91f5b976
|
@ -1,6 +1,6 @@
|
|||
# Source version
|
||||
ifndef OWLPS_VERSION
|
||||
OWLPS_VERSION = $$(git describe || echo 'UNKNOWN_VERSION')
|
||||
OWLPS_VERSION = $(shell git describe || echo 'UNKNOWN_VERSION')
|
||||
endif
|
||||
|
||||
# Répertoire d'installation
|
||||
|
@ -17,8 +17,8 @@ ifeq ($(COLORGCC), 0)
|
|||
endif
|
||||
|
||||
# Commandes d'installation et de désinstallation
|
||||
RM=rm -fv
|
||||
CP=cp -v
|
||||
RM = rm -f
|
||||
CP = cp
|
||||
|
||||
# Cible
|
||||
TARGET=owlps-drone
|
||||
|
@ -34,8 +34,8 @@ XCFLAGS = $(CFLAGS) $(DEPFLAGS) $(WARN) $(HEADERS)
|
|||
PICFLAG = -fPIC
|
||||
LIBS = -L$(LIBOWLPS_DIR) -lowlps \
|
||||
-L$(LIBOWLPSCLIENT_DIR) -lowlps-client \
|
||||
-lrt -lm
|
||||
STATIC_LIBS = -liw -lm -lrt
|
||||
-lrt -lm -pthread
|
||||
STATIC_LIBS =
|
||||
OWLPSFLAGS = -D OWLPS_VERSION=\"$(OWLPS_VERSION)\"
|
||||
|
||||
## Cibles de compilation standard ##
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# Source version
|
||||
ifndef OWLPS_VERSION
|
||||
OWLPS_VERSION = $$(git describe || echo 'UNKNOWN_VERSION')
|
||||
OWLPS_VERSION = $(shell git describe || echo 'UNKNOWN_VERSION')
|
||||
endif
|
||||
|
||||
# Emplacement de la suite de cross-compilation
|
||||
|
@ -20,8 +20,8 @@ INSTALL_INC= $(PREFIX)/include
|
|||
INSTALL_MAN= $(PREFIX)/share/man
|
||||
|
||||
# Commandes d'installation et de désinstallation
|
||||
RM=rm -f
|
||||
CP=cp -v
|
||||
RM = rm -f
|
||||
CP = cp
|
||||
|
||||
# Cible
|
||||
TARGET=owlps-drone
|
||||
|
@ -30,14 +30,15 @@ DEPS = oc.o
|
|||
# Flags
|
||||
LIBOWLPS_DIR = ../libowlps
|
||||
LIBOWLPSCLIENT_DIR = ../libowlps-client
|
||||
CFLAGS = -O2 -Wall -Wextra -Wstrict-prototypes -I.
|
||||
CFLAGS = -O2 -Wall -Wextra -Wstrict-prototypes \
|
||||
-I$(LIBOWLPS_DIR) -I$(LIBOWLPSCLIENT_DIR)
|
||||
DEPFLAGS = -MMD
|
||||
XCFLAGS = $(CFLAGS) $(DEPFLAGS) $(WARN) $(HEADERS)
|
||||
PICFLAG = -fPIC
|
||||
LOWLPS = -L$(LIBOWLPS_DIR) -lowlps
|
||||
LOWLPSA = $(LIBOWLPS_DIR)/libowlps.a
|
||||
LOWLPSCLIENTA = $(LIBOWLPSCLIENT_DIR)/libowlps-client.a
|
||||
LIBS = $(LOWLPSCLIENTA) -liw -lm -lrt
|
||||
LIBS = $(LOWLPSCLIENTA) -lrt -lm -pthread
|
||||
DYNAMIC_LIBS = $(LOWLPS) $(LIBS)
|
||||
SEMISTATIC_LIBS = $(LOWLPSA) $(LIBS)
|
||||
STATIC_LIBS = $(LOWLPSA) $(LIBS)
|
||||
|
@ -75,8 +76,12 @@ install : $(TARGET)
|
|||
@$(CP) $(TARGET) $(INSTALL_DIR)
|
||||
@cd $(INSTALL_DIR) ; chown root:root $(TARGET) ; chmod 755 $(TARGET)
|
||||
|
||||
install-static : $(TARGET).static
|
||||
@$(CP) $(TARGET).static $(INSTALL_DIR)
|
||||
@cd $(INSTALL_DIR) ; chown root:root $(TARGET).static ; chmod 755 $(TARGET).static
|
||||
|
||||
uninstall :
|
||||
@$(RM) $(INSTALL_DIR)/$(TARGET)
|
||||
@$(RM) $(INSTALL_DIR)/{$(TARGET),$(TARGET).static}
|
||||
|
||||
|
||||
## Nettoyage ##
|
||||
|
@ -85,7 +90,7 @@ clean :
|
|||
@$(RM) -fv *~ *.o *.d
|
||||
|
||||
purge : clean
|
||||
@$(RM) -fv $(TARGET) $(TARGET).static $(TARGET)-drone
|
||||
@$(RM) -fv $(TARGET) $(TARGET).static
|
||||
|
||||
|
||||
## Aide ##
|
||||
|
@ -98,8 +103,6 @@ help :
|
|||
$(TARGET) (cible par défaut) : Compile le programme $(TARGET).\n\
|
||||
$(TARGET).static : Compile le programme $(TARGET).static \
|
||||
(version sans lien dynamique).\n\
|
||||
$(TARGET).semistatic : Compile le programme $(TARGET).semistatic \
|
||||
(version sans lien dynamique vers libowlps).\n\
|
||||
install : Installe le programme $(TARGET).\n\
|
||||
uninstall : Désinstalle le programme $(TARGET).\n\
|
||||
clean : Supprime les fichiers temporaires.\n\
|
||||
|
|
Loading…
Reference in New Issue