remove support for SSL on f27 because of openssl-1.1 - see specfile
[pcucontrol.git] / pcucontrol / models / intelamt / Makefile
1 CC = g++
2 LIBTOOL = libtool
3 ARCH := $(shell uname -m | sed 's/i.86/i386/')
4
5 # for f27: removing -Wlong-long
6 X64FLAGS = -Wformat -Wpointer-arith 
7
8 # for f27: getting rid of most warnings
9 CFLAGS = -Dlinux -Wno-write-strings
10
11 # for f27 : remove support for SSL - hopefully temporary
12 # the changes to openssl 1.1 look a bit awkward though
13 ifneq "$(FCDISTRO)" "$(filter $(FCDISTRO),f27)"
14 SSL = 
15 else
16 SSL = -DWITH_OPENSSL
17 endif
18
19 ifeq ($(ARCH),x86_64)
20         FLAGS = $(CFLAGS) $(X64FLAGS) $(SSL)
21 else
22         FLAGS = $(CFLAGS) $(SSL)
23 endif
24
25 #CFLAGS = -Dlinux  -Wall -Wno-deprecated $(SSL)
26 GSOAP_PATH = ./
27 GSOAP_CODE = ./
28 INC_PATH = ./Include
29 SRC_PATH = ./
30 INCLUDE = -I$(GSOAP_PATH)  -I$(INC_PATH)  -I$(GSOAP_CODE)
31 SRCS = $(GSOAP_CODE)/soapClient.cpp $(GSOAP_CODE)/soapC.cpp $(GSOAP_PATH)/stdsoap2.cpp $(GSOAP_PATH)/httpDigest.cpp $(GSOAP_PATH)/digcalc.cpp RemoteControlSample.cpp 
32 OBJS = $(SRCS:.cpp=.o) Utils.o 
33 LIBS = -lssl -lcrypto
34 APPNAME = remoteControl
35 WSDL2H = $(GSOAP_PATH)/wsdl2h
36 SOAPCPP = $(GSOAP_PATH)/soapcpp2
37 all: clean $(APPNAME)
38
39 $(APPNAME): $(OBJS)   
40         $(LIBTOOL) --mode=link $(CC) $(FLAGS) $(INCLUDE) -o $(APPNAME) $(OBJS) $(LIBS)       
41
42 Utils.o: $(SRC_PATH)/Utils.cpp 
43         $(CC) $(CFLAGS) $(INCLUDE) -c $(SRC_PATH)/Utils.cpp -o Utils.o      
44
45 %.o: %.cpp
46         $(CC) $(FLAGS) $(INCLUDE) -c $< -o $@ 
47
48 clean:
49         rm -f $(OBJS) $(APPNAME) *~
50         rm -rf .libs