1#*************************************************************************** 2# _ _ ____ _ 3# Project ___| | | | _ \| | 4# / __| | | | |_) | | 5# | (__| |_| | _ <| |___ 6# \___|\___/|_| \_\_____| 7# 8# Copyright (C) 1998 - 2019, Daniel Stenberg, <daniel@haxx.se>, et al. 9# 10# This software is licensed as described in the file COPYING, which 11# you should have received as part of this distribution. The terms 12# are also available at https://curl.haxx.se/docs/copyright.html. 13# 14# You may opt to use, copy, modify, merge, publish, distribute and/or sell 15# copies of the Software, and permit persons to whom the Software is 16# furnished to do so, under the terms of the COPYING file. 17# 18# This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY 19# KIND, either express or implied. 20# 21########################################################################### 22 23HTMLPAGES = testcurl.html runtests.html 24PDFPAGES = testcurl.pdf runtests.pdf 25MANDISTPAGES = runtests.1.dist testcurl.1.dist 26 27# the path to the impacket python lib used for SMB tests 28IMP = python_dependencies/impacket 29SMBDEPS = $(IMP)/__init__.py $(IMP)/nmb.py $(IMP)/nt_errors.py \ 30 $(IMP)/ntlm.py $(IMP)/smb.py $(IMP)/smb3.py $(IMP)/smb3structs.py \ 31 $(IMP)/smbserver.py $(IMP)/spnego.py $(IMP)/structure.py \ 32 $(IMP)/uuid.py $(IMP)/version.py smbserver.py curl_test_data.py 33 34EXTRA_DIST = ftpserver.pl httpserver.pl secureserver.pl runtests.pl \ 35 getpart.pm FILEFORMAT README stunnel.pem memanalyze.pl testcurl.pl \ 36 valgrind.pm ftp.pm sshserver.pl sshhelp.pm pathhelp.pm testcurl.1 runtests.1 \ 37 serverhelp.pm tftpserver.pl rtspserver.pl directories.pm symbol-scan.pl \ 38 CMakeLists.txt mem-include-scan.pl valgrind.supp extern-scan.pl \ 39 manpage-scan.pl nroff-scan.pl http2-server.pl dictserver.py \ 40 negtelnetserver.py $(SMBDEPS) objnames-test08.sh objnames-test10.sh \ 41 objnames.inc 42 43DISTCLEANFILES = configurehelp.pm 44 45# we have two variables here to make sure DIST_SUBDIRS won't get 'unit' 46# added twice as then targets such as 'distclean' misbehave and try to 47# do things twice in that subdir at times (and thus fails). 48if BUILD_UNITTESTS 49BUILD_UNIT = unit 50DIST_UNIT = 51else 52BUILD_UNIT = 53DIST_UNIT = unit 54endif 55 56SUBDIRS = certs data server libtest $(BUILD_UNIT) 57DIST_SUBDIRS = $(SUBDIRS) $(DIST_UNIT) 58 59PERLFLAGS = -I$(srcdir) 60 61CLEANFILES = .http.pid .https.pid .ftp.pid .ftps.pid $(MANDISTPAGES) 62 63MAN2HTML= roffit $< >$@ 64 65curl: 66 @cd $(top_builddir) && $(MAKE) 67 68if CROSSCOMPILING 69TEST = @echo "NOTICE: we can't run the tests when cross-compiling!" 70else # if not cross-compiling: 71TEST = srcdir=$(srcdir) $(PERL) $(PERLFLAGS) $(srcdir)/runtests.pl 72TEST_Q = -a -s 73TEST_AM = -a -am 74TEST_F = -a -p -r 75TEST_T = -a -t 76TEST_E = -a -e 77 78# !flaky means that it'll skip all tests using the flaky keyword 79TEST_NF = -a -p !flaky 80endif 81 82# make sure that PERL is pointing to an executable 83perlcheck: 84 @if ! test -x "$(PERL)"; then echo "No perl!"; exit 2; fi 85 86test: perlcheck all 87 $(TEST) $(TFLAGS) 88 89quiet-test: perlcheck all 90 $(TEST) $(TEST_Q) $(TFLAGS) 91 92am-test: perlcheck all 93 $(TEST) $(TEST_AM) $(TFLAGS) 94 95full-test: perlcheck all 96 $(TEST) $(TEST_F) $(TFLAGS) 97 98nonflaky-test: perlcheck all 99 $(TEST) $(TEST_NF) $(TFLAGS) 100 101torture-test: perlcheck all 102 $(TEST) $(TEST_T) $(TFLAGS) 103 104event-test: perlcheck all 105 $(TEST) $(TEST_E) $(TFLAGS) 106 107.1.html: 108 $(MAN2HTML) 109 110.1.pdf: 111 @(foo=`echo $@ | sed -e 's/\.[0-9]$$//g'`; \ 112 groff -Tps -man $< >$$foo.ps; \ 113 ps2pdf $$foo.ps $@; \ 114 rm $$foo.ps; \ 115 echo "converted $< to $@") 116 117checksrc: 118 cd libtest && $(MAKE) checksrc 119 cd unit && $(MAKE) checksrc 120 cd server && $(MAKE) checksrc 121 122if CURLDEBUG 123# for debug builds, we scan the sources on all regular make invokes 124all-local: checksrc 125endif 126