Revert "Update to 7.40.1"
[platform/upstream/curl.git] / lib / Makefile.netware
index c4ebc5e..bafd32f 100644 (file)
@@ -14,17 +14,17 @@ endif
 
 # Edit the path below to point to the base of your Zlib sources.
 ifndef ZLIB_PATH
-ZLIB_PATH = ../../zlib-1.2.5
+ZLIB_PATH = ../../zlib-1.2.8
 endif
 
 # Edit the path below to point to the base of your OpenSSL package.
 ifndef OPENSSL_PATH
-OPENSSL_PATH = ../../openssl-0.9.8r
+OPENSSL_PATH = ../../openssl-0.9.8y
 endif
 
 # Edit the path below to point to the base of your LibSSH2 package.
 ifndef LIBSSH2_PATH
-LIBSSH2_PATH = ../../libssh2-1.2.9
+LIBSSH2_PATH = ../../libssh2-1.4.3
 endif
 
 # Edit the path below to point to the base of your axTLS package.
@@ -42,6 +42,11 @@ ifndef LIBRTMP_PATH
 LIBRTMP_PATH = ../../librtmp-2.3
 endif
 
+# Edit the path below to point to the base of your fbopenssl package.
+ifndef FBOPENSSL_PATH
+FBOPENSSL_PATH = ../../fbopenssl-0.4
+endif
+
 # Edit the path below to point to the base of your c-ares package.
 ifndef LIBCARES_PATH
 LIBCARES_PATH = ../ares
@@ -59,7 +64,8 @@ DESCR = cURL libcurl $(LIBCURL_VERSION_STR) ($(LIBARCH)) - http://curl.haxx.se
 MTSAFE = YES
 STACK  = 64000
 SCREEN = none
-EXPORTS        = @libcurl.imp
+EXPORTF        = $(TARGET).imp
+EXPORTS        = @$(EXPORTF)
 
 # Uncomment the next line to enable linking with POSIX semantics.
 # POSIXFL = 1
@@ -95,7 +101,7 @@ else
 endif
 PERL   = perl
 # Here you can find a native Win32 binary of the original awk:
-# http://www.gknw.net/development/prgtools/awk-20070501.zip
+# http://www.gknw.net/development/prgtools/awk-20100523.zip
 AWK    = awk
 CP     = cp -afv
 MKDIR  = mkdir
@@ -181,6 +187,43 @@ CURL_LIB = ../lib
 
 INCLUDES = -I$(CURL_INC) -I$(CURL_LIB)
 
+ifeq ($(findstring -static,$(CFG)),-static)
+LINK_STATIC = 1
+endif
+ifeq ($(findstring -ares,$(CFG)),-ares)
+WITH_ARES = 1
+endif
+ifeq ($(findstring -rtmp,$(CFG)),-rtmp)
+WITH_RTMP = 1
+WITH_SSL = 1
+WITH_ZLIB = 1
+endif
+ifeq ($(findstring -ssh2,$(CFG)),-ssh2)
+WITH_SSH2 = 1
+WITH_SSL = 1
+WITH_ZLIB = 1
+endif
+ifeq ($(findstring -axtls,$(CFG)),-axtls)
+WITH_AXTLS = 1
+WITH_SSL =
+else
+ifeq ($(findstring -ssl,$(CFG)),-ssl)
+WITH_SSL = 1
+endif
+endif
+ifeq ($(findstring -zlib,$(CFG)),-zlib)
+WITH_ZLIB = 1
+endif
+ifeq ($(findstring -idn,$(CFG)),-idn)
+WITH_IDN = 1
+endif
+ifeq ($(findstring -spnego,$(CFG)),-spnego)
+WITH_SPNEGO = 1
+endif
+ifeq ($(findstring -ipv6,$(CFG)),-ipv6)
+ENABLE_IPV6 = 1
+endif
+
 ifdef WITH_ARES
        INCLUDES += -I$(LIBCARES_PATH)
        LDLIBS += $(LIBCARES_PATH)/libcares.$(LIBEXT)
@@ -204,6 +247,10 @@ ifdef WITH_SSL
        LDLIBS += $(OPENSSL_PATH)/out_nw_$(LIBARCH_L)/crypto.$(LIBEXT)
        IMPORTS += GetProcessSwitchCount RunningProcess
        INSTDEP += ca-bundle.crt
+ifdef WITH_SPNEGO
+       INCLUDES += -I$(FBOPENSSL_PATH)/include
+       LDLIBS += $(FBOPENSSL_PATH)/nw/fbopenssl.$(LIBEXT)
+endif
 else
 ifdef WITH_AXTLS
        INCLUDES += -I$(AXTLS_PATH)/inc
@@ -268,10 +315,12 @@ endif
 # Makefile.inc provides the CSOURCES and HHEADERS defines
 include Makefile.inc
 
-OBJS   := $(patsubst %.c,$(OBJDIR)/%.o,$(strip $(CSOURCES))) $(OBJDIR)/nwos.o
+OBJS   := $(patsubst %.c,$(OBJDIR)/%.o,$(strip $(notdir $(CSOURCES)))) $(OBJDIR)/nwos.o
 
 OBJL   = $(OBJS) $(OBJDIR)/nwlib.o $(LDLIBS)
 
+vpath %.c . vtls
+
 all: lib nlm
 
 nlm: prebuild $(TARGET).nlm
@@ -284,7 +333,7 @@ $(OBJDIR)/%.o: %.c
 #      @echo Compiling $<
        $(CC) $(CFLAGS) -c $< -o $@
 
-$(OBJDIR)/version.inc: ../include/curl/curlver.h $(OBJDIR)
+$(OBJDIR)/version.inc: $(CURL_INC)/curl/curlver.h $(OBJDIR)
        @echo Creating $@
        @$(AWK) -f ../packages/NetWare/get_ver.awk $< > $@
 
@@ -304,7 +353,7 @@ clean:
        -$(RM) -r $(OBJDIR)
 
 distclean vclean: clean
-       -$(RM) $(TARGET).$(LIBEXT) $(TARGET).nlm
+       -$(RM) $(TARGET).$(LIBEXT) $(TARGET).nlm $(TARGET).imp
        -$(RM) certdata.txt ca-bundle.crt
 
 $(OBJDIR) $(INSTDIR):
@@ -318,7 +367,7 @@ ifdef RANLIB
        @$(RANLIB) $@
 endif
 
-$(TARGET).nlm: $(OBJDIR)/$(TARGET).def $(OBJL) $(XDCDATA)
+$(TARGET).nlm: $(OBJDIR)/$(TARGET).def $(OBJL) $(EXPORTF) $(XDCDATA)
        @echo Linking $@
        @-$(RM) $@
        @$(LD) $(LDFLAGS) $<
@@ -584,6 +633,9 @@ ifdef WITH_SSL
        @echo $(DL)#define HAVE_LIBSSL 1$(DL) >> $@
        @echo $(DL)#define HAVE_LIBCRYPTO 1$(DL) >> $@
        @echo $(DL)#define OPENSSL_NO_KRB5 1$(DL) >> $@
+ifdef WITH_SPNEGO
+       @echo $(DL)#define HAVE_SPNEGO 1$(DL) >> $@
+endif
 else
 ifdef WITH_AXTLS
        @echo $(DL)#define USE_AXTLS 1$(DL) >> $@
@@ -611,6 +663,10 @@ else
        @echo $(DL)#define CURL_CA_BUNDLE getenv("CURL_CA_BUNDLE")$(DL) >> $@
 endif
 
+$(EXPORTF): $(CURL_INC)/curl/curl.h $(CURL_INC)/curl/easy.h $(CURL_INC)/curl/multi.h $(CURL_INC)/curl/mprintf.h
+       @echo Creating $@
+       @$(AWK) -f ../packages/NetWare/get_exp.awk $^ > $@
+
 FORCE: ;
 
 info: $(OBJDIR)/version.inc
@@ -647,13 +703,6 @@ else
        @echo ipv6 support:    no
 endif
 
-$(LIBCARES_PATH)/libcares.$(LIBEXT):
-       $(MAKE) -C $(LIBCARES_PATH) -f Makefile.netware lib
-
-ca-bundle.crt: mk-ca-bundle.pl
-       @echo Creating $@
-       @-$(PERL) $< -b -n $@
-
 $(CURL_INC)/curl/curlbuild.h: Makefile.netware FORCE
        @echo Creating $@
        @echo $(DL)/* $@ intended for NetWare target.$(DL) > $@
@@ -692,3 +741,10 @@ endif
        @echo $(DL)typedef CURL_TYPEOF_CURL_OFF_T curl_off_t;$(DL) >> $@
        @echo $(DL)#endif /* __CURL_CURLBUILD_H */$(DL) >> $@
 
+$(LIBCARES_PATH)/libcares.$(LIBEXT):
+       $(MAKE) -C $(LIBCARES_PATH) -f Makefile.netware lib
+
+ca-bundle.crt: mk-ca-bundle.pl
+       @echo Creating $@
+       @-$(PERL) $< -b -n $@
+