├── README.md ├── liburl ├── Win32 │ └── VC12 │ │ ├── LIB Debug │ │ └── libcurld.lib │ │ └── LIB Release │ │ └── libcurl.lib └── include │ ├── Makefile.am │ ├── Makefile.in │ ├── README │ └── curl │ ├── Makefile.am │ ├── Makefile.in │ ├── curl.h │ ├── curlbuild.h │ ├── curlbuild.h.cmake │ ├── curlbuild.h.in │ ├── curlrules.h │ ├── curlver.h │ ├── easy.h │ ├── mprintf.h │ ├── multi.h │ ├── stdcheaders.h │ └── typecheck-gcc.h ├── minihttp.sln └── minihttp ├── CMiniHttp.cpp ├── CMiniHttp.h ├── ReadMe.txt ├── minihttp.cpp ├── minihttp.vcxproj ├── minihttp.vcxproj.filters └── stdafx.h /README.md: -------------------------------------------------------------------------------- 1 | # minihttp 2 | 3 | `minihttp` is a simple https/http request library based on libcurl and openssl. 4 | 5 | support: 6 | 7 | 1. [x] https / http 8 | 2. [x] GET 9 | 3. [x] POST 10 | 4. [x] Ajax 11 | 5. [x] Cookies 12 | 6. [x] Save raw data 13 | 14 | # Usage 15 | 16 | build by vs2017. 17 | 18 | ``` 19 | int main() 20 | { 21 | CMiniHttp http; 22 | 23 | string res_; 24 | 25 | size_t size = http.get("https://www.baidu.com", res_); 26 | cout << "size = " << size << endl; 27 | cout << res_ << endl; 28 | 29 | //size_t size = http.get("http://www.baidu.com/", 80, "/index.html", res_); 30 | 31 | /* 32 | username:111 33 | userpass:11 34 | saveLogin:0 35 | */ 36 | //size_t size = http.post("http://www.xiaoshuo520.com/services/Member/chkLogin/?", "username=111&userpass=11&saveLogin=0", res_); 37 | size = http.post("http://www.xiaoshuo520.com/", 80, "services/Member/chkLogin/?", "username=111&userpass=11&saveLogin=0", res_); 38 | 39 | cout << "size = " << size << endl; 40 | cout << res_ << endl; 41 | 42 | //size = http.get("http://www.baidu.com/", 80, "/index.html", res_); 43 | size = http.ajax("http://www.xiaoshuo520.com/", 80, "services/Member/chkLogin/?", "username=admin11&userpass=admin11&saveLogin=0", res_); 44 | 45 | cout << "size = " << size << endl; 46 | cout << res_ << endl; 47 | 48 | //size = http.get("http://so.xiaoshuo520.com/kw/%E6%B1%9F%E5%B1%B1", res_); 49 | size = http.get("http://so.xiaoshuo520.com/", 80, "kw/江山", res_); 50 | 51 | return 0; 52 | } 53 | ``` 54 | 55 | You can see more informaiton [here](http://anhkgg.github.io/liburl-use-minihttp/). 56 | 57 | Contact me if there are some bugs in `minihttp`. 58 | 59 | - 公众号:[汉客儿](https://mp.weixin.qq.com/s/-h4A6MXOdPLBEIzFXY-SiA) 60 | - homepage: [anhkgg.com](anhkgg.com) 61 | - weibo: [weibo.com/anhkgg](weibo.com/anhkgg) 62 | -------------------------------------------------------------------------------- /liburl/Win32/VC12/LIB Debug/libcurld.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anhkgg/minihttp/1631b881b0a6da933a8ae29faf08f4cf753c1337/liburl/Win32/VC12/LIB Debug/libcurld.lib -------------------------------------------------------------------------------- /liburl/Win32/VC12/LIB Release/libcurl.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anhkgg/minihttp/1631b881b0a6da933a8ae29faf08f4cf753c1337/liburl/Win32/VC12/LIB Release/libcurl.lib -------------------------------------------------------------------------------- /liburl/include/Makefile.am: -------------------------------------------------------------------------------- 1 | SUBDIRS = curl 2 | 3 | EXTRA_DIST = README 4 | 5 | AUTOMAKE_OPTIONS = foreign no-dependencies 6 | -------------------------------------------------------------------------------- /liburl/include/Makefile.in: -------------------------------------------------------------------------------- 1 | # Makefile.in generated by automake 1.15 from Makefile.am. 2 | # @configure_input@ 3 | 4 | # Copyright (C) 1994-2014 Free Software Foundation, Inc. 5 | 6 | # This Makefile.in is free software; the Free Software Foundation 7 | # gives unlimited permission to copy and/or distribute it, 8 | # with or without modifications, as long as this notice is preserved. 9 | 10 | # This program is distributed in the hope that it will be useful, 11 | # but WITHOUT ANY WARRANTY, to the extent permitted by law; without 12 | # even the implied warranty of MERCHANTABILITY or FITNESS FOR A 13 | # PARTICULAR PURPOSE. 14 | 15 | @SET_MAKE@ 16 | VPATH = @srcdir@ 17 | am__is_gnu_make = { \ 18 | if test -z '$(MAKELEVEL)'; then \ 19 | false; \ 20 | elif test -n '$(MAKE_HOST)'; then \ 21 | true; \ 22 | elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ 23 | true; \ 24 | else \ 25 | false; \ 26 | fi; \ 27 | } 28 | am__make_running_with_option = \ 29 | case $${target_option-} in \ 30 | ?) ;; \ 31 | *) echo "am__make_running_with_option: internal error: invalid" \ 32 | "target option '$${target_option-}' specified" >&2; \ 33 | exit 1;; \ 34 | esac; \ 35 | has_opt=no; \ 36 | sane_makeflags=$$MAKEFLAGS; \ 37 | if $(am__is_gnu_make); then \ 38 | sane_makeflags=$$MFLAGS; \ 39 | else \ 40 | case $$MAKEFLAGS in \ 41 | *\\[\ \ ]*) \ 42 | bs=\\; \ 43 | sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ 44 | | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ 45 | esac; \ 46 | fi; \ 47 | skip_next=no; \ 48 | strip_trailopt () \ 49 | { \ 50 | flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ 51 | }; \ 52 | for flg in $$sane_makeflags; do \ 53 | test $$skip_next = yes && { skip_next=no; continue; }; \ 54 | case $$flg in \ 55 | *=*|--*) continue;; \ 56 | -*I) strip_trailopt 'I'; skip_next=yes;; \ 57 | -*I?*) strip_trailopt 'I';; \ 58 | -*O) strip_trailopt 'O'; skip_next=yes;; \ 59 | -*O?*) strip_trailopt 'O';; \ 60 | -*l) strip_trailopt 'l'; skip_next=yes;; \ 61 | -*l?*) strip_trailopt 'l';; \ 62 | -[dEDm]) skip_next=yes;; \ 63 | -[JT]) skip_next=yes;; \ 64 | esac; \ 65 | case $$flg in \ 66 | *$$target_option*) has_opt=yes; break;; \ 67 | esac; \ 68 | done; \ 69 | test $$has_opt = yes 70 | am__make_dryrun = (target_option=n; $(am__make_running_with_option)) 71 | am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) 72 | pkgdatadir = $(datadir)/@PACKAGE@ 73 | pkgincludedir = $(includedir)/@PACKAGE@ 74 | pkglibdir = $(libdir)/@PACKAGE@ 75 | pkglibexecdir = $(libexecdir)/@PACKAGE@ 76 | am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd 77 | install_sh_DATA = $(install_sh) -c -m 644 78 | install_sh_PROGRAM = $(install_sh) -c 79 | install_sh_SCRIPT = $(install_sh) -c 80 | INSTALL_HEADER = $(INSTALL_DATA) 81 | transform = $(program_transform_name) 82 | NORMAL_INSTALL = : 83 | PRE_INSTALL = : 84 | POST_INSTALL = : 85 | NORMAL_UNINSTALL = : 86 | PRE_UNINSTALL = : 87 | POST_UNINSTALL = : 88 | build_triplet = @build@ 89 | host_triplet = @host@ 90 | subdir = include 91 | ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 92 | am__aclocal_m4_deps = $(top_srcdir)/m4/curl-compilers.m4 \ 93 | $(top_srcdir)/m4/curl-confopts.m4 \ 94 | $(top_srcdir)/m4/curl-functions.m4 \ 95 | $(top_srcdir)/m4/curl-openssl.m4 \ 96 | $(top_srcdir)/m4/curl-override.m4 \ 97 | $(top_srcdir)/m4/curl-reentrant.m4 $(top_srcdir)/m4/libtool.m4 \ 98 | $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ 99 | $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ 100 | $(top_srcdir)/m4/xc-am-iface.m4 \ 101 | $(top_srcdir)/m4/xc-cc-check.m4 \ 102 | $(top_srcdir)/m4/xc-lt-iface.m4 \ 103 | $(top_srcdir)/m4/xc-translit.m4 \ 104 | $(top_srcdir)/m4/xc-val-flgs.m4 \ 105 | $(top_srcdir)/m4/zz40-xc-ovr.m4 \ 106 | $(top_srcdir)/m4/zz50-xc-ovr.m4 \ 107 | $(top_srcdir)/m4/zz60-xc-ovr.m4 $(top_srcdir)/acinclude.m4 \ 108 | $(top_srcdir)/configure.ac 109 | am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ 110 | $(ACLOCAL_M4) 111 | DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) 112 | mkinstalldirs = $(install_sh) -d 113 | CONFIG_HEADER = $(top_builddir)/lib/curl_config.h \ 114 | $(top_builddir)/include/curl/curlbuild.h 115 | CONFIG_CLEAN_FILES = 116 | CONFIG_CLEAN_VPATH_FILES = 117 | AM_V_P = $(am__v_P_@AM_V@) 118 | am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) 119 | am__v_P_0 = false 120 | am__v_P_1 = : 121 | AM_V_GEN = $(am__v_GEN_@AM_V@) 122 | am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) 123 | am__v_GEN_0 = @echo " GEN " $@; 124 | am__v_GEN_1 = 125 | AM_V_at = $(am__v_at_@AM_V@) 126 | am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) 127 | am__v_at_0 = @ 128 | am__v_at_1 = 129 | depcomp = 130 | am__depfiles_maybe = 131 | SOURCES = 132 | DIST_SOURCES = 133 | RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ 134 | ctags-recursive dvi-recursive html-recursive info-recursive \ 135 | install-data-recursive install-dvi-recursive \ 136 | install-exec-recursive install-html-recursive \ 137 | install-info-recursive install-pdf-recursive \ 138 | install-ps-recursive install-recursive installcheck-recursive \ 139 | installdirs-recursive pdf-recursive ps-recursive \ 140 | tags-recursive uninstall-recursive 141 | am__can_run_installinfo = \ 142 | case $$AM_UPDATE_INFO_DIR in \ 143 | n|no|NO) false;; \ 144 | *) (install-info --version) >/dev/null 2>&1;; \ 145 | esac 146 | RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ 147 | distclean-recursive maintainer-clean-recursive 148 | am__recursive_targets = \ 149 | $(RECURSIVE_TARGETS) \ 150 | $(RECURSIVE_CLEAN_TARGETS) \ 151 | $(am__extra_recursive_targets) 152 | AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ 153 | distdir 154 | am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) 155 | # Read a list of newline-separated strings from the standard input, 156 | # and print each of them once, without duplicates. Input order is 157 | # *not* preserved. 158 | am__uniquify_input = $(AWK) '\ 159 | BEGIN { nonempty = 0; } \ 160 | { items[$$0] = 1; nonempty = 1; } \ 161 | END { if (nonempty) { for (i in items) print i; }; } \ 162 | ' 163 | # Make sure the list of sources is unique. This is necessary because, 164 | # e.g., the same source file might be shared among _SOURCES variables 165 | # for different programs/libraries. 166 | am__define_uniq_tagged_files = \ 167 | list='$(am__tagged_files)'; \ 168 | unique=`for i in $$list; do \ 169 | if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ 170 | done | $(am__uniquify_input)` 171 | ETAGS = etags 172 | CTAGS = ctags 173 | DIST_SUBDIRS = $(SUBDIRS) 174 | am__DIST_COMMON = $(srcdir)/Makefile.in README 175 | DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) 176 | am__relativize = \ 177 | dir0=`pwd`; \ 178 | sed_first='s,^\([^/]*\)/.*$$,\1,'; \ 179 | sed_rest='s,^[^/]*/*,,'; \ 180 | sed_last='s,^.*/\([^/]*\)$$,\1,'; \ 181 | sed_butlast='s,/*[^/]*$$,,'; \ 182 | while test -n "$$dir1"; do \ 183 | first=`echo "$$dir1" | sed -e "$$sed_first"`; \ 184 | if test "$$first" != "."; then \ 185 | if test "$$first" = ".."; then \ 186 | dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ 187 | dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ 188 | else \ 189 | first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ 190 | if test "$$first2" = "$$first"; then \ 191 | dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ 192 | else \ 193 | dir2="../$$dir2"; \ 194 | fi; \ 195 | dir0="$$dir0"/"$$first"; \ 196 | fi; \ 197 | fi; \ 198 | dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ 199 | done; \ 200 | reldir="$$dir2" 201 | ACLOCAL = @ACLOCAL@ 202 | AMTAR = @AMTAR@ 203 | AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ 204 | AR = @AR@ 205 | AS = @AS@ 206 | AUTOCONF = @AUTOCONF@ 207 | AUTOHEADER = @AUTOHEADER@ 208 | AUTOMAKE = @AUTOMAKE@ 209 | AWK = @AWK@ 210 | BLANK_AT_MAKETIME = @BLANK_AT_MAKETIME@ 211 | CC = @CC@ 212 | CCDEPMODE = @CCDEPMODE@ 213 | CFLAGS = @CFLAGS@ 214 | CFLAG_CURL_SYMBOL_HIDING = @CFLAG_CURL_SYMBOL_HIDING@ 215 | CONFIGURE_OPTIONS = @CONFIGURE_OPTIONS@ 216 | CPP = @CPP@ 217 | CPPFLAGS = @CPPFLAGS@ 218 | CPPFLAG_CURL_STATICLIB = @CPPFLAG_CURL_STATICLIB@ 219 | CURLVERSION = @CURLVERSION@ 220 | CURL_CA_BUNDLE = @CURL_CA_BUNDLE@ 221 | CURL_CFLAG_EXTRAS = @CURL_CFLAG_EXTRAS@ 222 | CURL_DISABLE_DICT = @CURL_DISABLE_DICT@ 223 | CURL_DISABLE_FILE = @CURL_DISABLE_FILE@ 224 | CURL_DISABLE_FTP = @CURL_DISABLE_FTP@ 225 | CURL_DISABLE_GOPHER = @CURL_DISABLE_GOPHER@ 226 | CURL_DISABLE_HTTP = @CURL_DISABLE_HTTP@ 227 | CURL_DISABLE_IMAP = @CURL_DISABLE_IMAP@ 228 | CURL_DISABLE_LDAP = @CURL_DISABLE_LDAP@ 229 | CURL_DISABLE_LDAPS = @CURL_DISABLE_LDAPS@ 230 | CURL_DISABLE_POP3 = @CURL_DISABLE_POP3@ 231 | CURL_DISABLE_PROXY = @CURL_DISABLE_PROXY@ 232 | CURL_DISABLE_RTSP = @CURL_DISABLE_RTSP@ 233 | CURL_DISABLE_SMB = @CURL_DISABLE_SMB@ 234 | CURL_DISABLE_SMTP = @CURL_DISABLE_SMTP@ 235 | CURL_DISABLE_TELNET = @CURL_DISABLE_TELNET@ 236 | CURL_DISABLE_TFTP = @CURL_DISABLE_TFTP@ 237 | CURL_LT_SHLIB_VERSIONED_FLAVOUR = @CURL_LT_SHLIB_VERSIONED_FLAVOUR@ 238 | CURL_NETWORK_AND_TIME_LIBS = @CURL_NETWORK_AND_TIME_LIBS@ 239 | CURL_NETWORK_LIBS = @CURL_NETWORK_LIBS@ 240 | CYGPATH_W = @CYGPATH_W@ 241 | DEFS = @DEFS@ 242 | DEPDIR = @DEPDIR@ 243 | DLLTOOL = @DLLTOOL@ 244 | DSYMUTIL = @DSYMUTIL@ 245 | DUMPBIN = @DUMPBIN@ 246 | ECHO_C = @ECHO_C@ 247 | ECHO_N = @ECHO_N@ 248 | ECHO_T = @ECHO_T@ 249 | EGREP = @EGREP@ 250 | ENABLE_SHARED = @ENABLE_SHARED@ 251 | ENABLE_STATIC = @ENABLE_STATIC@ 252 | EXEEXT = @EXEEXT@ 253 | FGREP = @FGREP@ 254 | GREP = @GREP@ 255 | HAVE_GNUTLS_SRP = @HAVE_GNUTLS_SRP@ 256 | HAVE_LDAP_SSL = @HAVE_LDAP_SSL@ 257 | HAVE_LIBZ = @HAVE_LIBZ@ 258 | HAVE_OPENSSL_SRP = @HAVE_OPENSSL_SRP@ 259 | IDN_ENABLED = @IDN_ENABLED@ 260 | INSTALL = @INSTALL@ 261 | INSTALL_DATA = @INSTALL_DATA@ 262 | INSTALL_PROGRAM = @INSTALL_PROGRAM@ 263 | INSTALL_SCRIPT = @INSTALL_SCRIPT@ 264 | INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ 265 | IPV6_ENABLED = @IPV6_ENABLED@ 266 | LD = @LD@ 267 | LDFLAGS = @LDFLAGS@ 268 | LIBCURL_LIBS = @LIBCURL_LIBS@ 269 | LIBMETALINK_CPPFLAGS = @LIBMETALINK_CPPFLAGS@ 270 | LIBMETALINK_LDFLAGS = @LIBMETALINK_LDFLAGS@ 271 | LIBMETALINK_LIBS = @LIBMETALINK_LIBS@ 272 | LIBOBJS = @LIBOBJS@ 273 | LIBS = @LIBS@ 274 | LIBTOOL = @LIBTOOL@ 275 | LIPO = @LIPO@ 276 | LN_S = @LN_S@ 277 | LTLIBOBJS = @LTLIBOBJS@ 278 | LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ 279 | MAINT = @MAINT@ 280 | MAKEINFO = @MAKEINFO@ 281 | MANIFEST_TOOL = @MANIFEST_TOOL@ 282 | MANOPT = @MANOPT@ 283 | MKDIR_P = @MKDIR_P@ 284 | NM = @NM@ 285 | NMEDIT = @NMEDIT@ 286 | NROFF = @NROFF@ 287 | NSS_LIBS = @NSS_LIBS@ 288 | OBJDUMP = @OBJDUMP@ 289 | OBJEXT = @OBJEXT@ 290 | OTOOL = @OTOOL@ 291 | OTOOL64 = @OTOOL64@ 292 | PACKAGE = @PACKAGE@ 293 | PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ 294 | PACKAGE_NAME = @PACKAGE_NAME@ 295 | PACKAGE_STRING = @PACKAGE_STRING@ 296 | PACKAGE_TARNAME = @PACKAGE_TARNAME@ 297 | PACKAGE_URL = @PACKAGE_URL@ 298 | PACKAGE_VERSION = @PACKAGE_VERSION@ 299 | PATH_SEPARATOR = @PATH_SEPARATOR@ 300 | PERL = @PERL@ 301 | PKGADD_NAME = @PKGADD_NAME@ 302 | PKGADD_PKG = @PKGADD_PKG@ 303 | PKGADD_VENDOR = @PKGADD_VENDOR@ 304 | PKGCONFIG = @PKGCONFIG@ 305 | RANDOM_FILE = @RANDOM_FILE@ 306 | RANLIB = @RANLIB@ 307 | REQUIRE_LIB_DEPS = @REQUIRE_LIB_DEPS@ 308 | SED = @SED@ 309 | SET_MAKE = @SET_MAKE@ 310 | SHELL = @SHELL@ 311 | SSL_ENABLED = @SSL_ENABLED@ 312 | SSL_LIBS = @SSL_LIBS@ 313 | STRIP = @STRIP@ 314 | SUPPORT_FEATURES = @SUPPORT_FEATURES@ 315 | SUPPORT_PROTOCOLS = @SUPPORT_PROTOCOLS@ 316 | USE_ARES = @USE_ARES@ 317 | USE_AXTLS = @USE_AXTLS@ 318 | USE_CYASSL = @USE_CYASSL@ 319 | USE_DARWINSSL = @USE_DARWINSSL@ 320 | USE_GNUTLS = @USE_GNUTLS@ 321 | USE_GNUTLS_NETTLE = @USE_GNUTLS_NETTLE@ 322 | USE_LIBRTMP = @USE_LIBRTMP@ 323 | USE_LIBSSH2 = @USE_LIBSSH2@ 324 | USE_MBEDTLS = @USE_MBEDTLS@ 325 | USE_NGHTTP2 = @USE_NGHTTP2@ 326 | USE_NSS = @USE_NSS@ 327 | USE_OPENLDAP = @USE_OPENLDAP@ 328 | USE_POLARSSL = @USE_POLARSSL@ 329 | USE_SCHANNEL = @USE_SCHANNEL@ 330 | USE_UNIX_SOCKETS = @USE_UNIX_SOCKETS@ 331 | USE_WINDOWS_SSPI = @USE_WINDOWS_SSPI@ 332 | VERSION = @VERSION@ 333 | VERSIONNUM = @VERSIONNUM@ 334 | ZLIB_LIBS = @ZLIB_LIBS@ 335 | ZSH_FUNCTIONS_DIR = @ZSH_FUNCTIONS_DIR@ 336 | abs_builddir = @abs_builddir@ 337 | abs_srcdir = @abs_srcdir@ 338 | abs_top_builddir = @abs_top_builddir@ 339 | abs_top_srcdir = @abs_top_srcdir@ 340 | ac_ct_AR = @ac_ct_AR@ 341 | ac_ct_CC = @ac_ct_CC@ 342 | ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ 343 | am__include = @am__include@ 344 | am__leading_dot = @am__leading_dot@ 345 | am__quote = @am__quote@ 346 | am__tar = @am__tar@ 347 | am__untar = @am__untar@ 348 | bindir = @bindir@ 349 | build = @build@ 350 | build_alias = @build_alias@ 351 | build_cpu = @build_cpu@ 352 | build_os = @build_os@ 353 | build_vendor = @build_vendor@ 354 | builddir = @builddir@ 355 | datadir = @datadir@ 356 | datarootdir = @datarootdir@ 357 | docdir = @docdir@ 358 | dvidir = @dvidir@ 359 | exec_prefix = @exec_prefix@ 360 | host = @host@ 361 | host_alias = @host_alias@ 362 | host_cpu = @host_cpu@ 363 | host_os = @host_os@ 364 | host_vendor = @host_vendor@ 365 | htmldir = @htmldir@ 366 | includedir = @includedir@ 367 | infodir = @infodir@ 368 | install_sh = @install_sh@ 369 | libdir = @libdir@ 370 | libexecdir = @libexecdir@ 371 | libext = @libext@ 372 | localedir = @localedir@ 373 | localstatedir = @localstatedir@ 374 | mandir = @mandir@ 375 | mkdir_p = @mkdir_p@ 376 | oldincludedir = @oldincludedir@ 377 | pdfdir = @pdfdir@ 378 | prefix = @prefix@ 379 | program_transform_name = @program_transform_name@ 380 | psdir = @psdir@ 381 | runstatedir = @runstatedir@ 382 | sbindir = @sbindir@ 383 | sharedstatedir = @sharedstatedir@ 384 | srcdir = @srcdir@ 385 | subdirs = @subdirs@ 386 | sysconfdir = @sysconfdir@ 387 | target_alias = @target_alias@ 388 | top_build_prefix = @top_build_prefix@ 389 | top_builddir = @top_builddir@ 390 | top_srcdir = @top_srcdir@ 391 | SUBDIRS = curl 392 | EXTRA_DIST = README 393 | AUTOMAKE_OPTIONS = foreign no-dependencies 394 | all: all-recursive 395 | 396 | .SUFFIXES: 397 | $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) 398 | @for dep in $?; do \ 399 | case '$(am__configure_deps)' in \ 400 | *$$dep*) \ 401 | ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ 402 | && { if test -f $@; then exit 0; else break; fi; }; \ 403 | exit 1;; \ 404 | esac; \ 405 | done; \ 406 | echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign include/Makefile'; \ 407 | $(am__cd) $(top_srcdir) && \ 408 | $(AUTOMAKE) --foreign include/Makefile 409 | Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status 410 | @case '$?' in \ 411 | *config.status*) \ 412 | cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ 413 | *) \ 414 | echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ 415 | cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ 416 | esac; 417 | 418 | $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) 419 | cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh 420 | 421 | $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) 422 | cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh 423 | $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) 424 | cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh 425 | $(am__aclocal_m4_deps): 426 | 427 | mostlyclean-libtool: 428 | -rm -f *.lo 429 | 430 | clean-libtool: 431 | -rm -rf .libs _libs 432 | 433 | # This directory's subdirectories are mostly independent; you can cd 434 | # into them and run 'make' without going through this Makefile. 435 | # To change the values of 'make' variables: instead of editing Makefiles, 436 | # (1) if the variable is set in 'config.status', edit 'config.status' 437 | # (which will cause the Makefiles to be regenerated when you run 'make'); 438 | # (2) otherwise, pass the desired values on the 'make' command line. 439 | $(am__recursive_targets): 440 | @fail=; \ 441 | if $(am__make_keepgoing); then \ 442 | failcom='fail=yes'; \ 443 | else \ 444 | failcom='exit 1'; \ 445 | fi; \ 446 | dot_seen=no; \ 447 | target=`echo $@ | sed s/-recursive//`; \ 448 | case "$@" in \ 449 | distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ 450 | *) list='$(SUBDIRS)' ;; \ 451 | esac; \ 452 | for subdir in $$list; do \ 453 | echo "Making $$target in $$subdir"; \ 454 | if test "$$subdir" = "."; then \ 455 | dot_seen=yes; \ 456 | local_target="$$target-am"; \ 457 | else \ 458 | local_target="$$target"; \ 459 | fi; \ 460 | ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ 461 | || eval $$failcom; \ 462 | done; \ 463 | if test "$$dot_seen" = "no"; then \ 464 | $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ 465 | fi; test -z "$$fail" 466 | 467 | ID: $(am__tagged_files) 468 | $(am__define_uniq_tagged_files); mkid -fID $$unique 469 | tags: tags-recursive 470 | TAGS: tags 471 | 472 | tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) 473 | set x; \ 474 | here=`pwd`; \ 475 | if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ 476 | include_option=--etags-include; \ 477 | empty_fix=.; \ 478 | else \ 479 | include_option=--include; \ 480 | empty_fix=; \ 481 | fi; \ 482 | list='$(SUBDIRS)'; for subdir in $$list; do \ 483 | if test "$$subdir" = .; then :; else \ 484 | test ! -f $$subdir/TAGS || \ 485 | set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ 486 | fi; \ 487 | done; \ 488 | $(am__define_uniq_tagged_files); \ 489 | shift; \ 490 | if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ 491 | test -n "$$unique" || unique=$$empty_fix; \ 492 | if test $$# -gt 0; then \ 493 | $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ 494 | "$$@" $$unique; \ 495 | else \ 496 | $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ 497 | $$unique; \ 498 | fi; \ 499 | fi 500 | ctags: ctags-recursive 501 | 502 | CTAGS: ctags 503 | ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) 504 | $(am__define_uniq_tagged_files); \ 505 | test -z "$(CTAGS_ARGS)$$unique" \ 506 | || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ 507 | $$unique 508 | 509 | GTAGS: 510 | here=`$(am__cd) $(top_builddir) && pwd` \ 511 | && $(am__cd) $(top_srcdir) \ 512 | && gtags -i $(GTAGS_ARGS) "$$here" 513 | cscopelist: cscopelist-recursive 514 | 515 | cscopelist-am: $(am__tagged_files) 516 | list='$(am__tagged_files)'; \ 517 | case "$(srcdir)" in \ 518 | [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ 519 | *) sdir=$(subdir)/$(srcdir) ;; \ 520 | esac; \ 521 | for i in $$list; do \ 522 | if test -f "$$i"; then \ 523 | echo "$(subdir)/$$i"; \ 524 | else \ 525 | echo "$$sdir/$$i"; \ 526 | fi; \ 527 | done >> $(top_builddir)/cscope.files 528 | 529 | distclean-tags: 530 | -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags 531 | 532 | distdir: $(DISTFILES) 533 | @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ 534 | topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ 535 | list='$(DISTFILES)'; \ 536 | dist_files=`for file in $$list; do echo $$file; done | \ 537 | sed -e "s|^$$srcdirstrip/||;t" \ 538 | -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ 539 | case $$dist_files in \ 540 | */*) $(MKDIR_P) `echo "$$dist_files" | \ 541 | sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ 542 | sort -u` ;; \ 543 | esac; \ 544 | for file in $$dist_files; do \ 545 | if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ 546 | if test -d $$d/$$file; then \ 547 | dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ 548 | if test -d "$(distdir)/$$file"; then \ 549 | find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ 550 | fi; \ 551 | if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ 552 | cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ 553 | find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ 554 | fi; \ 555 | cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ 556 | else \ 557 | test -f "$(distdir)/$$file" \ 558 | || cp -p $$d/$$file "$(distdir)/$$file" \ 559 | || exit 1; \ 560 | fi; \ 561 | done 562 | @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ 563 | if test "$$subdir" = .; then :; else \ 564 | $(am__make_dryrun) \ 565 | || test -d "$(distdir)/$$subdir" \ 566 | || $(MKDIR_P) "$(distdir)/$$subdir" \ 567 | || exit 1; \ 568 | dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ 569 | $(am__relativize); \ 570 | new_distdir=$$reldir; \ 571 | dir1=$$subdir; dir2="$(top_distdir)"; \ 572 | $(am__relativize); \ 573 | new_top_distdir=$$reldir; \ 574 | echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ 575 | echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ 576 | ($(am__cd) $$subdir && \ 577 | $(MAKE) $(AM_MAKEFLAGS) \ 578 | top_distdir="$$new_top_distdir" \ 579 | distdir="$$new_distdir" \ 580 | am__remove_distdir=: \ 581 | am__skip_length_check=: \ 582 | am__skip_mode_fix=: \ 583 | distdir) \ 584 | || exit 1; \ 585 | fi; \ 586 | done 587 | check-am: all-am 588 | check: check-recursive 589 | all-am: Makefile 590 | installdirs: installdirs-recursive 591 | installdirs-am: 592 | install: install-recursive 593 | install-exec: install-exec-recursive 594 | install-data: install-data-recursive 595 | uninstall: uninstall-recursive 596 | 597 | install-am: all-am 598 | @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am 599 | 600 | installcheck: installcheck-recursive 601 | install-strip: 602 | if test -z '$(STRIP)'; then \ 603 | $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ 604 | install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ 605 | install; \ 606 | else \ 607 | $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ 608 | install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ 609 | "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ 610 | fi 611 | mostlyclean-generic: 612 | 613 | clean-generic: 614 | 615 | distclean-generic: 616 | -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) 617 | -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) 618 | 619 | maintainer-clean-generic: 620 | @echo "This command is intended for maintainers to use" 621 | @echo "it deletes files that may require special tools to rebuild." 622 | clean: clean-recursive 623 | 624 | clean-am: clean-generic clean-libtool mostlyclean-am 625 | 626 | distclean: distclean-recursive 627 | -rm -f Makefile 628 | distclean-am: clean-am distclean-generic distclean-tags 629 | 630 | dvi: dvi-recursive 631 | 632 | dvi-am: 633 | 634 | html: html-recursive 635 | 636 | html-am: 637 | 638 | info: info-recursive 639 | 640 | info-am: 641 | 642 | install-data-am: 643 | 644 | install-dvi: install-dvi-recursive 645 | 646 | install-dvi-am: 647 | 648 | install-exec-am: 649 | 650 | install-html: install-html-recursive 651 | 652 | install-html-am: 653 | 654 | install-info: install-info-recursive 655 | 656 | install-info-am: 657 | 658 | install-man: 659 | 660 | install-pdf: install-pdf-recursive 661 | 662 | install-pdf-am: 663 | 664 | install-ps: install-ps-recursive 665 | 666 | install-ps-am: 667 | 668 | installcheck-am: 669 | 670 | maintainer-clean: maintainer-clean-recursive 671 | -rm -f Makefile 672 | maintainer-clean-am: distclean-am maintainer-clean-generic 673 | 674 | mostlyclean: mostlyclean-recursive 675 | 676 | mostlyclean-am: mostlyclean-generic mostlyclean-libtool 677 | 678 | pdf: pdf-recursive 679 | 680 | pdf-am: 681 | 682 | ps: ps-recursive 683 | 684 | ps-am: 685 | 686 | uninstall-am: 687 | 688 | .MAKE: $(am__recursive_targets) install-am install-strip 689 | 690 | .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ 691 | check-am clean clean-generic clean-libtool cscopelist-am ctags \ 692 | ctags-am distclean distclean-generic distclean-libtool \ 693 | distclean-tags distdir dvi dvi-am html html-am info info-am \ 694 | install install-am install-data install-data-am install-dvi \ 695 | install-dvi-am install-exec install-exec-am install-html \ 696 | install-html-am install-info install-info-am install-man \ 697 | install-pdf install-pdf-am install-ps install-ps-am \ 698 | install-strip installcheck installcheck-am installdirs \ 699 | installdirs-am maintainer-clean maintainer-clean-generic \ 700 | mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ 701 | ps ps-am tags tags-am uninstall uninstall-am 702 | 703 | .PRECIOUS: Makefile 704 | 705 | 706 | # Tell versions [3.59,3.63) of GNU make to not export all variables. 707 | # Otherwise a system limit (for SysV at least) may be exceeded. 708 | .NOEXPORT: 709 | -------------------------------------------------------------------------------- /liburl/include/README: -------------------------------------------------------------------------------- 1 | _ _ ____ _ 2 | ___| | | | _ \| | 3 | / __| | | | |_) | | 4 | | (__| |_| | _ <| |___ 5 | \___|\___/|_| \_\_____| 6 | 7 | Include files for libcurl, external users. 8 | 9 | They're all placed in the curl subdirectory here for better fit in any kind 10 | of environment. You must include files from here using... 11 | 12 | #include 13 | 14 | ... style and point the compiler's include path to the directory holding the 15 | curl subdirectory. It makes it more likely to survive future modifications. 16 | 17 | NOTE FOR LIBCURL HACKERS 18 | 19 | The following notes apply to libcurl version 7.19.0 and later. 20 | 21 | * The distributed curl/curlbuild.h file is only intended to be used on systems 22 | which can not run the also distributed configure script. 23 | 24 | * The distributed curlbuild.h file is generated as a copy of curlbuild.h.dist 25 | when the libcurl source code distribution archive file is originally created. 26 | 27 | * If you check out from git on a non-configure platform, you must run the 28 | appropriate buildconf* script to set up curlbuild.h and other local files 29 | before being able of compiling the library. 30 | 31 | * On systems capable of running the configure script, the configure process 32 | will overwrite the distributed include/curl/curlbuild.h file with one that 33 | is suitable and specific to the library being configured and built, which 34 | is generated from the include/curl/curlbuild.h.in template file. 35 | 36 | * If you intend to distribute an already compiled libcurl library you _MUST_ 37 | also distribute along with it the generated curl/curlbuild.h which has been 38 | used to compile it. Otherwise the library will be of no use for the users of 39 | the library that you have built. It is _your_ responsibility to provide this 40 | file. No one at the cURL project can know how you have built the library. 41 | 42 | * File curl/curlbuild.h includes platform and configuration dependent info, 43 | and must not be modified by anyone. Configure script generates it for you. 44 | 45 | * We cannot assume anything else but very basic compiler features being 46 | present. While libcurl requires an ANSI C compiler to build, some of the 47 | earlier ANSI compilers clearly can't deal with some preprocessor operators. 48 | 49 | * Newlines must remain unix-style for older compilers' sake. 50 | 51 | * Comments must be written in the old-style /* unnested C-fashion */ 52 | 53 | To figure out how to do good and portable checks for features, operating 54 | systems or specific hardwarare, a very good resource is Bjorn Reese's 55 | collection at http://predef.sf.net/ 56 | -------------------------------------------------------------------------------- /liburl/include/curl/Makefile.am: -------------------------------------------------------------------------------- 1 | #*************************************************************************** 2 | # _ _ ____ _ 3 | # Project ___| | | | _ \| | 4 | # / __| | | | |_) | | 5 | # | (__| |_| | _ <| |___ 6 | # \___|\___/|_| \_\_____| 7 | # 8 | # Copyright (C) 1998 - 2011, Daniel Stenberg, , 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 | pkginclude_HEADERS = \ 23 | curl.h curlver.h easy.h mprintf.h stdcheaders.h multi.h \ 24 | typecheck-gcc.h curlbuild.h curlrules.h 25 | 26 | pkgincludedir= $(includedir)/curl 27 | 28 | # curlbuild.h does not exist in the git tree. When the original libcurl 29 | # source code distribution archive file is created, curlbuild.h.dist is 30 | # renamed to curlbuild.h and included in the tarball so that it can be 31 | # used directly on non-configure systems. 32 | # 33 | # The distributed curlbuild.h will be overwritten on configure systems 34 | # when the configure script runs, with one that is suitable and specific 35 | # to the library being configured and built. 36 | # 37 | # curlbuild.h.in is the distributed template file from which the configure 38 | # script creates curlbuild.h at library configuration time, overwiting the 39 | # one included in the distribution archive. 40 | # 41 | # curlbuild.h.dist is not included in the source code distribution archive. 42 | 43 | EXTRA_DIST = curlbuild.h.in 44 | 45 | DISTCLEANFILES = curlbuild.h 46 | 47 | checksrc: 48 | @@PERL@ $(top_srcdir)/lib/checksrc.pl -Wcurlbuild.h -D$(top_srcdir)/include/curl $(pkginclude_HEADERS) $(EXTRA_DIST) 49 | 50 | if CURLDEBUG 51 | # for debug builds, we scan the sources on all regular make invokes 52 | all-local: checksrc 53 | endif 54 | -------------------------------------------------------------------------------- /liburl/include/curl/Makefile.in: -------------------------------------------------------------------------------- 1 | # Makefile.in generated by automake 1.15 from Makefile.am. 2 | # @configure_input@ 3 | 4 | # Copyright (C) 1994-2014 Free Software Foundation, Inc. 5 | 6 | # This Makefile.in is free software; the Free Software Foundation 7 | # gives unlimited permission to copy and/or distribute it, 8 | # with or without modifications, as long as this notice is preserved. 9 | 10 | # This program is distributed in the hope that it will be useful, 11 | # but WITHOUT ANY WARRANTY, to the extent permitted by law; without 12 | # even the implied warranty of MERCHANTABILITY or FITNESS FOR A 13 | # PARTICULAR PURPOSE. 14 | 15 | @SET_MAKE@ 16 | 17 | VPATH = @srcdir@ 18 | am__is_gnu_make = { \ 19 | if test -z '$(MAKELEVEL)'; then \ 20 | false; \ 21 | elif test -n '$(MAKE_HOST)'; then \ 22 | true; \ 23 | elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ 24 | true; \ 25 | else \ 26 | false; \ 27 | fi; \ 28 | } 29 | am__make_running_with_option = \ 30 | case $${target_option-} in \ 31 | ?) ;; \ 32 | *) echo "am__make_running_with_option: internal error: invalid" \ 33 | "target option '$${target_option-}' specified" >&2; \ 34 | exit 1;; \ 35 | esac; \ 36 | has_opt=no; \ 37 | sane_makeflags=$$MAKEFLAGS; \ 38 | if $(am__is_gnu_make); then \ 39 | sane_makeflags=$$MFLAGS; \ 40 | else \ 41 | case $$MAKEFLAGS in \ 42 | *\\[\ \ ]*) \ 43 | bs=\\; \ 44 | sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ 45 | | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ 46 | esac; \ 47 | fi; \ 48 | skip_next=no; \ 49 | strip_trailopt () \ 50 | { \ 51 | flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ 52 | }; \ 53 | for flg in $$sane_makeflags; do \ 54 | test $$skip_next = yes && { skip_next=no; continue; }; \ 55 | case $$flg in \ 56 | *=*|--*) continue;; \ 57 | -*I) strip_trailopt 'I'; skip_next=yes;; \ 58 | -*I?*) strip_trailopt 'I';; \ 59 | -*O) strip_trailopt 'O'; skip_next=yes;; \ 60 | -*O?*) strip_trailopt 'O';; \ 61 | -*l) strip_trailopt 'l'; skip_next=yes;; \ 62 | -*l?*) strip_trailopt 'l';; \ 63 | -[dEDm]) skip_next=yes;; \ 64 | -[JT]) skip_next=yes;; \ 65 | esac; \ 66 | case $$flg in \ 67 | *$$target_option*) has_opt=yes; break;; \ 68 | esac; \ 69 | done; \ 70 | test $$has_opt = yes 71 | am__make_dryrun = (target_option=n; $(am__make_running_with_option)) 72 | am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) 73 | pkgdatadir = $(datadir)/@PACKAGE@ 74 | pkglibdir = $(libdir)/@PACKAGE@ 75 | pkglibexecdir = $(libexecdir)/@PACKAGE@ 76 | am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd 77 | install_sh_DATA = $(install_sh) -c -m 644 78 | install_sh_PROGRAM = $(install_sh) -c 79 | install_sh_SCRIPT = $(install_sh) -c 80 | INSTALL_HEADER = $(INSTALL_DATA) 81 | transform = $(program_transform_name) 82 | NORMAL_INSTALL = : 83 | PRE_INSTALL = : 84 | POST_INSTALL = : 85 | NORMAL_UNINSTALL = : 86 | PRE_UNINSTALL = : 87 | POST_UNINSTALL = : 88 | build_triplet = @build@ 89 | host_triplet = @host@ 90 | subdir = include/curl 91 | ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 92 | am__aclocal_m4_deps = $(top_srcdir)/m4/curl-compilers.m4 \ 93 | $(top_srcdir)/m4/curl-confopts.m4 \ 94 | $(top_srcdir)/m4/curl-functions.m4 \ 95 | $(top_srcdir)/m4/curl-openssl.m4 \ 96 | $(top_srcdir)/m4/curl-override.m4 \ 97 | $(top_srcdir)/m4/curl-reentrant.m4 $(top_srcdir)/m4/libtool.m4 \ 98 | $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ 99 | $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ 100 | $(top_srcdir)/m4/xc-am-iface.m4 \ 101 | $(top_srcdir)/m4/xc-cc-check.m4 \ 102 | $(top_srcdir)/m4/xc-lt-iface.m4 \ 103 | $(top_srcdir)/m4/xc-translit.m4 \ 104 | $(top_srcdir)/m4/xc-val-flgs.m4 \ 105 | $(top_srcdir)/m4/zz40-xc-ovr.m4 \ 106 | $(top_srcdir)/m4/zz50-xc-ovr.m4 \ 107 | $(top_srcdir)/m4/zz60-xc-ovr.m4 $(top_srcdir)/acinclude.m4 \ 108 | $(top_srcdir)/configure.ac 109 | am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ 110 | $(ACLOCAL_M4) 111 | DIST_COMMON = $(srcdir)/Makefile.am $(pkginclude_HEADERS) \ 112 | $(am__DIST_COMMON) 113 | mkinstalldirs = $(install_sh) -d 114 | CONFIG_HEADER = $(top_builddir)/lib/curl_config.h curlbuild.h 115 | CONFIG_CLEAN_FILES = 116 | CONFIG_CLEAN_VPATH_FILES = 117 | AM_V_P = $(am__v_P_@AM_V@) 118 | am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) 119 | am__v_P_0 = false 120 | am__v_P_1 = : 121 | AM_V_GEN = $(am__v_GEN_@AM_V@) 122 | am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) 123 | am__v_GEN_0 = @echo " GEN " $@; 124 | am__v_GEN_1 = 125 | AM_V_at = $(am__v_at_@AM_V@) 126 | am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) 127 | am__v_at_0 = @ 128 | am__v_at_1 = 129 | SOURCES = 130 | DIST_SOURCES = 131 | am__can_run_installinfo = \ 132 | case $$AM_UPDATE_INFO_DIR in \ 133 | n|no|NO) false;; \ 134 | *) (install-info --version) >/dev/null 2>&1;; \ 135 | esac 136 | am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; 137 | am__vpath_adj = case $$p in \ 138 | $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ 139 | *) f=$$p;; \ 140 | esac; 141 | am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; 142 | am__install_max = 40 143 | am__nobase_strip_setup = \ 144 | srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` 145 | am__nobase_strip = \ 146 | for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" 147 | am__nobase_list = $(am__nobase_strip_setup); \ 148 | for p in $$list; do echo "$$p $$p"; done | \ 149 | sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ 150 | $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ 151 | if (++n[$$2] == $(am__install_max)) \ 152 | { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ 153 | END { for (dir in files) print dir, files[dir] }' 154 | am__base_list = \ 155 | sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ 156 | sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' 157 | am__uninstall_files_from_dir = { \ 158 | test -z "$$files" \ 159 | || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ 160 | || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ 161 | $(am__cd) "$$dir" && rm -f $$files; }; \ 162 | } 163 | am__installdirs = "$(DESTDIR)$(pkgincludedir)" 164 | HEADERS = $(pkginclude_HEADERS) 165 | am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) \ 166 | $(LISP)curlbuild.h.in 167 | # Read a list of newline-separated strings from the standard input, 168 | # and print each of them once, without duplicates. Input order is 169 | # *not* preserved. 170 | am__uniquify_input = $(AWK) '\ 171 | BEGIN { nonempty = 0; } \ 172 | { items[$$0] = 1; nonempty = 1; } \ 173 | END { if (nonempty) { for (i in items) print i; }; } \ 174 | ' 175 | # Make sure the list of sources is unique. This is necessary because, 176 | # e.g., the same source file might be shared among _SOURCES variables 177 | # for different programs/libraries. 178 | am__define_uniq_tagged_files = \ 179 | list='$(am__tagged_files)'; \ 180 | unique=`for i in $$list; do \ 181 | if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ 182 | done | $(am__uniquify_input)` 183 | ETAGS = etags 184 | CTAGS = ctags 185 | am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/curlbuild.h.in 186 | DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) 187 | pkgincludedir = $(includedir)/curl 188 | ACLOCAL = @ACLOCAL@ 189 | AMTAR = @AMTAR@ 190 | AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ 191 | AR = @AR@ 192 | AS = @AS@ 193 | AUTOCONF = @AUTOCONF@ 194 | AUTOHEADER = @AUTOHEADER@ 195 | AUTOMAKE = @AUTOMAKE@ 196 | AWK = @AWK@ 197 | BLANK_AT_MAKETIME = @BLANK_AT_MAKETIME@ 198 | CC = @CC@ 199 | CCDEPMODE = @CCDEPMODE@ 200 | CFLAGS = @CFLAGS@ 201 | CFLAG_CURL_SYMBOL_HIDING = @CFLAG_CURL_SYMBOL_HIDING@ 202 | CONFIGURE_OPTIONS = @CONFIGURE_OPTIONS@ 203 | CPP = @CPP@ 204 | CPPFLAGS = @CPPFLAGS@ 205 | CPPFLAG_CURL_STATICLIB = @CPPFLAG_CURL_STATICLIB@ 206 | CURLVERSION = @CURLVERSION@ 207 | CURL_CA_BUNDLE = @CURL_CA_BUNDLE@ 208 | CURL_CFLAG_EXTRAS = @CURL_CFLAG_EXTRAS@ 209 | CURL_DISABLE_DICT = @CURL_DISABLE_DICT@ 210 | CURL_DISABLE_FILE = @CURL_DISABLE_FILE@ 211 | CURL_DISABLE_FTP = @CURL_DISABLE_FTP@ 212 | CURL_DISABLE_GOPHER = @CURL_DISABLE_GOPHER@ 213 | CURL_DISABLE_HTTP = @CURL_DISABLE_HTTP@ 214 | CURL_DISABLE_IMAP = @CURL_DISABLE_IMAP@ 215 | CURL_DISABLE_LDAP = @CURL_DISABLE_LDAP@ 216 | CURL_DISABLE_LDAPS = @CURL_DISABLE_LDAPS@ 217 | CURL_DISABLE_POP3 = @CURL_DISABLE_POP3@ 218 | CURL_DISABLE_PROXY = @CURL_DISABLE_PROXY@ 219 | CURL_DISABLE_RTSP = @CURL_DISABLE_RTSP@ 220 | CURL_DISABLE_SMB = @CURL_DISABLE_SMB@ 221 | CURL_DISABLE_SMTP = @CURL_DISABLE_SMTP@ 222 | CURL_DISABLE_TELNET = @CURL_DISABLE_TELNET@ 223 | CURL_DISABLE_TFTP = @CURL_DISABLE_TFTP@ 224 | CURL_LT_SHLIB_VERSIONED_FLAVOUR = @CURL_LT_SHLIB_VERSIONED_FLAVOUR@ 225 | CURL_NETWORK_AND_TIME_LIBS = @CURL_NETWORK_AND_TIME_LIBS@ 226 | CURL_NETWORK_LIBS = @CURL_NETWORK_LIBS@ 227 | CYGPATH_W = @CYGPATH_W@ 228 | DEFS = @DEFS@ 229 | DEPDIR = @DEPDIR@ 230 | DLLTOOL = @DLLTOOL@ 231 | DSYMUTIL = @DSYMUTIL@ 232 | DUMPBIN = @DUMPBIN@ 233 | ECHO_C = @ECHO_C@ 234 | ECHO_N = @ECHO_N@ 235 | ECHO_T = @ECHO_T@ 236 | EGREP = @EGREP@ 237 | ENABLE_SHARED = @ENABLE_SHARED@ 238 | ENABLE_STATIC = @ENABLE_STATIC@ 239 | EXEEXT = @EXEEXT@ 240 | FGREP = @FGREP@ 241 | GREP = @GREP@ 242 | HAVE_GNUTLS_SRP = @HAVE_GNUTLS_SRP@ 243 | HAVE_LDAP_SSL = @HAVE_LDAP_SSL@ 244 | HAVE_LIBZ = @HAVE_LIBZ@ 245 | HAVE_OPENSSL_SRP = @HAVE_OPENSSL_SRP@ 246 | IDN_ENABLED = @IDN_ENABLED@ 247 | INSTALL = @INSTALL@ 248 | INSTALL_DATA = @INSTALL_DATA@ 249 | INSTALL_PROGRAM = @INSTALL_PROGRAM@ 250 | INSTALL_SCRIPT = @INSTALL_SCRIPT@ 251 | INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ 252 | IPV6_ENABLED = @IPV6_ENABLED@ 253 | LD = @LD@ 254 | LDFLAGS = @LDFLAGS@ 255 | LIBCURL_LIBS = @LIBCURL_LIBS@ 256 | LIBMETALINK_CPPFLAGS = @LIBMETALINK_CPPFLAGS@ 257 | LIBMETALINK_LDFLAGS = @LIBMETALINK_LDFLAGS@ 258 | LIBMETALINK_LIBS = @LIBMETALINK_LIBS@ 259 | LIBOBJS = @LIBOBJS@ 260 | LIBS = @LIBS@ 261 | LIBTOOL = @LIBTOOL@ 262 | LIPO = @LIPO@ 263 | LN_S = @LN_S@ 264 | LTLIBOBJS = @LTLIBOBJS@ 265 | LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ 266 | MAINT = @MAINT@ 267 | MAKEINFO = @MAKEINFO@ 268 | MANIFEST_TOOL = @MANIFEST_TOOL@ 269 | MANOPT = @MANOPT@ 270 | MKDIR_P = @MKDIR_P@ 271 | NM = @NM@ 272 | NMEDIT = @NMEDIT@ 273 | NROFF = @NROFF@ 274 | NSS_LIBS = @NSS_LIBS@ 275 | OBJDUMP = @OBJDUMP@ 276 | OBJEXT = @OBJEXT@ 277 | OTOOL = @OTOOL@ 278 | OTOOL64 = @OTOOL64@ 279 | PACKAGE = @PACKAGE@ 280 | PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ 281 | PACKAGE_NAME = @PACKAGE_NAME@ 282 | PACKAGE_STRING = @PACKAGE_STRING@ 283 | PACKAGE_TARNAME = @PACKAGE_TARNAME@ 284 | PACKAGE_URL = @PACKAGE_URL@ 285 | PACKAGE_VERSION = @PACKAGE_VERSION@ 286 | PATH_SEPARATOR = @PATH_SEPARATOR@ 287 | PERL = @PERL@ 288 | PKGADD_NAME = @PKGADD_NAME@ 289 | PKGADD_PKG = @PKGADD_PKG@ 290 | PKGADD_VENDOR = @PKGADD_VENDOR@ 291 | PKGCONFIG = @PKGCONFIG@ 292 | RANDOM_FILE = @RANDOM_FILE@ 293 | RANLIB = @RANLIB@ 294 | REQUIRE_LIB_DEPS = @REQUIRE_LIB_DEPS@ 295 | SED = @SED@ 296 | SET_MAKE = @SET_MAKE@ 297 | SHELL = @SHELL@ 298 | SSL_ENABLED = @SSL_ENABLED@ 299 | SSL_LIBS = @SSL_LIBS@ 300 | STRIP = @STRIP@ 301 | SUPPORT_FEATURES = @SUPPORT_FEATURES@ 302 | SUPPORT_PROTOCOLS = @SUPPORT_PROTOCOLS@ 303 | USE_ARES = @USE_ARES@ 304 | USE_AXTLS = @USE_AXTLS@ 305 | USE_CYASSL = @USE_CYASSL@ 306 | USE_DARWINSSL = @USE_DARWINSSL@ 307 | USE_GNUTLS = @USE_GNUTLS@ 308 | USE_GNUTLS_NETTLE = @USE_GNUTLS_NETTLE@ 309 | USE_LIBRTMP = @USE_LIBRTMP@ 310 | USE_LIBSSH2 = @USE_LIBSSH2@ 311 | USE_MBEDTLS = @USE_MBEDTLS@ 312 | USE_NGHTTP2 = @USE_NGHTTP2@ 313 | USE_NSS = @USE_NSS@ 314 | USE_OPENLDAP = @USE_OPENLDAP@ 315 | USE_POLARSSL = @USE_POLARSSL@ 316 | USE_SCHANNEL = @USE_SCHANNEL@ 317 | USE_UNIX_SOCKETS = @USE_UNIX_SOCKETS@ 318 | USE_WINDOWS_SSPI = @USE_WINDOWS_SSPI@ 319 | VERSION = @VERSION@ 320 | VERSIONNUM = @VERSIONNUM@ 321 | ZLIB_LIBS = @ZLIB_LIBS@ 322 | ZSH_FUNCTIONS_DIR = @ZSH_FUNCTIONS_DIR@ 323 | abs_builddir = @abs_builddir@ 324 | abs_srcdir = @abs_srcdir@ 325 | abs_top_builddir = @abs_top_builddir@ 326 | abs_top_srcdir = @abs_top_srcdir@ 327 | ac_ct_AR = @ac_ct_AR@ 328 | ac_ct_CC = @ac_ct_CC@ 329 | ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ 330 | am__include = @am__include@ 331 | am__leading_dot = @am__leading_dot@ 332 | am__quote = @am__quote@ 333 | am__tar = @am__tar@ 334 | am__untar = @am__untar@ 335 | bindir = @bindir@ 336 | build = @build@ 337 | build_alias = @build_alias@ 338 | build_cpu = @build_cpu@ 339 | build_os = @build_os@ 340 | build_vendor = @build_vendor@ 341 | builddir = @builddir@ 342 | datadir = @datadir@ 343 | datarootdir = @datarootdir@ 344 | docdir = @docdir@ 345 | dvidir = @dvidir@ 346 | exec_prefix = @exec_prefix@ 347 | host = @host@ 348 | host_alias = @host_alias@ 349 | host_cpu = @host_cpu@ 350 | host_os = @host_os@ 351 | host_vendor = @host_vendor@ 352 | htmldir = @htmldir@ 353 | includedir = @includedir@ 354 | infodir = @infodir@ 355 | install_sh = @install_sh@ 356 | libdir = @libdir@ 357 | libexecdir = @libexecdir@ 358 | libext = @libext@ 359 | localedir = @localedir@ 360 | localstatedir = @localstatedir@ 361 | mandir = @mandir@ 362 | mkdir_p = @mkdir_p@ 363 | oldincludedir = @oldincludedir@ 364 | pdfdir = @pdfdir@ 365 | prefix = @prefix@ 366 | program_transform_name = @program_transform_name@ 367 | psdir = @psdir@ 368 | runstatedir = @runstatedir@ 369 | sbindir = @sbindir@ 370 | sharedstatedir = @sharedstatedir@ 371 | srcdir = @srcdir@ 372 | subdirs = @subdirs@ 373 | sysconfdir = @sysconfdir@ 374 | target_alias = @target_alias@ 375 | top_build_prefix = @top_build_prefix@ 376 | top_builddir = @top_builddir@ 377 | top_srcdir = @top_srcdir@ 378 | 379 | #*************************************************************************** 380 | # _ _ ____ _ 381 | # Project ___| | | | _ \| | 382 | # / __| | | | |_) | | 383 | # | (__| |_| | _ <| |___ 384 | # \___|\___/|_| \_\_____| 385 | # 386 | # Copyright (C) 1998 - 2011, Daniel Stenberg, , et al. 387 | # 388 | # This software is licensed as described in the file COPYING, which 389 | # you should have received as part of this distribution. The terms 390 | # are also available at https://curl.haxx.se/docs/copyright.html. 391 | # 392 | # You may opt to use, copy, modify, merge, publish, distribute and/or sell 393 | # copies of the Software, and permit persons to whom the Software is 394 | # furnished to do so, under the terms of the COPYING file. 395 | # 396 | # This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY 397 | # KIND, either express or implied. 398 | # 399 | ########################################################################### 400 | pkginclude_HEADERS = \ 401 | curl.h curlver.h easy.h mprintf.h stdcheaders.h multi.h \ 402 | typecheck-gcc.h curlbuild.h curlrules.h 403 | 404 | 405 | # curlbuild.h does not exist in the git tree. When the original libcurl 406 | # source code distribution archive file is created, curlbuild.h.dist is 407 | # renamed to curlbuild.h and included in the tarball so that it can be 408 | # used directly on non-configure systems. 409 | # 410 | # The distributed curlbuild.h will be overwritten on configure systems 411 | # when the configure script runs, with one that is suitable and specific 412 | # to the library being configured and built. 413 | # 414 | # curlbuild.h.in is the distributed template file from which the configure 415 | # script creates curlbuild.h at library configuration time, overwiting the 416 | # one included in the distribution archive. 417 | # 418 | # curlbuild.h.dist is not included in the source code distribution archive. 419 | EXTRA_DIST = curlbuild.h.in 420 | DISTCLEANFILES = curlbuild.h 421 | all: curlbuild.h 422 | $(MAKE) $(AM_MAKEFLAGS) all-am 423 | 424 | .SUFFIXES: 425 | $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) 426 | @for dep in $?; do \ 427 | case '$(am__configure_deps)' in \ 428 | *$$dep*) \ 429 | ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ 430 | && { if test -f $@; then exit 0; else break; fi; }; \ 431 | exit 1;; \ 432 | esac; \ 433 | done; \ 434 | echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu include/curl/Makefile'; \ 435 | $(am__cd) $(top_srcdir) && \ 436 | $(AUTOMAKE) --gnu include/curl/Makefile 437 | Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status 438 | @case '$?' in \ 439 | *config.status*) \ 440 | cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ 441 | *) \ 442 | echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ 443 | cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ 444 | esac; 445 | 446 | $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) 447 | cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh 448 | 449 | $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) 450 | cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh 451 | $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) 452 | cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh 453 | $(am__aclocal_m4_deps): 454 | 455 | curlbuild.h: stamp-h2 456 | @test -f $@ || rm -f stamp-h2 457 | @test -f $@ || $(MAKE) $(AM_MAKEFLAGS) stamp-h2 458 | 459 | stamp-h2: $(srcdir)/curlbuild.h.in $(top_builddir)/config.status 460 | @rm -f stamp-h2 461 | cd $(top_builddir) && $(SHELL) ./config.status include/curl/curlbuild.h 462 | 463 | distclean-hdr: 464 | -rm -f curlbuild.h stamp-h2 465 | 466 | mostlyclean-libtool: 467 | -rm -f *.lo 468 | 469 | clean-libtool: 470 | -rm -rf .libs _libs 471 | install-pkgincludeHEADERS: $(pkginclude_HEADERS) 472 | @$(NORMAL_INSTALL) 473 | @list='$(pkginclude_HEADERS)'; test -n "$(pkgincludedir)" || list=; \ 474 | if test -n "$$list"; then \ 475 | echo " $(MKDIR_P) '$(DESTDIR)$(pkgincludedir)'"; \ 476 | $(MKDIR_P) "$(DESTDIR)$(pkgincludedir)" || exit 1; \ 477 | fi; \ 478 | for p in $$list; do \ 479 | if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ 480 | echo "$$d$$p"; \ 481 | done | $(am__base_list) | \ 482 | while read files; do \ 483 | echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(pkgincludedir)'"; \ 484 | $(INSTALL_HEADER) $$files "$(DESTDIR)$(pkgincludedir)" || exit $$?; \ 485 | done 486 | 487 | uninstall-pkgincludeHEADERS: 488 | @$(NORMAL_UNINSTALL) 489 | @list='$(pkginclude_HEADERS)'; test -n "$(pkgincludedir)" || list=; \ 490 | files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ 491 | dir='$(DESTDIR)$(pkgincludedir)'; $(am__uninstall_files_from_dir) 492 | 493 | ID: $(am__tagged_files) 494 | $(am__define_uniq_tagged_files); mkid -fID $$unique 495 | tags: tags-am 496 | TAGS: tags 497 | 498 | tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) 499 | set x; \ 500 | here=`pwd`; \ 501 | $(am__define_uniq_tagged_files); \ 502 | shift; \ 503 | if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ 504 | test -n "$$unique" || unique=$$empty_fix; \ 505 | if test $$# -gt 0; then \ 506 | $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ 507 | "$$@" $$unique; \ 508 | else \ 509 | $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ 510 | $$unique; \ 511 | fi; \ 512 | fi 513 | ctags: ctags-am 514 | 515 | CTAGS: ctags 516 | ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) 517 | $(am__define_uniq_tagged_files); \ 518 | test -z "$(CTAGS_ARGS)$$unique" \ 519 | || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ 520 | $$unique 521 | 522 | GTAGS: 523 | here=`$(am__cd) $(top_builddir) && pwd` \ 524 | && $(am__cd) $(top_srcdir) \ 525 | && gtags -i $(GTAGS_ARGS) "$$here" 526 | cscopelist: cscopelist-am 527 | 528 | cscopelist-am: $(am__tagged_files) 529 | list='$(am__tagged_files)'; \ 530 | case "$(srcdir)" in \ 531 | [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ 532 | *) sdir=$(subdir)/$(srcdir) ;; \ 533 | esac; \ 534 | for i in $$list; do \ 535 | if test -f "$$i"; then \ 536 | echo "$(subdir)/$$i"; \ 537 | else \ 538 | echo "$$sdir/$$i"; \ 539 | fi; \ 540 | done >> $(top_builddir)/cscope.files 541 | 542 | distclean-tags: 543 | -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags 544 | 545 | distdir: $(DISTFILES) 546 | @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ 547 | topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ 548 | list='$(DISTFILES)'; \ 549 | dist_files=`for file in $$list; do echo $$file; done | \ 550 | sed -e "s|^$$srcdirstrip/||;t" \ 551 | -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ 552 | case $$dist_files in \ 553 | */*) $(MKDIR_P) `echo "$$dist_files" | \ 554 | sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ 555 | sort -u` ;; \ 556 | esac; \ 557 | for file in $$dist_files; do \ 558 | if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ 559 | if test -d $$d/$$file; then \ 560 | dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ 561 | if test -d "$(distdir)/$$file"; then \ 562 | find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ 563 | fi; \ 564 | if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ 565 | cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ 566 | find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ 567 | fi; \ 568 | cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ 569 | else \ 570 | test -f "$(distdir)/$$file" \ 571 | || cp -p $$d/$$file "$(distdir)/$$file" \ 572 | || exit 1; \ 573 | fi; \ 574 | done 575 | check-am: all-am 576 | check: check-am 577 | @CURLDEBUG_FALSE@all-local: 578 | all-am: Makefile $(HEADERS) curlbuild.h all-local 579 | installdirs: 580 | for dir in "$(DESTDIR)$(pkgincludedir)"; do \ 581 | test -z "$$dir" || $(MKDIR_P) "$$dir"; \ 582 | done 583 | install: install-am 584 | install-exec: install-exec-am 585 | install-data: install-data-am 586 | uninstall: uninstall-am 587 | 588 | install-am: all-am 589 | @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am 590 | 591 | installcheck: installcheck-am 592 | install-strip: 593 | if test -z '$(STRIP)'; then \ 594 | $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ 595 | install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ 596 | install; \ 597 | else \ 598 | $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ 599 | install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ 600 | "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ 601 | fi 602 | mostlyclean-generic: 603 | 604 | clean-generic: 605 | 606 | distclean-generic: 607 | -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) 608 | -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) 609 | -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES) 610 | 611 | maintainer-clean-generic: 612 | @echo "This command is intended for maintainers to use" 613 | @echo "it deletes files that may require special tools to rebuild." 614 | clean: clean-am 615 | 616 | clean-am: clean-generic clean-libtool mostlyclean-am 617 | 618 | distclean: distclean-am 619 | -rm -f Makefile 620 | distclean-am: clean-am distclean-generic distclean-hdr distclean-tags 621 | 622 | dvi: dvi-am 623 | 624 | dvi-am: 625 | 626 | html: html-am 627 | 628 | html-am: 629 | 630 | info: info-am 631 | 632 | info-am: 633 | 634 | install-data-am: install-pkgincludeHEADERS 635 | 636 | install-dvi: install-dvi-am 637 | 638 | install-dvi-am: 639 | 640 | install-exec-am: 641 | 642 | install-html: install-html-am 643 | 644 | install-html-am: 645 | 646 | install-info: install-info-am 647 | 648 | install-info-am: 649 | 650 | install-man: 651 | 652 | install-pdf: install-pdf-am 653 | 654 | install-pdf-am: 655 | 656 | install-ps: install-ps-am 657 | 658 | install-ps-am: 659 | 660 | installcheck-am: 661 | 662 | maintainer-clean: maintainer-clean-am 663 | -rm -f Makefile 664 | maintainer-clean-am: distclean-am maintainer-clean-generic 665 | 666 | mostlyclean: mostlyclean-am 667 | 668 | mostlyclean-am: mostlyclean-generic mostlyclean-libtool 669 | 670 | pdf: pdf-am 671 | 672 | pdf-am: 673 | 674 | ps: ps-am 675 | 676 | ps-am: 677 | 678 | uninstall-am: uninstall-pkgincludeHEADERS 679 | 680 | .MAKE: all install-am install-strip 681 | 682 | .PHONY: CTAGS GTAGS TAGS all all-am all-local check check-am clean \ 683 | clean-generic clean-libtool cscopelist-am ctags ctags-am \ 684 | distclean distclean-generic distclean-hdr distclean-libtool \ 685 | distclean-tags distdir dvi dvi-am html html-am info info-am \ 686 | install install-am install-data install-data-am install-dvi \ 687 | install-dvi-am install-exec install-exec-am install-html \ 688 | install-html-am install-info install-info-am install-man \ 689 | install-pdf install-pdf-am install-pkgincludeHEADERS \ 690 | install-ps install-ps-am install-strip installcheck \ 691 | installcheck-am installdirs maintainer-clean \ 692 | maintainer-clean-generic mostlyclean mostlyclean-generic \ 693 | mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \ 694 | uninstall-am uninstall-pkgincludeHEADERS 695 | 696 | .PRECIOUS: Makefile 697 | 698 | 699 | checksrc: 700 | @@PERL@ $(top_srcdir)/lib/checksrc.pl -Wcurlbuild.h -D$(top_srcdir)/include/curl $(pkginclude_HEADERS) $(EXTRA_DIST) 701 | 702 | # for debug builds, we scan the sources on all regular make invokes 703 | @CURLDEBUG_TRUE@all-local: checksrc 704 | 705 | # Tell versions [3.59,3.63) of GNU make to not export all variables. 706 | # Otherwise a system limit (for SysV at least) may be exceeded. 707 | .NOEXPORT: 708 | -------------------------------------------------------------------------------- /liburl/include/curl/curlbuild.h: -------------------------------------------------------------------------------- 1 | #ifndef __CURL_CURLBUILD_H 2 | #define __CURL_CURLBUILD_H 3 | /*************************************************************************** 4 | * _ _ ____ _ 5 | * Project ___| | | | _ \| | 6 | * / __| | | | |_) | | 7 | * | (__| |_| | _ <| |___ 8 | * \___|\___/|_| \_\_____| 9 | * 10 | * Copyright (C) 1998 - 2016, Daniel Stenberg, , et al. 11 | * 12 | * This software is licensed as described in the file COPYING, which 13 | * you should have received as part of this distribution. The terms 14 | * are also available at https://curl.haxx.se/docs/copyright.html. 15 | * 16 | * You may opt to use, copy, modify, merge, publish, distribute and/or sell 17 | * copies of the Software, and permit persons to whom the Software is 18 | * furnished to do so, under the terms of the COPYING file. 19 | * 20 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY 21 | * KIND, either express or implied. 22 | * 23 | ***************************************************************************/ 24 | 25 | /* ================================================================ */ 26 | /* NOTES FOR CONFIGURE CAPABLE SYSTEMS */ 27 | /* ================================================================ */ 28 | 29 | /* 30 | * NOTE 1: 31 | * ------- 32 | * 33 | * See file include/curl/curlbuild.h.in, run configure, and forget 34 | * that this file exists it is only used for non-configure systems. 35 | * But you can keep reading if you want ;-) 36 | * 37 | */ 38 | 39 | /* ================================================================ */ 40 | /* NOTES FOR NON-CONFIGURE SYSTEMS */ 41 | /* ================================================================ */ 42 | 43 | /* 44 | * NOTE 1: 45 | * ------- 46 | * 47 | * Nothing in this file is intended to be modified or adjusted by the 48 | * curl library user nor by the curl library builder. 49 | * 50 | * If you think that something actually needs to be changed, adjusted 51 | * or fixed in this file, then, report it on the libcurl development 52 | * mailing list: https://cool.haxx.se/mailman/listinfo/curl-library/ 53 | * 54 | * Try to keep one section per platform, compiler and architecture, 55 | * otherwise, if an existing section is reused for a different one and 56 | * later on the original is adjusted, probably the piggybacking one can 57 | * be adversely changed. 58 | * 59 | * In order to differentiate between platforms/compilers/architectures 60 | * use only compiler built in predefined preprocessor symbols. 61 | * 62 | * This header file shall only export symbols which are 'curl' or 'CURL' 63 | * prefixed, otherwise public name space would be polluted. 64 | * 65 | * NOTE 2: 66 | * ------- 67 | * 68 | * For any given platform/compiler curl_off_t must be typedef'ed to a 69 | * 64-bit wide signed integral data type. The width of this data type 70 | * must remain constant and independent of any possible large file 71 | * support settings. 72 | * 73 | * As an exception to the above, curl_off_t shall be typedef'ed to a 74 | * 32-bit wide signed integral data type if there is no 64-bit type. 75 | * 76 | * As a general rule, curl_off_t shall not be mapped to off_t. This 77 | * rule shall only be violated if off_t is the only 64-bit data type 78 | * available and the size of off_t is independent of large file support 79 | * settings. Keep your build on the safe side avoiding an off_t gating. 80 | * If you have a 64-bit off_t then take for sure that another 64-bit 81 | * data type exists, dig deeper and you will find it. 82 | * 83 | * NOTE 3: 84 | * ------- 85 | * 86 | * Right now you might be staring at file include/curl/curlbuild.h.dist or 87 | * at file include/curl/curlbuild.h, this is due to the following reason: 88 | * file include/curl/curlbuild.h.dist is renamed to include/curl/curlbuild.h 89 | * when the libcurl source code distribution archive file is created. 90 | * 91 | * File include/curl/curlbuild.h.dist is not included in the distribution 92 | * archive. File include/curl/curlbuild.h is not present in the git tree. 93 | * 94 | * The distributed include/curl/curlbuild.h file is only intended to be used 95 | * on systems which can not run the also distributed configure script. 96 | * 97 | * On systems capable of running the configure script, the configure process 98 | * will overwrite the distributed include/curl/curlbuild.h file with one that 99 | * is suitable and specific to the library being configured and built, which 100 | * is generated from the include/curl/curlbuild.h.in template file. 101 | * 102 | * If you check out from git on a non-configure platform, you must run the 103 | * appropriate buildconf* script to set up curlbuild.h and other local files. 104 | * 105 | */ 106 | 107 | /* ================================================================ */ 108 | /* DEFINITION OF THESE SYMBOLS SHALL NOT TAKE PLACE ANYWHERE ELSE */ 109 | /* ================================================================ */ 110 | 111 | #ifdef CURL_SIZEOF_LONG 112 | # error "CURL_SIZEOF_LONG shall not be defined except in curlbuild.h" 113 | Error Compilation_aborted_CURL_SIZEOF_LONG_already_defined 114 | #endif 115 | 116 | #ifdef CURL_TYPEOF_CURL_SOCKLEN_T 117 | # error "CURL_TYPEOF_CURL_SOCKLEN_T shall not be defined except in curlbuild.h" 118 | Error Compilation_aborted_CURL_TYPEOF_CURL_SOCKLEN_T_already_defined 119 | #endif 120 | 121 | #ifdef CURL_SIZEOF_CURL_SOCKLEN_T 122 | # error "CURL_SIZEOF_CURL_SOCKLEN_T shall not be defined except in curlbuild.h" 123 | Error Compilation_aborted_CURL_SIZEOF_CURL_SOCKLEN_T_already_defined 124 | #endif 125 | 126 | #ifdef CURL_TYPEOF_CURL_OFF_T 127 | # error "CURL_TYPEOF_CURL_OFF_T shall not be defined except in curlbuild.h" 128 | Error Compilation_aborted_CURL_TYPEOF_CURL_OFF_T_already_defined 129 | #endif 130 | 131 | #ifdef CURL_FORMAT_CURL_OFF_T 132 | # error "CURL_FORMAT_CURL_OFF_T shall not be defined except in curlbuild.h" 133 | Error Compilation_aborted_CURL_FORMAT_CURL_OFF_T_already_defined 134 | #endif 135 | 136 | #ifdef CURL_FORMAT_CURL_OFF_TU 137 | # error "CURL_FORMAT_CURL_OFF_TU shall not be defined except in curlbuild.h" 138 | Error Compilation_aborted_CURL_FORMAT_CURL_OFF_TU_already_defined 139 | #endif 140 | 141 | #ifdef CURL_FORMAT_OFF_T 142 | # error "CURL_FORMAT_OFF_T shall not be defined except in curlbuild.h" 143 | Error Compilation_aborted_CURL_FORMAT_OFF_T_already_defined 144 | #endif 145 | 146 | #ifdef CURL_SIZEOF_CURL_OFF_T 147 | # error "CURL_SIZEOF_CURL_OFF_T shall not be defined except in curlbuild.h" 148 | Error Compilation_aborted_CURL_SIZEOF_CURL_OFF_T_already_defined 149 | #endif 150 | 151 | #ifdef CURL_SUFFIX_CURL_OFF_T 152 | # error "CURL_SUFFIX_CURL_OFF_T shall not be defined except in curlbuild.h" 153 | Error Compilation_aborted_CURL_SUFFIX_CURL_OFF_T_already_defined 154 | #endif 155 | 156 | #ifdef CURL_SUFFIX_CURL_OFF_TU 157 | # error "CURL_SUFFIX_CURL_OFF_TU shall not be defined except in curlbuild.h" 158 | Error Compilation_aborted_CURL_SUFFIX_CURL_OFF_TU_already_defined 159 | #endif 160 | 161 | /* ================================================================ */ 162 | /* EXTERNAL INTERFACE SETTINGS FOR NON-CONFIGURE SYSTEMS ONLY */ 163 | /* ================================================================ */ 164 | 165 | #if defined(__DJGPP__) || defined(__GO32__) 166 | # if defined(__DJGPP__) && (__DJGPP__ > 1) 167 | # define CURL_SIZEOF_LONG 4 168 | # define CURL_TYPEOF_CURL_OFF_T long long 169 | # define CURL_FORMAT_CURL_OFF_T "lld" 170 | # define CURL_FORMAT_CURL_OFF_TU "llu" 171 | # define CURL_FORMAT_OFF_T "%lld" 172 | # define CURL_SIZEOF_CURL_OFF_T 8 173 | # define CURL_SUFFIX_CURL_OFF_T LL 174 | # define CURL_SUFFIX_CURL_OFF_TU ULL 175 | # else 176 | # define CURL_SIZEOF_LONG 4 177 | # define CURL_TYPEOF_CURL_OFF_T long 178 | # define CURL_FORMAT_CURL_OFF_T "ld" 179 | # define CURL_FORMAT_CURL_OFF_TU "lu" 180 | # define CURL_FORMAT_OFF_T "%ld" 181 | # define CURL_SIZEOF_CURL_OFF_T 4 182 | # define CURL_SUFFIX_CURL_OFF_T L 183 | # define CURL_SUFFIX_CURL_OFF_TU UL 184 | # endif 185 | # define CURL_TYPEOF_CURL_SOCKLEN_T int 186 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 187 | 188 | #elif defined(__SALFORDC__) 189 | # define CURL_SIZEOF_LONG 4 190 | # define CURL_TYPEOF_CURL_OFF_T long 191 | # define CURL_FORMAT_CURL_OFF_T "ld" 192 | # define CURL_FORMAT_CURL_OFF_TU "lu" 193 | # define CURL_FORMAT_OFF_T "%ld" 194 | # define CURL_SIZEOF_CURL_OFF_T 4 195 | # define CURL_SUFFIX_CURL_OFF_T L 196 | # define CURL_SUFFIX_CURL_OFF_TU UL 197 | # define CURL_TYPEOF_CURL_SOCKLEN_T int 198 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 199 | 200 | #elif defined(__BORLANDC__) 201 | # if (__BORLANDC__ < 0x520) 202 | # define CURL_SIZEOF_LONG 4 203 | # define CURL_TYPEOF_CURL_OFF_T long 204 | # define CURL_FORMAT_CURL_OFF_T "ld" 205 | # define CURL_FORMAT_CURL_OFF_TU "lu" 206 | # define CURL_FORMAT_OFF_T "%ld" 207 | # define CURL_SIZEOF_CURL_OFF_T 4 208 | # define CURL_SUFFIX_CURL_OFF_T L 209 | # define CURL_SUFFIX_CURL_OFF_TU UL 210 | # else 211 | # define CURL_SIZEOF_LONG 4 212 | # define CURL_TYPEOF_CURL_OFF_T __int64 213 | # define CURL_FORMAT_CURL_OFF_T "I64d" 214 | # define CURL_FORMAT_CURL_OFF_TU "I64u" 215 | # define CURL_FORMAT_OFF_T "%I64d" 216 | # define CURL_SIZEOF_CURL_OFF_T 8 217 | # define CURL_SUFFIX_CURL_OFF_T i64 218 | # define CURL_SUFFIX_CURL_OFF_TU ui64 219 | # endif 220 | # define CURL_TYPEOF_CURL_SOCKLEN_T int 221 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 222 | 223 | #elif defined(__TURBOC__) 224 | # define CURL_SIZEOF_LONG 4 225 | # define CURL_TYPEOF_CURL_OFF_T long 226 | # define CURL_FORMAT_CURL_OFF_T "ld" 227 | # define CURL_FORMAT_CURL_OFF_TU "lu" 228 | # define CURL_FORMAT_OFF_T "%ld" 229 | # define CURL_SIZEOF_CURL_OFF_T 4 230 | # define CURL_SUFFIX_CURL_OFF_T L 231 | # define CURL_SUFFIX_CURL_OFF_TU UL 232 | # define CURL_TYPEOF_CURL_SOCKLEN_T int 233 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 234 | 235 | #elif defined(__WATCOMC__) 236 | # if defined(__386__) 237 | # define CURL_SIZEOF_LONG 4 238 | # define CURL_TYPEOF_CURL_OFF_T __int64 239 | # define CURL_FORMAT_CURL_OFF_T "I64d" 240 | # define CURL_FORMAT_CURL_OFF_TU "I64u" 241 | # define CURL_FORMAT_OFF_T "%I64d" 242 | # define CURL_SIZEOF_CURL_OFF_T 8 243 | # define CURL_SUFFIX_CURL_OFF_T i64 244 | # define CURL_SUFFIX_CURL_OFF_TU ui64 245 | # else 246 | # define CURL_SIZEOF_LONG 4 247 | # define CURL_TYPEOF_CURL_OFF_T long 248 | # define CURL_FORMAT_CURL_OFF_T "ld" 249 | # define CURL_FORMAT_CURL_OFF_TU "lu" 250 | # define CURL_FORMAT_OFF_T "%ld" 251 | # define CURL_SIZEOF_CURL_OFF_T 4 252 | # define CURL_SUFFIX_CURL_OFF_T L 253 | # define CURL_SUFFIX_CURL_OFF_TU UL 254 | # endif 255 | # define CURL_TYPEOF_CURL_SOCKLEN_T int 256 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 257 | 258 | #elif defined(__POCC__) 259 | # if (__POCC__ < 280) 260 | # define CURL_SIZEOF_LONG 4 261 | # define CURL_TYPEOF_CURL_OFF_T long 262 | # define CURL_FORMAT_CURL_OFF_T "ld" 263 | # define CURL_FORMAT_CURL_OFF_TU "lu" 264 | # define CURL_FORMAT_OFF_T "%ld" 265 | # define CURL_SIZEOF_CURL_OFF_T 4 266 | # define CURL_SUFFIX_CURL_OFF_T L 267 | # define CURL_SUFFIX_CURL_OFF_TU UL 268 | # elif defined(_MSC_VER) 269 | # define CURL_SIZEOF_LONG 4 270 | # define CURL_TYPEOF_CURL_OFF_T __int64 271 | # define CURL_FORMAT_CURL_OFF_T "I64d" 272 | # define CURL_FORMAT_CURL_OFF_TU "I64u" 273 | # define CURL_FORMAT_OFF_T "%I64d" 274 | # define CURL_SIZEOF_CURL_OFF_T 8 275 | # define CURL_SUFFIX_CURL_OFF_T i64 276 | # define CURL_SUFFIX_CURL_OFF_TU ui64 277 | # else 278 | # define CURL_SIZEOF_LONG 4 279 | # define CURL_TYPEOF_CURL_OFF_T long long 280 | # define CURL_FORMAT_CURL_OFF_T "lld" 281 | # define CURL_FORMAT_CURL_OFF_TU "llu" 282 | # define CURL_FORMAT_OFF_T "%lld" 283 | # define CURL_SIZEOF_CURL_OFF_T 8 284 | # define CURL_SUFFIX_CURL_OFF_T LL 285 | # define CURL_SUFFIX_CURL_OFF_TU ULL 286 | # endif 287 | # define CURL_TYPEOF_CURL_SOCKLEN_T int 288 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 289 | 290 | #elif defined(__LCC__) 291 | # define CURL_SIZEOF_LONG 4 292 | # define CURL_TYPEOF_CURL_OFF_T long 293 | # define CURL_FORMAT_CURL_OFF_T "ld" 294 | # define CURL_FORMAT_CURL_OFF_TU "lu" 295 | # define CURL_FORMAT_OFF_T "%ld" 296 | # define CURL_SIZEOF_CURL_OFF_T 4 297 | # define CURL_SUFFIX_CURL_OFF_T L 298 | # define CURL_SUFFIX_CURL_OFF_TU UL 299 | # define CURL_TYPEOF_CURL_SOCKLEN_T int 300 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 301 | 302 | #elif defined(__SYMBIAN32__) 303 | # if defined(__EABI__) /* Treat all ARM compilers equally */ 304 | # define CURL_SIZEOF_LONG 4 305 | # define CURL_TYPEOF_CURL_OFF_T long long 306 | # define CURL_FORMAT_CURL_OFF_T "lld" 307 | # define CURL_FORMAT_CURL_OFF_TU "llu" 308 | # define CURL_FORMAT_OFF_T "%lld" 309 | # define CURL_SIZEOF_CURL_OFF_T 8 310 | # define CURL_SUFFIX_CURL_OFF_T LL 311 | # define CURL_SUFFIX_CURL_OFF_TU ULL 312 | # elif defined(__CW32__) 313 | # pragma longlong on 314 | # define CURL_SIZEOF_LONG 4 315 | # define CURL_TYPEOF_CURL_OFF_T long long 316 | # define CURL_FORMAT_CURL_OFF_T "lld" 317 | # define CURL_FORMAT_CURL_OFF_TU "llu" 318 | # define CURL_FORMAT_OFF_T "%lld" 319 | # define CURL_SIZEOF_CURL_OFF_T 8 320 | # define CURL_SUFFIX_CURL_OFF_T LL 321 | # define CURL_SUFFIX_CURL_OFF_TU ULL 322 | # elif defined(__VC32__) 323 | # define CURL_SIZEOF_LONG 4 324 | # define CURL_TYPEOF_CURL_OFF_T __int64 325 | # define CURL_FORMAT_CURL_OFF_T "lld" 326 | # define CURL_FORMAT_CURL_OFF_TU "llu" 327 | # define CURL_FORMAT_OFF_T "%lld" 328 | # define CURL_SIZEOF_CURL_OFF_T 8 329 | # define CURL_SUFFIX_CURL_OFF_T LL 330 | # define CURL_SUFFIX_CURL_OFF_TU ULL 331 | # endif 332 | # define CURL_TYPEOF_CURL_SOCKLEN_T unsigned int 333 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 334 | 335 | #elif defined(__MWERKS__) 336 | # define CURL_SIZEOF_LONG 4 337 | # define CURL_TYPEOF_CURL_OFF_T long long 338 | # define CURL_FORMAT_CURL_OFF_T "lld" 339 | # define CURL_FORMAT_CURL_OFF_TU "llu" 340 | # define CURL_FORMAT_OFF_T "%lld" 341 | # define CURL_SIZEOF_CURL_OFF_T 8 342 | # define CURL_SUFFIX_CURL_OFF_T LL 343 | # define CURL_SUFFIX_CURL_OFF_TU ULL 344 | # define CURL_TYPEOF_CURL_SOCKLEN_T int 345 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 346 | 347 | #elif defined(_WIN32_WCE) 348 | # define CURL_SIZEOF_LONG 4 349 | # define CURL_TYPEOF_CURL_OFF_T __int64 350 | # define CURL_FORMAT_CURL_OFF_T "I64d" 351 | # define CURL_FORMAT_CURL_OFF_TU "I64u" 352 | # define CURL_FORMAT_OFF_T "%I64d" 353 | # define CURL_SIZEOF_CURL_OFF_T 8 354 | # define CURL_SUFFIX_CURL_OFF_T i64 355 | # define CURL_SUFFIX_CURL_OFF_TU ui64 356 | # define CURL_TYPEOF_CURL_SOCKLEN_T int 357 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 358 | 359 | #elif defined(__MINGW32__) 360 | # define CURL_SIZEOF_LONG 4 361 | # define CURL_TYPEOF_CURL_OFF_T long long 362 | # define CURL_FORMAT_CURL_OFF_T "I64d" 363 | # define CURL_FORMAT_CURL_OFF_TU "I64u" 364 | # define CURL_FORMAT_OFF_T "%I64d" 365 | # define CURL_SIZEOF_CURL_OFF_T 8 366 | # define CURL_SUFFIX_CURL_OFF_T LL 367 | # define CURL_SUFFIX_CURL_OFF_TU ULL 368 | # define CURL_TYPEOF_CURL_SOCKLEN_T int 369 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 370 | 371 | #elif defined(__VMS) 372 | # if defined(__VAX) 373 | # define CURL_SIZEOF_LONG 4 374 | # define CURL_TYPEOF_CURL_OFF_T long 375 | # define CURL_FORMAT_CURL_OFF_T "ld" 376 | # define CURL_FORMAT_CURL_OFF_TU "lu" 377 | # define CURL_FORMAT_OFF_T "%ld" 378 | # define CURL_SIZEOF_CURL_OFF_T 4 379 | # define CURL_SUFFIX_CURL_OFF_T L 380 | # define CURL_SUFFIX_CURL_OFF_TU UL 381 | # else 382 | # define CURL_SIZEOF_LONG 4 383 | # define CURL_TYPEOF_CURL_OFF_T long long 384 | # define CURL_FORMAT_CURL_OFF_T "lld" 385 | # define CURL_FORMAT_CURL_OFF_TU "llu" 386 | # define CURL_FORMAT_OFF_T "%lld" 387 | # define CURL_SIZEOF_CURL_OFF_T 8 388 | # define CURL_SUFFIX_CURL_OFF_T LL 389 | # define CURL_SUFFIX_CURL_OFF_TU ULL 390 | # endif 391 | # define CURL_TYPEOF_CURL_SOCKLEN_T unsigned int 392 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 393 | 394 | #elif defined(__OS400__) 395 | # if defined(__ILEC400__) 396 | # define CURL_SIZEOF_LONG 4 397 | # define CURL_TYPEOF_CURL_OFF_T long long 398 | # define CURL_FORMAT_CURL_OFF_T "lld" 399 | # define CURL_FORMAT_CURL_OFF_TU "llu" 400 | # define CURL_FORMAT_OFF_T "%lld" 401 | # define CURL_SIZEOF_CURL_OFF_T 8 402 | # define CURL_SUFFIX_CURL_OFF_T LL 403 | # define CURL_SUFFIX_CURL_OFF_TU ULL 404 | # define CURL_TYPEOF_CURL_SOCKLEN_T socklen_t 405 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 406 | # define CURL_PULL_SYS_TYPES_H 1 407 | # define CURL_PULL_SYS_SOCKET_H 1 408 | # endif 409 | 410 | #elif defined(__MVS__) 411 | # if defined(__IBMC__) || defined(__IBMCPP__) 412 | # if defined(_ILP32) 413 | # define CURL_SIZEOF_LONG 4 414 | # elif defined(_LP64) 415 | # define CURL_SIZEOF_LONG 8 416 | # endif 417 | # if defined(_LONG_LONG) 418 | # define CURL_TYPEOF_CURL_OFF_T long long 419 | # define CURL_FORMAT_CURL_OFF_T "lld" 420 | # define CURL_FORMAT_CURL_OFF_TU "llu" 421 | # define CURL_FORMAT_OFF_T "%lld" 422 | # define CURL_SIZEOF_CURL_OFF_T 8 423 | # define CURL_SUFFIX_CURL_OFF_T LL 424 | # define CURL_SUFFIX_CURL_OFF_TU ULL 425 | # elif defined(_LP64) 426 | # define CURL_TYPEOF_CURL_OFF_T long 427 | # define CURL_FORMAT_CURL_OFF_T "ld" 428 | # define CURL_FORMAT_CURL_OFF_TU "lu" 429 | # define CURL_FORMAT_OFF_T "%ld" 430 | # define CURL_SIZEOF_CURL_OFF_T 8 431 | # define CURL_SUFFIX_CURL_OFF_T L 432 | # define CURL_SUFFIX_CURL_OFF_TU UL 433 | # else 434 | # define CURL_TYPEOF_CURL_OFF_T long 435 | # define CURL_FORMAT_CURL_OFF_T "ld" 436 | # define CURL_FORMAT_CURL_OFF_TU "lu" 437 | # define CURL_FORMAT_OFF_T "%ld" 438 | # define CURL_SIZEOF_CURL_OFF_T 4 439 | # define CURL_SUFFIX_CURL_OFF_T L 440 | # define CURL_SUFFIX_CURL_OFF_TU UL 441 | # endif 442 | # define CURL_TYPEOF_CURL_SOCKLEN_T socklen_t 443 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 444 | # define CURL_PULL_SYS_TYPES_H 1 445 | # define CURL_PULL_SYS_SOCKET_H 1 446 | # endif 447 | 448 | #elif defined(__370__) 449 | # if defined(__IBMC__) || defined(__IBMCPP__) 450 | # if defined(_ILP32) 451 | # define CURL_SIZEOF_LONG 4 452 | # elif defined(_LP64) 453 | # define CURL_SIZEOF_LONG 8 454 | # endif 455 | # if defined(_LONG_LONG) 456 | # define CURL_TYPEOF_CURL_OFF_T long long 457 | # define CURL_FORMAT_CURL_OFF_T "lld" 458 | # define CURL_FORMAT_CURL_OFF_TU "llu" 459 | # define CURL_FORMAT_OFF_T "%lld" 460 | # define CURL_SIZEOF_CURL_OFF_T 8 461 | # define CURL_SUFFIX_CURL_OFF_T LL 462 | # define CURL_SUFFIX_CURL_OFF_TU ULL 463 | # elif defined(_LP64) 464 | # define CURL_TYPEOF_CURL_OFF_T long 465 | # define CURL_FORMAT_CURL_OFF_T "ld" 466 | # define CURL_FORMAT_CURL_OFF_TU "lu" 467 | # define CURL_FORMAT_OFF_T "%ld" 468 | # define CURL_SIZEOF_CURL_OFF_T 8 469 | # define CURL_SUFFIX_CURL_OFF_T L 470 | # define CURL_SUFFIX_CURL_OFF_TU UL 471 | # else 472 | # define CURL_TYPEOF_CURL_OFF_T long 473 | # define CURL_FORMAT_CURL_OFF_T "ld" 474 | # define CURL_FORMAT_CURL_OFF_TU "lu" 475 | # define CURL_FORMAT_OFF_T "%ld" 476 | # define CURL_SIZEOF_CURL_OFF_T 4 477 | # define CURL_SUFFIX_CURL_OFF_T L 478 | # define CURL_SUFFIX_CURL_OFF_TU UL 479 | # endif 480 | # define CURL_TYPEOF_CURL_SOCKLEN_T socklen_t 481 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 482 | # define CURL_PULL_SYS_TYPES_H 1 483 | # define CURL_PULL_SYS_SOCKET_H 1 484 | # endif 485 | 486 | #elif defined(TPF) 487 | # define CURL_SIZEOF_LONG 8 488 | # define CURL_TYPEOF_CURL_OFF_T long 489 | # define CURL_FORMAT_CURL_OFF_T "ld" 490 | # define CURL_FORMAT_CURL_OFF_TU "lu" 491 | # define CURL_FORMAT_OFF_T "%ld" 492 | # define CURL_SIZEOF_CURL_OFF_T 8 493 | # define CURL_SUFFIX_CURL_OFF_T L 494 | # define CURL_SUFFIX_CURL_OFF_TU UL 495 | # define CURL_TYPEOF_CURL_SOCKLEN_T int 496 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 497 | 498 | /* ===================================== */ 499 | /* KEEP MSVC THE PENULTIMATE ENTRY */ 500 | /* ===================================== */ 501 | 502 | #elif defined(_MSC_VER) 503 | # if (_MSC_VER >= 900) && (_INTEGRAL_MAX_BITS >= 64) 504 | # define CURL_SIZEOF_LONG 4 505 | # define CURL_TYPEOF_CURL_OFF_T __int64 506 | # define CURL_FORMAT_CURL_OFF_T "I64d" 507 | # define CURL_FORMAT_CURL_OFF_TU "I64u" 508 | # define CURL_FORMAT_OFF_T "%I64d" 509 | # define CURL_SIZEOF_CURL_OFF_T 8 510 | # define CURL_SUFFIX_CURL_OFF_T i64 511 | # define CURL_SUFFIX_CURL_OFF_TU ui64 512 | # else 513 | # define CURL_SIZEOF_LONG 4 514 | # define CURL_TYPEOF_CURL_OFF_T long 515 | # define CURL_FORMAT_CURL_OFF_T "ld" 516 | # define CURL_FORMAT_CURL_OFF_TU "lu" 517 | # define CURL_FORMAT_OFF_T "%ld" 518 | # define CURL_SIZEOF_CURL_OFF_T 4 519 | # define CURL_SUFFIX_CURL_OFF_T L 520 | # define CURL_SUFFIX_CURL_OFF_TU UL 521 | # endif 522 | # define CURL_TYPEOF_CURL_SOCKLEN_T int 523 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 524 | 525 | /* ===================================== */ 526 | /* KEEP GENERIC GCC THE LAST ENTRY */ 527 | /* ===================================== */ 528 | 529 | #elif defined(__GNUC__) 530 | # if !defined(__LP64__) && (defined(__ILP32__) || \ 531 | defined(__i386__) || defined(__ppc__) || defined(__arm__) || \ 532 | defined(__sparc__) || defined(__mips__) || defined(__sh__)) 533 | # define CURL_SIZEOF_LONG 4 534 | # define CURL_TYPEOF_CURL_OFF_T long long 535 | # define CURL_FORMAT_CURL_OFF_T "lld" 536 | # define CURL_FORMAT_CURL_OFF_TU "llu" 537 | # define CURL_FORMAT_OFF_T "%lld" 538 | # define CURL_SIZEOF_CURL_OFF_T 8 539 | # define CURL_SUFFIX_CURL_OFF_T LL 540 | # define CURL_SUFFIX_CURL_OFF_TU ULL 541 | # elif defined(__LP64__) || \ 542 | defined(__x86_64__) || defined(__ppc64__) || defined(__sparc64__) 543 | # define CURL_SIZEOF_LONG 8 544 | # define CURL_TYPEOF_CURL_OFF_T long 545 | # define CURL_FORMAT_CURL_OFF_T "ld" 546 | # define CURL_FORMAT_CURL_OFF_TU "lu" 547 | # define CURL_FORMAT_OFF_T "%ld" 548 | # define CURL_SIZEOF_CURL_OFF_T 8 549 | # define CURL_SUFFIX_CURL_OFF_T L 550 | # define CURL_SUFFIX_CURL_OFF_TU UL 551 | # endif 552 | # define CURL_TYPEOF_CURL_SOCKLEN_T socklen_t 553 | # define CURL_SIZEOF_CURL_SOCKLEN_T 4 554 | # define CURL_PULL_SYS_TYPES_H 1 555 | # define CURL_PULL_SYS_SOCKET_H 1 556 | 557 | #else 558 | # error "Unknown non-configure build target!" 559 | Error Compilation_aborted_Unknown_non_configure_build_target 560 | #endif 561 | 562 | /* CURL_PULL_SYS_TYPES_H is defined above when inclusion of header file */ 563 | /* sys/types.h is required here to properly make type definitions below. */ 564 | #ifdef CURL_PULL_SYS_TYPES_H 565 | # include 566 | #endif 567 | 568 | /* CURL_PULL_SYS_SOCKET_H is defined above when inclusion of header file */ 569 | /* sys/socket.h is required here to properly make type definitions below. */ 570 | #ifdef CURL_PULL_SYS_SOCKET_H 571 | # include 572 | #endif 573 | 574 | /* Data type definition of curl_socklen_t. */ 575 | 576 | #ifdef CURL_TYPEOF_CURL_SOCKLEN_T 577 | typedef CURL_TYPEOF_CURL_SOCKLEN_T curl_socklen_t; 578 | #endif 579 | 580 | /* Data type definition of curl_off_t. */ 581 | 582 | #ifdef CURL_TYPEOF_CURL_OFF_T 583 | typedef CURL_TYPEOF_CURL_OFF_T curl_off_t; 584 | #endif 585 | 586 | #endif /* __CURL_CURLBUILD_H */ 587 | -------------------------------------------------------------------------------- /liburl/include/curl/curlbuild.h.cmake: -------------------------------------------------------------------------------- 1 | #ifndef __CURL_CURLBUILD_H 2 | #define __CURL_CURLBUILD_H 3 | /*************************************************************************** 4 | * _ _ ____ _ 5 | * Project ___| | | | _ \| | 6 | * / __| | | | |_) | | 7 | * | (__| |_| | _ <| |___ 8 | * \___|\___/|_| \_\_____| 9 | * 10 | * Copyright (C) 1998 - 2008, Daniel Stenberg, , et al. 11 | * 12 | * This software is licensed as described in the file COPYING, which 13 | * you should have received as part of this distribution. The terms 14 | * are also available at https://curl.haxx.se/docs/copyright.html. 15 | * 16 | * You may opt to use, copy, modify, merge, publish, distribute and/or sell 17 | * copies of the Software, and permit persons to whom the Software is 18 | * furnished to do so, under the terms of the COPYING file. 19 | * 20 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY 21 | * KIND, either express or implied. 22 | * 23 | ***************************************************************************/ 24 | 25 | /* ================================================================ */ 26 | /* NOTES FOR CONFIGURE CAPABLE SYSTEMS */ 27 | /* ================================================================ */ 28 | 29 | /* 30 | * NOTE 1: 31 | * ------- 32 | * 33 | * Nothing in this file is intended to be modified or adjusted by the 34 | * curl library user nor by the curl library builder. 35 | * 36 | * If you think that something actually needs to be changed, adjusted 37 | * or fixed in this file, then, report it on the libcurl development 38 | * mailing list: https://cool.haxx.se/mailman/listinfo/curl-library/ 39 | * 40 | * This header file shall only export symbols which are 'curl' or 'CURL' 41 | * prefixed, otherwise public name space would be polluted. 42 | * 43 | * NOTE 2: 44 | * ------- 45 | * 46 | * Right now you might be staring at file include/curl/curlbuild.h.in or 47 | * at file include/curl/curlbuild.h, this is due to the following reason: 48 | * 49 | * On systems capable of running the configure script, the configure process 50 | * will overwrite the distributed include/curl/curlbuild.h file with one that 51 | * is suitable and specific to the library being configured and built, which 52 | * is generated from the include/curl/curlbuild.h.in template file. 53 | * 54 | */ 55 | 56 | /* ================================================================ */ 57 | /* DEFINITION OF THESE SYMBOLS SHALL NOT TAKE PLACE ANYWHERE ELSE */ 58 | /* ================================================================ */ 59 | 60 | #ifdef CURL_SIZEOF_LONG 61 | #error "CURL_SIZEOF_LONG shall not be defined except in curlbuild.h" 62 | Error Compilation_aborted_CURL_SIZEOF_LONG_already_defined 63 | #endif 64 | 65 | #ifdef CURL_TYPEOF_CURL_SOCKLEN_T 66 | #error "CURL_TYPEOF_CURL_SOCKLEN_T shall not be defined except in curlbuild.h" 67 | Error Compilation_aborted_CURL_TYPEOF_CURL_SOCKLEN_T_already_defined 68 | #endif 69 | 70 | #ifdef CURL_SIZEOF_CURL_SOCKLEN_T 71 | #error "CURL_SIZEOF_CURL_SOCKLEN_T shall not be defined except in curlbuild.h" 72 | Error Compilation_aborted_CURL_SIZEOF_CURL_SOCKLEN_T_already_defined 73 | #endif 74 | 75 | #ifdef CURL_TYPEOF_CURL_OFF_T 76 | #error "CURL_TYPEOF_CURL_OFF_T shall not be defined except in curlbuild.h" 77 | Error Compilation_aborted_CURL_TYPEOF_CURL_OFF_T_already_defined 78 | #endif 79 | 80 | #ifdef CURL_FORMAT_CURL_OFF_T 81 | #error "CURL_FORMAT_CURL_OFF_T shall not be defined except in curlbuild.h" 82 | Error Compilation_aborted_CURL_FORMAT_CURL_OFF_T_already_defined 83 | #endif 84 | 85 | #ifdef CURL_FORMAT_CURL_OFF_TU 86 | #error "CURL_FORMAT_CURL_OFF_TU shall not be defined except in curlbuild.h" 87 | Error Compilation_aborted_CURL_FORMAT_CURL_OFF_TU_already_defined 88 | #endif 89 | 90 | #ifdef CURL_FORMAT_OFF_T 91 | #error "CURL_FORMAT_OFF_T shall not be defined except in curlbuild.h" 92 | Error Compilation_aborted_CURL_FORMAT_OFF_T_already_defined 93 | #endif 94 | 95 | #ifdef CURL_SIZEOF_CURL_OFF_T 96 | #error "CURL_SIZEOF_CURL_OFF_T shall not be defined except in curlbuild.h" 97 | Error Compilation_aborted_CURL_SIZEOF_CURL_OFF_T_already_defined 98 | #endif 99 | 100 | #ifdef CURL_SUFFIX_CURL_OFF_T 101 | #error "CURL_SUFFIX_CURL_OFF_T shall not be defined except in curlbuild.h" 102 | Error Compilation_aborted_CURL_SUFFIX_CURL_OFF_T_already_defined 103 | #endif 104 | 105 | #ifdef CURL_SUFFIX_CURL_OFF_TU 106 | #error "CURL_SUFFIX_CURL_OFF_TU shall not be defined except in curlbuild.h" 107 | Error Compilation_aborted_CURL_SUFFIX_CURL_OFF_TU_already_defined 108 | #endif 109 | 110 | /* ================================================================ */ 111 | /* EXTERNAL INTERFACE SETTINGS FOR CONFIGURE CAPABLE SYSTEMS ONLY */ 112 | /* ================================================================ */ 113 | 114 | /* Configure process defines this to 1 when it finds out that system */ 115 | /* header file ws2tcpip.h must be included by the external interface. */ 116 | #cmakedefine CURL_PULL_WS2TCPIP_H 117 | #ifdef CURL_PULL_WS2TCPIP_H 118 | # ifndef WIN32_LEAN_AND_MEAN 119 | # define WIN32_LEAN_AND_MEAN 120 | # endif 121 | # include 122 | # include 123 | # include 124 | #endif 125 | 126 | /* Configure process defines this to 1 when it finds out that system */ 127 | /* header file sys/types.h must be included by the external interface. */ 128 | #cmakedefine CURL_PULL_SYS_TYPES_H 129 | #ifdef CURL_PULL_SYS_TYPES_H 130 | # include 131 | #endif 132 | 133 | /* Configure process defines this to 1 when it finds out that system */ 134 | /* header file stdint.h must be included by the external interface. */ 135 | #cmakedefine CURL_PULL_STDINT_H 136 | #ifdef CURL_PULL_STDINT_H 137 | # include 138 | #endif 139 | 140 | /* Configure process defines this to 1 when it finds out that system */ 141 | /* header file inttypes.h must be included by the external interface. */ 142 | #cmakedefine CURL_PULL_INTTYPES_H 143 | #ifdef CURL_PULL_INTTYPES_H 144 | # include 145 | #endif 146 | 147 | /* Configure process defines this to 1 when it finds out that system */ 148 | /* header file sys/socket.h must be included by the external interface. */ 149 | #cmakedefine CURL_PULL_SYS_SOCKET_H 150 | #ifdef CURL_PULL_SYS_SOCKET_H 151 | # include 152 | #endif 153 | 154 | /* Configure process defines this to 1 when it finds out that system */ 155 | /* header file sys/poll.h must be included by the external interface. */ 156 | #cmakedefine CURL_PULL_SYS_POLL_H 157 | #ifdef CURL_PULL_SYS_POLL_H 158 | # include 159 | #endif 160 | 161 | /* The size of `long', as computed by sizeof. */ 162 | #define CURL_SIZEOF_LONG ${CURL_SIZEOF_LONG} 163 | 164 | /* Integral data type used for curl_socklen_t. */ 165 | #define CURL_TYPEOF_CURL_SOCKLEN_T ${CURL_TYPEOF_CURL_SOCKLEN_T} 166 | 167 | /* The size of `curl_socklen_t', as computed by sizeof. */ 168 | #define CURL_SIZEOF_CURL_SOCKLEN_T ${CURL_SIZEOF_CURL_SOCKLEN_T} 169 | 170 | /* Data type definition of curl_socklen_t. */ 171 | typedef CURL_TYPEOF_CURL_SOCKLEN_T curl_socklen_t; 172 | 173 | /* Signed integral data type used for curl_off_t. */ 174 | #define CURL_TYPEOF_CURL_OFF_T ${CURL_TYPEOF_CURL_OFF_T} 175 | 176 | /* Data type definition of curl_off_t. */ 177 | typedef CURL_TYPEOF_CURL_OFF_T curl_off_t; 178 | 179 | /* curl_off_t formatting string directive without "%" conversion specifier. */ 180 | #define CURL_FORMAT_CURL_OFF_T "${CURL_FORMAT_CURL_OFF_T}" 181 | 182 | /* unsigned curl_off_t formatting string without "%" conversion specifier. */ 183 | #define CURL_FORMAT_CURL_OFF_TU "${CURL_FORMAT_CURL_OFF_TU}" 184 | 185 | /* curl_off_t formatting string directive with "%" conversion specifier. */ 186 | #define CURL_FORMAT_OFF_T "${CURL_FORMAT_OFF_T}" 187 | 188 | /* The size of `curl_off_t', as computed by sizeof. */ 189 | #define CURL_SIZEOF_CURL_OFF_T ${CURL_SIZEOF_CURL_OFF_T} 190 | 191 | /* curl_off_t constant suffix. */ 192 | #define CURL_SUFFIX_CURL_OFF_T ${CURL_SUFFIX_CURL_OFF_T} 193 | 194 | /* unsigned curl_off_t constant suffix. */ 195 | #define CURL_SUFFIX_CURL_OFF_TU ${CURL_SUFFIX_CURL_OFF_TU} 196 | 197 | #endif /* __CURL_CURLBUILD_H */ 198 | -------------------------------------------------------------------------------- /liburl/include/curl/curlbuild.h.in: -------------------------------------------------------------------------------- 1 | #ifndef __CURL_CURLBUILD_H 2 | #define __CURL_CURLBUILD_H 3 | /*************************************************************************** 4 | * _ _ ____ _ 5 | * Project ___| | | | _ \| | 6 | * / __| | | | |_) | | 7 | * | (__| |_| | _ <| |___ 8 | * \___|\___/|_| \_\_____| 9 | * 10 | * Copyright (C) 1998 - 2012, Daniel Stenberg, , et al. 11 | * 12 | * This software is licensed as described in the file COPYING, which 13 | * you should have received as part of this distribution. The terms 14 | * are also available at https://curl.haxx.se/docs/copyright.html. 15 | * 16 | * You may opt to use, copy, modify, merge, publish, distribute and/or sell 17 | * copies of the Software, and permit persons to whom the Software is 18 | * furnished to do so, under the terms of the COPYING file. 19 | * 20 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY 21 | * KIND, either express or implied. 22 | * 23 | ***************************************************************************/ 24 | 25 | /* ================================================================ */ 26 | /* NOTES FOR CONFIGURE CAPABLE SYSTEMS */ 27 | /* ================================================================ */ 28 | 29 | /* 30 | * NOTE 1: 31 | * ------- 32 | * 33 | * Nothing in this file is intended to be modified or adjusted by the 34 | * curl library user nor by the curl library builder. 35 | * 36 | * If you think that something actually needs to be changed, adjusted 37 | * or fixed in this file, then, report it on the libcurl development 38 | * mailing list: https://cool.haxx.se/mailman/listinfo/curl-library/ 39 | * 40 | * This header file shall only export symbols which are 'curl' or 'CURL' 41 | * prefixed, otherwise public name space would be polluted. 42 | * 43 | * NOTE 2: 44 | * ------- 45 | * 46 | * Right now you might be staring at file include/curl/curlbuild.h.in or 47 | * at file include/curl/curlbuild.h, this is due to the following reason: 48 | * 49 | * On systems capable of running the configure script, the configure process 50 | * will overwrite the distributed include/curl/curlbuild.h file with one that 51 | * is suitable and specific to the library being configured and built, which 52 | * is generated from the include/curl/curlbuild.h.in template file. 53 | * 54 | */ 55 | 56 | /* ================================================================ */ 57 | /* DEFINITION OF THESE SYMBOLS SHALL NOT TAKE PLACE ANYWHERE ELSE */ 58 | /* ================================================================ */ 59 | 60 | #ifdef CURL_SIZEOF_LONG 61 | #error "CURL_SIZEOF_LONG shall not be defined except in curlbuild.h" 62 | Error Compilation_aborted_CURL_SIZEOF_LONG_already_defined 63 | #endif 64 | 65 | #ifdef CURL_TYPEOF_CURL_SOCKLEN_T 66 | #error "CURL_TYPEOF_CURL_SOCKLEN_T shall not be defined except in curlbuild.h" 67 | Error Compilation_aborted_CURL_TYPEOF_CURL_SOCKLEN_T_already_defined 68 | #endif 69 | 70 | #ifdef CURL_SIZEOF_CURL_SOCKLEN_T 71 | #error "CURL_SIZEOF_CURL_SOCKLEN_T shall not be defined except in curlbuild.h" 72 | Error Compilation_aborted_CURL_SIZEOF_CURL_SOCKLEN_T_already_defined 73 | #endif 74 | 75 | #ifdef CURL_TYPEOF_CURL_OFF_T 76 | #error "CURL_TYPEOF_CURL_OFF_T shall not be defined except in curlbuild.h" 77 | Error Compilation_aborted_CURL_TYPEOF_CURL_OFF_T_already_defined 78 | #endif 79 | 80 | #ifdef CURL_FORMAT_CURL_OFF_T 81 | #error "CURL_FORMAT_CURL_OFF_T shall not be defined except in curlbuild.h" 82 | Error Compilation_aborted_CURL_FORMAT_CURL_OFF_T_already_defined 83 | #endif 84 | 85 | #ifdef CURL_FORMAT_CURL_OFF_TU 86 | #error "CURL_FORMAT_CURL_OFF_TU shall not be defined except in curlbuild.h" 87 | Error Compilation_aborted_CURL_FORMAT_CURL_OFF_TU_already_defined 88 | #endif 89 | 90 | #ifdef CURL_FORMAT_OFF_T 91 | #error "CURL_FORMAT_OFF_T shall not be defined except in curlbuild.h" 92 | Error Compilation_aborted_CURL_FORMAT_OFF_T_already_defined 93 | #endif 94 | 95 | #ifdef CURL_SIZEOF_CURL_OFF_T 96 | #error "CURL_SIZEOF_CURL_OFF_T shall not be defined except in curlbuild.h" 97 | Error Compilation_aborted_CURL_SIZEOF_CURL_OFF_T_already_defined 98 | #endif 99 | 100 | #ifdef CURL_SUFFIX_CURL_OFF_T 101 | #error "CURL_SUFFIX_CURL_OFF_T shall not be defined except in curlbuild.h" 102 | Error Compilation_aborted_CURL_SUFFIX_CURL_OFF_T_already_defined 103 | #endif 104 | 105 | #ifdef CURL_SUFFIX_CURL_OFF_TU 106 | #error "CURL_SUFFIX_CURL_OFF_TU shall not be defined except in curlbuild.h" 107 | Error Compilation_aborted_CURL_SUFFIX_CURL_OFF_TU_already_defined 108 | #endif 109 | 110 | /* ================================================================ */ 111 | /* EXTERNAL INTERFACE SETTINGS FOR CONFIGURE CAPABLE SYSTEMS ONLY */ 112 | /* ================================================================ */ 113 | 114 | /* Configure process defines this to 1 when it finds out that system */ 115 | /* header file ws2tcpip.h must be included by the external interface. */ 116 | #undef CURL_PULL_WS2TCPIP_H 117 | #ifdef CURL_PULL_WS2TCPIP_H 118 | # ifndef WIN32_LEAN_AND_MEAN 119 | # define WIN32_LEAN_AND_MEAN 120 | # endif 121 | # include 122 | # include 123 | # include 124 | #endif 125 | 126 | /* Configure process defines this to 1 when it finds out that system */ 127 | /* header file sys/types.h must be included by the external interface. */ 128 | #undef CURL_PULL_SYS_TYPES_H 129 | #ifdef CURL_PULL_SYS_TYPES_H 130 | # include 131 | #endif 132 | 133 | /* Configure process defines this to 1 when it finds out that system */ 134 | /* header file stdint.h must be included by the external interface. */ 135 | #undef CURL_PULL_STDINT_H 136 | #ifdef CURL_PULL_STDINT_H 137 | # include 138 | #endif 139 | 140 | /* Configure process defines this to 1 when it finds out that system */ 141 | /* header file inttypes.h must be included by the external interface. */ 142 | #undef CURL_PULL_INTTYPES_H 143 | #ifdef CURL_PULL_INTTYPES_H 144 | # include 145 | #endif 146 | 147 | /* Configure process defines this to 1 when it finds out that system */ 148 | /* header file sys/socket.h must be included by the external interface. */ 149 | #undef CURL_PULL_SYS_SOCKET_H 150 | #ifdef CURL_PULL_SYS_SOCKET_H 151 | # include 152 | #endif 153 | 154 | /* Configure process defines this to 1 when it finds out that system */ 155 | /* header file sys/poll.h must be included by the external interface. */ 156 | #undef CURL_PULL_SYS_POLL_H 157 | #ifdef CURL_PULL_SYS_POLL_H 158 | # include 159 | #endif 160 | 161 | /* The size of `long', as computed by sizeof. */ 162 | #undef CURL_SIZEOF_LONG 163 | 164 | /* Integral data type used for curl_socklen_t. */ 165 | #undef CURL_TYPEOF_CURL_SOCKLEN_T 166 | 167 | /* The size of `curl_socklen_t', as computed by sizeof. */ 168 | #undef CURL_SIZEOF_CURL_SOCKLEN_T 169 | 170 | /* Data type definition of curl_socklen_t. */ 171 | typedef CURL_TYPEOF_CURL_SOCKLEN_T curl_socklen_t; 172 | 173 | /* Signed integral data type used for curl_off_t. */ 174 | #undef CURL_TYPEOF_CURL_OFF_T 175 | 176 | /* Data type definition of curl_off_t. */ 177 | typedef CURL_TYPEOF_CURL_OFF_T curl_off_t; 178 | 179 | /* curl_off_t formatting string directive without "%" conversion specifier. */ 180 | #undef CURL_FORMAT_CURL_OFF_T 181 | 182 | /* unsigned curl_off_t formatting string without "%" conversion specifier. */ 183 | #undef CURL_FORMAT_CURL_OFF_TU 184 | 185 | /* curl_off_t formatting string directive with "%" conversion specifier. */ 186 | #undef CURL_FORMAT_OFF_T 187 | 188 | /* The size of `curl_off_t', as computed by sizeof. */ 189 | #undef CURL_SIZEOF_CURL_OFF_T 190 | 191 | /* curl_off_t constant suffix. */ 192 | #undef CURL_SUFFIX_CURL_OFF_T 193 | 194 | /* unsigned curl_off_t constant suffix. */ 195 | #undef CURL_SUFFIX_CURL_OFF_TU 196 | 197 | #endif /* __CURL_CURLBUILD_H */ 198 | -------------------------------------------------------------------------------- /liburl/include/curl/curlrules.h: -------------------------------------------------------------------------------- 1 | #ifndef __CURL_CURLRULES_H 2 | #define __CURL_CURLRULES_H 3 | /*************************************************************************** 4 | * _ _ ____ _ 5 | * Project ___| | | | _ \| | 6 | * / __| | | | |_) | | 7 | * | (__| |_| | _ <| |___ 8 | * \___|\___/|_| \_\_____| 9 | * 10 | * Copyright (C) 1998 - 2012, Daniel Stenberg, , et al. 11 | * 12 | * This software is licensed as described in the file COPYING, which 13 | * you should have received as part of this distribution. The terms 14 | * are also available at https://curl.haxx.se/docs/copyright.html. 15 | * 16 | * You may opt to use, copy, modify, merge, publish, distribute and/or sell 17 | * copies of the Software, and permit persons to whom the Software is 18 | * furnished to do so, under the terms of the COPYING file. 19 | * 20 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY 21 | * KIND, either express or implied. 22 | * 23 | ***************************************************************************/ 24 | 25 | /* ================================================================ */ 26 | /* COMPILE TIME SANITY CHECKS */ 27 | /* ================================================================ */ 28 | 29 | /* 30 | * NOTE 1: 31 | * ------- 32 | * 33 | * All checks done in this file are intentionally placed in a public 34 | * header file which is pulled by curl/curl.h when an application is 35 | * being built using an already built libcurl library. Additionally 36 | * this file is also included and used when building the library. 37 | * 38 | * If compilation fails on this file it is certainly sure that the 39 | * problem is elsewhere. It could be a problem in the curlbuild.h 40 | * header file, or simply that you are using different compilation 41 | * settings than those used to build the library. 42 | * 43 | * Nothing in this file is intended to be modified or adjusted by the 44 | * curl library user nor by the curl library builder. 45 | * 46 | * Do not deactivate any check, these are done to make sure that the 47 | * library is properly built and used. 48 | * 49 | * You can find further help on the libcurl development mailing list: 50 | * https://cool.haxx.se/mailman/listinfo/curl-library/ 51 | * 52 | * NOTE 2 53 | * ------ 54 | * 55 | * Some of the following compile time checks are based on the fact 56 | * that the dimension of a constant array can not be a negative one. 57 | * In this way if the compile time verification fails, the compilation 58 | * will fail issuing an error. The error description wording is compiler 59 | * dependent but it will be quite similar to one of the following: 60 | * 61 | * "negative subscript or subscript is too large" 62 | * "array must have at least one element" 63 | * "-1 is an illegal array size" 64 | * "size of array is negative" 65 | * 66 | * If you are building an application which tries to use an already 67 | * built libcurl library and you are getting this kind of errors on 68 | * this file, it is a clear indication that there is a mismatch between 69 | * how the library was built and how you are trying to use it for your 70 | * application. Your already compiled or binary library provider is the 71 | * only one who can give you the details you need to properly use it. 72 | */ 73 | 74 | /* 75 | * Verify that some macros are actually defined. 76 | */ 77 | 78 | #ifndef CURL_SIZEOF_LONG 79 | # error "CURL_SIZEOF_LONG definition is missing!" 80 | Error Compilation_aborted_CURL_SIZEOF_LONG_is_missing 81 | #endif 82 | 83 | #ifndef CURL_TYPEOF_CURL_SOCKLEN_T 84 | # error "CURL_TYPEOF_CURL_SOCKLEN_T definition is missing!" 85 | Error Compilation_aborted_CURL_TYPEOF_CURL_SOCKLEN_T_is_missing 86 | #endif 87 | 88 | #ifndef CURL_SIZEOF_CURL_SOCKLEN_T 89 | # error "CURL_SIZEOF_CURL_SOCKLEN_T definition is missing!" 90 | Error Compilation_aborted_CURL_SIZEOF_CURL_SOCKLEN_T_is_missing 91 | #endif 92 | 93 | #ifndef CURL_TYPEOF_CURL_OFF_T 94 | # error "CURL_TYPEOF_CURL_OFF_T definition is missing!" 95 | Error Compilation_aborted_CURL_TYPEOF_CURL_OFF_T_is_missing 96 | #endif 97 | 98 | #ifndef CURL_FORMAT_CURL_OFF_T 99 | # error "CURL_FORMAT_CURL_OFF_T definition is missing!" 100 | Error Compilation_aborted_CURL_FORMAT_CURL_OFF_T_is_missing 101 | #endif 102 | 103 | #ifndef CURL_FORMAT_CURL_OFF_TU 104 | # error "CURL_FORMAT_CURL_OFF_TU definition is missing!" 105 | Error Compilation_aborted_CURL_FORMAT_CURL_OFF_TU_is_missing 106 | #endif 107 | 108 | #ifndef CURL_FORMAT_OFF_T 109 | # error "CURL_FORMAT_OFF_T definition is missing!" 110 | Error Compilation_aborted_CURL_FORMAT_OFF_T_is_missing 111 | #endif 112 | 113 | #ifndef CURL_SIZEOF_CURL_OFF_T 114 | # error "CURL_SIZEOF_CURL_OFF_T definition is missing!" 115 | Error Compilation_aborted_CURL_SIZEOF_CURL_OFF_T_is_missing 116 | #endif 117 | 118 | #ifndef CURL_SUFFIX_CURL_OFF_T 119 | # error "CURL_SUFFIX_CURL_OFF_T definition is missing!" 120 | Error Compilation_aborted_CURL_SUFFIX_CURL_OFF_T_is_missing 121 | #endif 122 | 123 | #ifndef CURL_SUFFIX_CURL_OFF_TU 124 | # error "CURL_SUFFIX_CURL_OFF_TU definition is missing!" 125 | Error Compilation_aborted_CURL_SUFFIX_CURL_OFF_TU_is_missing 126 | #endif 127 | 128 | /* 129 | * Macros private to this header file. 130 | */ 131 | 132 | #define CurlchkszEQ(t, s) sizeof(t) == s ? 1 : -1 133 | 134 | #define CurlchkszGE(t1, t2) sizeof(t1) >= sizeof(t2) ? 1 : -1 135 | 136 | /* 137 | * Verify that the size previously defined and expected for long 138 | * is the same as the one reported by sizeof() at compile time. 139 | */ 140 | 141 | typedef char 142 | __curl_rule_01__ 143 | [CurlchkszEQ(long, CURL_SIZEOF_LONG)]; 144 | 145 | /* 146 | * Verify that the size previously defined and expected for 147 | * curl_off_t is actually the the same as the one reported 148 | * by sizeof() at compile time. 149 | */ 150 | 151 | typedef char 152 | __curl_rule_02__ 153 | [CurlchkszEQ(curl_off_t, CURL_SIZEOF_CURL_OFF_T)]; 154 | 155 | /* 156 | * Verify at compile time that the size of curl_off_t as reported 157 | * by sizeof() is greater or equal than the one reported for long 158 | * for the current compilation. 159 | */ 160 | 161 | typedef char 162 | __curl_rule_03__ 163 | [CurlchkszGE(curl_off_t, long)]; 164 | 165 | /* 166 | * Verify that the size previously defined and expected for 167 | * curl_socklen_t is actually the the same as the one reported 168 | * by sizeof() at compile time. 169 | */ 170 | 171 | typedef char 172 | __curl_rule_04__ 173 | [CurlchkszEQ(curl_socklen_t, CURL_SIZEOF_CURL_SOCKLEN_T)]; 174 | 175 | /* 176 | * Verify at compile time that the size of curl_socklen_t as reported 177 | * by sizeof() is greater or equal than the one reported for int for 178 | * the current compilation. 179 | */ 180 | 181 | typedef char 182 | __curl_rule_05__ 183 | [CurlchkszGE(curl_socklen_t, int)]; 184 | 185 | /* ================================================================ */ 186 | /* EXTERNALLY AND INTERNALLY VISIBLE DEFINITIONS */ 187 | /* ================================================================ */ 188 | 189 | /* 190 | * CURL_ISOCPP and CURL_OFF_T_C definitions are done here in order to allow 191 | * these to be visible and exported by the external libcurl interface API, 192 | * while also making them visible to the library internals, simply including 193 | * curl_setup.h, without actually needing to include curl.h internally. 194 | * If some day this section would grow big enough, all this should be moved 195 | * to its own header file. 196 | */ 197 | 198 | /* 199 | * Figure out if we can use the ## preprocessor operator, which is supported 200 | * by ISO/ANSI C and C++. Some compilers support it without setting __STDC__ 201 | * or __cplusplus so we need to carefully check for them too. 202 | */ 203 | 204 | #if defined(__STDC__) || defined(_MSC_VER) || defined(__cplusplus) || \ 205 | defined(__HP_aCC) || defined(__BORLANDC__) || defined(__LCC__) || \ 206 | defined(__POCC__) || defined(__SALFORDC__) || defined(__HIGHC__) || \ 207 | defined(__ILEC400__) 208 | /* This compiler is believed to have an ISO compatible preprocessor */ 209 | #define CURL_ISOCPP 210 | #else 211 | /* This compiler is believed NOT to have an ISO compatible preprocessor */ 212 | #undef CURL_ISOCPP 213 | #endif 214 | 215 | /* 216 | * Macros for minimum-width signed and unsigned curl_off_t integer constants. 217 | */ 218 | 219 | #if defined(__BORLANDC__) && (__BORLANDC__ == 0x0551) 220 | # define __CURL_OFF_T_C_HLPR2(x) x 221 | # define __CURL_OFF_T_C_HLPR1(x) __CURL_OFF_T_C_HLPR2(x) 222 | # define CURL_OFF_T_C(Val) __CURL_OFF_T_C_HLPR1(Val) ## \ 223 | __CURL_OFF_T_C_HLPR1(CURL_SUFFIX_CURL_OFF_T) 224 | # define CURL_OFF_TU_C(Val) __CURL_OFF_T_C_HLPR1(Val) ## \ 225 | __CURL_OFF_T_C_HLPR1(CURL_SUFFIX_CURL_OFF_TU) 226 | #else 227 | # ifdef CURL_ISOCPP 228 | # define __CURL_OFF_T_C_HLPR2(Val,Suffix) Val ## Suffix 229 | # else 230 | # define __CURL_OFF_T_C_HLPR2(Val,Suffix) Val/**/Suffix 231 | # endif 232 | # define __CURL_OFF_T_C_HLPR1(Val,Suffix) __CURL_OFF_T_C_HLPR2(Val,Suffix) 233 | # define CURL_OFF_T_C(Val) __CURL_OFF_T_C_HLPR1(Val,CURL_SUFFIX_CURL_OFF_T) 234 | # define CURL_OFF_TU_C(Val) __CURL_OFF_T_C_HLPR1(Val,CURL_SUFFIX_CURL_OFF_TU) 235 | #endif 236 | 237 | /* 238 | * Get rid of macros private to this header file. 239 | */ 240 | 241 | #undef CurlchkszEQ 242 | #undef CurlchkszGE 243 | 244 | /* 245 | * Get rid of macros not intended to exist beyond this point. 246 | */ 247 | 248 | #undef CURL_PULL_WS2TCPIP_H 249 | #undef CURL_PULL_SYS_TYPES_H 250 | #undef CURL_PULL_SYS_SOCKET_H 251 | #undef CURL_PULL_SYS_POLL_H 252 | #undef CURL_PULL_STDINT_H 253 | #undef CURL_PULL_INTTYPES_H 254 | 255 | #undef CURL_TYPEOF_CURL_SOCKLEN_T 256 | #undef CURL_TYPEOF_CURL_OFF_T 257 | 258 | #ifdef CURL_NO_OLDIES 259 | #undef CURL_FORMAT_OFF_T /* not required since 7.19.0 - obsoleted in 7.20.0 */ 260 | #endif 261 | 262 | #endif /* __CURL_CURLRULES_H */ 263 | -------------------------------------------------------------------------------- /liburl/include/curl/curlver.h: -------------------------------------------------------------------------------- 1 | #ifndef __CURL_CURLVER_H 2 | #define __CURL_CURLVER_H 3 | /*************************************************************************** 4 | * _ _ ____ _ 5 | * Project ___| | | | _ \| | 6 | * / __| | | | |_) | | 7 | * | (__| |_| | _ <| |___ 8 | * \___|\___/|_| \_\_____| 9 | * 10 | * Copyright (C) 1998 - 2016, Daniel Stenberg, , et al. 11 | * 12 | * This software is licensed as described in the file COPYING, which 13 | * you should have received as part of this distribution. The terms 14 | * are also available at https://curl.haxx.se/docs/copyright.html. 15 | * 16 | * You may opt to use, copy, modify, merge, publish, distribute and/or sell 17 | * copies of the Software, and permit persons to whom the Software is 18 | * furnished to do so, under the terms of the COPYING file. 19 | * 20 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY 21 | * KIND, either express or implied. 22 | * 23 | ***************************************************************************/ 24 | 25 | /* This header file contains nothing but libcurl version info, generated by 26 | a script at release-time. This was made its own header file in 7.11.2 */ 27 | 28 | /* This is the global package copyright */ 29 | #define LIBCURL_COPYRIGHT "1996 - 2016 Daniel Stenberg, ." 30 | 31 | /* This is the version number of the libcurl package from which this header 32 | file origins: */ 33 | #define LIBCURL_VERSION "7.50.1" 34 | 35 | /* The numeric version number is also available "in parts" by using these 36 | defines: */ 37 | #define LIBCURL_VERSION_MAJOR 7 38 | #define LIBCURL_VERSION_MINOR 50 39 | #define LIBCURL_VERSION_PATCH 1 40 | 41 | /* This is the numeric version of the libcurl version number, meant for easier 42 | parsing and comparions by programs. The LIBCURL_VERSION_NUM define will 43 | always follow this syntax: 44 | 45 | 0xXXYYZZ 46 | 47 | Where XX, YY and ZZ are the main version, release and patch numbers in 48 | hexadecimal (using 8 bits each). All three numbers are always represented 49 | using two digits. 1.2 would appear as "0x010200" while version 9.11.7 50 | appears as "0x090b07". 51 | 52 | This 6-digit (24 bits) hexadecimal number does not show pre-release number, 53 | and it is always a greater number in a more recent release. It makes 54 | comparisons with greater than and less than work. 55 | 56 | Note: This define is the full hex number and _does not_ use the 57 | CURL_VERSION_BITS() macro since curl's own configure script greps for it 58 | and needs it to contain the full number. 59 | */ 60 | #define LIBCURL_VERSION_NUM 0x073201 61 | 62 | /* 63 | * This is the date and time when the full source package was created. The 64 | * timestamp is not stored in git, as the timestamp is properly set in the 65 | * tarballs by the maketgz script. 66 | * 67 | * The format of the date should follow this template: 68 | * 69 | * "Mon Feb 12 11:35:33 UTC 2007" 70 | */ 71 | #define LIBCURL_TIMESTAMP "Wed Aug 3 06:38:49 UTC 2016" 72 | 73 | #define CURL_VERSION_BITS(x,y,z) ((x)<<16|(y)<<8|z) 74 | #define CURL_AT_LEAST_VERSION(x,y,z) \ 75 | (LIBCURL_VERSION_NUM >= CURL_VERSION_BITS(x, y, z)) 76 | 77 | #endif /* __CURL_CURLVER_H */ 78 | -------------------------------------------------------------------------------- /liburl/include/curl/easy.h: -------------------------------------------------------------------------------- 1 | #ifndef __CURL_EASY_H 2 | #define __CURL_EASY_H 3 | /*************************************************************************** 4 | * _ _ ____ _ 5 | * Project ___| | | | _ \| | 6 | * / __| | | | |_) | | 7 | * | (__| |_| | _ <| |___ 8 | * \___|\___/|_| \_\_____| 9 | * 10 | * Copyright (C) 1998 - 2008, Daniel Stenberg, , et al. 11 | * 12 | * This software is licensed as described in the file COPYING, which 13 | * you should have received as part of this distribution. The terms 14 | * are also available at https://curl.haxx.se/docs/copyright.html. 15 | * 16 | * You may opt to use, copy, modify, merge, publish, distribute and/or sell 17 | * copies of the Software, and permit persons to whom the Software is 18 | * furnished to do so, under the terms of the COPYING file. 19 | * 20 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY 21 | * KIND, either express or implied. 22 | * 23 | ***************************************************************************/ 24 | #ifdef __cplusplus 25 | extern "C" { 26 | #endif 27 | 28 | CURL_EXTERN CURL *curl_easy_init(void); 29 | CURL_EXTERN CURLcode curl_easy_setopt(CURL *curl, CURLoption option, ...); 30 | CURL_EXTERN CURLcode curl_easy_perform(CURL *curl); 31 | CURL_EXTERN void curl_easy_cleanup(CURL *curl); 32 | 33 | /* 34 | * NAME curl_easy_getinfo() 35 | * 36 | * DESCRIPTION 37 | * 38 | * Request internal information from the curl session with this function. The 39 | * third argument MUST be a pointer to a long, a pointer to a char * or a 40 | * pointer to a double (as the documentation describes elsewhere). The data 41 | * pointed to will be filled in accordingly and can be relied upon only if the 42 | * function returns CURLE_OK. This function is intended to get used *AFTER* a 43 | * performed transfer, all results from this function are undefined until the 44 | * transfer is completed. 45 | */ 46 | CURL_EXTERN CURLcode curl_easy_getinfo(CURL *curl, CURLINFO info, ...); 47 | 48 | 49 | /* 50 | * NAME curl_easy_duphandle() 51 | * 52 | * DESCRIPTION 53 | * 54 | * Creates a new curl session handle with the same options set for the handle 55 | * passed in. Duplicating a handle could only be a matter of cloning data and 56 | * options, internal state info and things like persistent connections cannot 57 | * be transferred. It is useful in multithreaded applications when you can run 58 | * curl_easy_duphandle() for each new thread to avoid a series of identical 59 | * curl_easy_setopt() invokes in every thread. 60 | */ 61 | CURL_EXTERN CURL* curl_easy_duphandle(CURL *curl); 62 | 63 | /* 64 | * NAME curl_easy_reset() 65 | * 66 | * DESCRIPTION 67 | * 68 | * Re-initializes a CURL handle to the default values. This puts back the 69 | * handle to the same state as it was in when it was just created. 70 | * 71 | * It does keep: live connections, the Session ID cache, the DNS cache and the 72 | * cookies. 73 | */ 74 | CURL_EXTERN void curl_easy_reset(CURL *curl); 75 | 76 | /* 77 | * NAME curl_easy_recv() 78 | * 79 | * DESCRIPTION 80 | * 81 | * Receives data from the connected socket. Use after successful 82 | * curl_easy_perform() with CURLOPT_CONNECT_ONLY option. 83 | */ 84 | CURL_EXTERN CURLcode curl_easy_recv(CURL *curl, void *buffer, size_t buflen, 85 | size_t *n); 86 | 87 | /* 88 | * NAME curl_easy_send() 89 | * 90 | * DESCRIPTION 91 | * 92 | * Sends data over the connected socket. Use after successful 93 | * curl_easy_perform() with CURLOPT_CONNECT_ONLY option. 94 | */ 95 | CURL_EXTERN CURLcode curl_easy_send(CURL *curl, const void *buffer, 96 | size_t buflen, size_t *n); 97 | 98 | #ifdef __cplusplus 99 | } 100 | #endif 101 | 102 | #endif 103 | -------------------------------------------------------------------------------- /liburl/include/curl/mprintf.h: -------------------------------------------------------------------------------- 1 | #ifndef __CURL_MPRINTF_H 2 | #define __CURL_MPRINTF_H 3 | /*************************************************************************** 4 | * _ _ ____ _ 5 | * Project ___| | | | _ \| | 6 | * / __| | | | |_) | | 7 | * | (__| |_| | _ <| |___ 8 | * \___|\___/|_| \_\_____| 9 | * 10 | * Copyright (C) 1998 - 2016, Daniel Stenberg, , et al. 11 | * 12 | * This software is licensed as described in the file COPYING, which 13 | * you should have received as part of this distribution. The terms 14 | * are also available at https://curl.haxx.se/docs/copyright.html. 15 | * 16 | * You may opt to use, copy, modify, merge, publish, distribute and/or sell 17 | * copies of the Software, and permit persons to whom the Software is 18 | * furnished to do so, under the terms of the COPYING file. 19 | * 20 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY 21 | * KIND, either express or implied. 22 | * 23 | ***************************************************************************/ 24 | 25 | #include 26 | #include /* needed for FILE */ 27 | #include "curl.h" /* for CURL_EXTERN */ 28 | 29 | #ifdef __cplusplus 30 | extern "C" { 31 | #endif 32 | 33 | CURL_EXTERN int curl_mprintf(const char *format, ...); 34 | CURL_EXTERN int curl_mfprintf(FILE *fd, const char *format, ...); 35 | CURL_EXTERN int curl_msprintf(char *buffer, const char *format, ...); 36 | CURL_EXTERN int curl_msnprintf(char *buffer, size_t maxlength, 37 | const char *format, ...); 38 | CURL_EXTERN int curl_mvprintf(const char *format, va_list args); 39 | CURL_EXTERN int curl_mvfprintf(FILE *fd, const char *format, va_list args); 40 | CURL_EXTERN int curl_mvsprintf(char *buffer, const char *format, va_list args); 41 | CURL_EXTERN int curl_mvsnprintf(char *buffer, size_t maxlength, 42 | const char *format, va_list args); 43 | CURL_EXTERN char *curl_maprintf(const char *format, ...); 44 | CURL_EXTERN char *curl_mvaprintf(const char *format, va_list args); 45 | 46 | #ifdef __cplusplus 47 | } 48 | #endif 49 | 50 | #endif /* __CURL_MPRINTF_H */ 51 | -------------------------------------------------------------------------------- /liburl/include/curl/multi.h: -------------------------------------------------------------------------------- 1 | #ifndef __CURL_MULTI_H 2 | #define __CURL_MULTI_H 3 | /*************************************************************************** 4 | * _ _ ____ _ 5 | * Project ___| | | | _ \| | 6 | * / __| | | | |_) | | 7 | * | (__| |_| | _ <| |___ 8 | * \___|\___/|_| \_\_____| 9 | * 10 | * Copyright (C) 1998 - 2016, Daniel Stenberg, , et al. 11 | * 12 | * This software is licensed as described in the file COPYING, which 13 | * you should have received as part of this distribution. The terms 14 | * are also available at https://curl.haxx.se/docs/copyright.html. 15 | * 16 | * You may opt to use, copy, modify, merge, publish, distribute and/or sell 17 | * copies of the Software, and permit persons to whom the Software is 18 | * furnished to do so, under the terms of the COPYING file. 19 | * 20 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY 21 | * KIND, either express or implied. 22 | * 23 | ***************************************************************************/ 24 | /* 25 | This is an "external" header file. Don't give away any internals here! 26 | 27 | GOALS 28 | 29 | o Enable a "pull" interface. The application that uses libcurl decides where 30 | and when to ask libcurl to get/send data. 31 | 32 | o Enable multiple simultaneous transfers in the same thread without making it 33 | complicated for the application. 34 | 35 | o Enable the application to select() on its own file descriptors and curl's 36 | file descriptors simultaneous easily. 37 | 38 | */ 39 | 40 | /* 41 | * This header file should not really need to include "curl.h" since curl.h 42 | * itself includes this file and we expect user applications to do #include 43 | * without the need for especially including multi.h. 44 | * 45 | * For some reason we added this include here at one point, and rather than to 46 | * break existing (wrongly written) libcurl applications, we leave it as-is 47 | * but with this warning attached. 48 | */ 49 | #include "curl.h" 50 | 51 | #ifdef __cplusplus 52 | extern "C" { 53 | #endif 54 | 55 | #if defined(BUILDING_LIBCURL) || defined(CURL_STRICTER) 56 | typedef struct Curl_multi CURLM; 57 | #else 58 | typedef void CURLM; 59 | #endif 60 | 61 | typedef enum { 62 | CURLM_CALL_MULTI_PERFORM = -1, /* please call curl_multi_perform() or 63 | curl_multi_socket*() soon */ 64 | CURLM_OK, 65 | CURLM_BAD_HANDLE, /* the passed-in handle is not a valid CURLM handle */ 66 | CURLM_BAD_EASY_HANDLE, /* an easy handle was not good/valid */ 67 | CURLM_OUT_OF_MEMORY, /* if you ever get this, you're in deep sh*t */ 68 | CURLM_INTERNAL_ERROR, /* this is a libcurl bug */ 69 | CURLM_BAD_SOCKET, /* the passed in socket argument did not match */ 70 | CURLM_UNKNOWN_OPTION, /* curl_multi_setopt() with unsupported option */ 71 | CURLM_ADDED_ALREADY, /* an easy handle already added to a multi handle was 72 | attempted to get added - again */ 73 | CURLM_LAST 74 | } CURLMcode; 75 | 76 | /* just to make code nicer when using curl_multi_socket() you can now check 77 | for CURLM_CALL_MULTI_SOCKET too in the same style it works for 78 | curl_multi_perform() and CURLM_CALL_MULTI_PERFORM */ 79 | #define CURLM_CALL_MULTI_SOCKET CURLM_CALL_MULTI_PERFORM 80 | 81 | /* bitmask bits for CURLMOPT_PIPELINING */ 82 | #define CURLPIPE_NOTHING 0L 83 | #define CURLPIPE_HTTP1 1L 84 | #define CURLPIPE_MULTIPLEX 2L 85 | 86 | typedef enum { 87 | CURLMSG_NONE, /* first, not used */ 88 | CURLMSG_DONE, /* This easy handle has completed. 'result' contains 89 | the CURLcode of the transfer */ 90 | CURLMSG_LAST /* last, not used */ 91 | } CURLMSG; 92 | 93 | struct CURLMsg { 94 | CURLMSG msg; /* what this message means */ 95 | CURL *easy_handle; /* the handle it concerns */ 96 | union { 97 | void *whatever; /* message-specific data */ 98 | CURLcode result; /* return code for transfer */ 99 | } data; 100 | }; 101 | typedef struct CURLMsg CURLMsg; 102 | 103 | /* Based on poll(2) structure and values. 104 | * We don't use pollfd and POLL* constants explicitly 105 | * to cover platforms without poll(). */ 106 | #define CURL_WAIT_POLLIN 0x0001 107 | #define CURL_WAIT_POLLPRI 0x0002 108 | #define CURL_WAIT_POLLOUT 0x0004 109 | 110 | struct curl_waitfd { 111 | curl_socket_t fd; 112 | short events; 113 | short revents; /* not supported yet */ 114 | }; 115 | 116 | /* 117 | * Name: curl_multi_init() 118 | * 119 | * Desc: inititalize multi-style curl usage 120 | * 121 | * Returns: a new CURLM handle to use in all 'curl_multi' functions. 122 | */ 123 | CURL_EXTERN CURLM *curl_multi_init(void); 124 | 125 | /* 126 | * Name: curl_multi_add_handle() 127 | * 128 | * Desc: add a standard curl handle to the multi stack 129 | * 130 | * Returns: CURLMcode type, general multi error code. 131 | */ 132 | CURL_EXTERN CURLMcode curl_multi_add_handle(CURLM *multi_handle, 133 | CURL *curl_handle); 134 | 135 | /* 136 | * Name: curl_multi_remove_handle() 137 | * 138 | * Desc: removes a curl handle from the multi stack again 139 | * 140 | * Returns: CURLMcode type, general multi error code. 141 | */ 142 | CURL_EXTERN CURLMcode curl_multi_remove_handle(CURLM *multi_handle, 143 | CURL *curl_handle); 144 | 145 | /* 146 | * Name: curl_multi_fdset() 147 | * 148 | * Desc: Ask curl for its fd_set sets. The app can use these to select() or 149 | * poll() on. We want curl_multi_perform() called as soon as one of 150 | * them are ready. 151 | * 152 | * Returns: CURLMcode type, general multi error code. 153 | */ 154 | CURL_EXTERN CURLMcode curl_multi_fdset(CURLM *multi_handle, 155 | fd_set *read_fd_set, 156 | fd_set *write_fd_set, 157 | fd_set *exc_fd_set, 158 | int *max_fd); 159 | 160 | /* 161 | * Name: curl_multi_wait() 162 | * 163 | * Desc: Poll on all fds within a CURLM set as well as any 164 | * additional fds passed to the function. 165 | * 166 | * Returns: CURLMcode type, general multi error code. 167 | */ 168 | CURL_EXTERN CURLMcode curl_multi_wait(CURLM *multi_handle, 169 | struct curl_waitfd extra_fds[], 170 | unsigned int extra_nfds, 171 | int timeout_ms, 172 | int *ret); 173 | 174 | /* 175 | * Name: curl_multi_perform() 176 | * 177 | * Desc: When the app thinks there's data available for curl it calls this 178 | * function to read/write whatever there is right now. This returns 179 | * as soon as the reads and writes are done. This function does not 180 | * require that there actually is data available for reading or that 181 | * data can be written, it can be called just in case. It returns 182 | * the number of handles that still transfer data in the second 183 | * argument's integer-pointer. 184 | * 185 | * Returns: CURLMcode type, general multi error code. *NOTE* that this only 186 | * returns errors etc regarding the whole multi stack. There might 187 | * still have occurred problems on invidual transfers even when this 188 | * returns OK. 189 | */ 190 | CURL_EXTERN CURLMcode curl_multi_perform(CURLM *multi_handle, 191 | int *running_handles); 192 | 193 | /* 194 | * Name: curl_multi_cleanup() 195 | * 196 | * Desc: Cleans up and removes a whole multi stack. It does not free or 197 | * touch any individual easy handles in any way. We need to define 198 | * in what state those handles will be if this function is called 199 | * in the middle of a transfer. 200 | * 201 | * Returns: CURLMcode type, general multi error code. 202 | */ 203 | CURL_EXTERN CURLMcode curl_multi_cleanup(CURLM *multi_handle); 204 | 205 | /* 206 | * Name: curl_multi_info_read() 207 | * 208 | * Desc: Ask the multi handle if there's any messages/informationals from 209 | * the individual transfers. Messages include informationals such as 210 | * error code from the transfer or just the fact that a transfer is 211 | * completed. More details on these should be written down as well. 212 | * 213 | * Repeated calls to this function will return a new struct each 214 | * time, until a special "end of msgs" struct is returned as a signal 215 | * that there is no more to get at this point. 216 | * 217 | * The data the returned pointer points to will not survive calling 218 | * curl_multi_cleanup(). 219 | * 220 | * The 'CURLMsg' struct is meant to be very simple and only contain 221 | * very basic informations. If more involved information is wanted, 222 | * we will provide the particular "transfer handle" in that struct 223 | * and that should/could/would be used in subsequent 224 | * curl_easy_getinfo() calls (or similar). The point being that we 225 | * must never expose complex structs to applications, as then we'll 226 | * undoubtably get backwards compatibility problems in the future. 227 | * 228 | * Returns: A pointer to a filled-in struct, or NULL if it failed or ran out 229 | * of structs. It also writes the number of messages left in the 230 | * queue (after this read) in the integer the second argument points 231 | * to. 232 | */ 233 | CURL_EXTERN CURLMsg *curl_multi_info_read(CURLM *multi_handle, 234 | int *msgs_in_queue); 235 | 236 | /* 237 | * Name: curl_multi_strerror() 238 | * 239 | * Desc: The curl_multi_strerror function may be used to turn a CURLMcode 240 | * value into the equivalent human readable error string. This is 241 | * useful for printing meaningful error messages. 242 | * 243 | * Returns: A pointer to a zero-terminated error message. 244 | */ 245 | CURL_EXTERN const char *curl_multi_strerror(CURLMcode); 246 | 247 | /* 248 | * Name: curl_multi_socket() and 249 | * curl_multi_socket_all() 250 | * 251 | * Desc: An alternative version of curl_multi_perform() that allows the 252 | * application to pass in one of the file descriptors that have been 253 | * detected to have "action" on them and let libcurl perform. 254 | * See man page for details. 255 | */ 256 | #define CURL_POLL_NONE 0 257 | #define CURL_POLL_IN 1 258 | #define CURL_POLL_OUT 2 259 | #define CURL_POLL_INOUT 3 260 | #define CURL_POLL_REMOVE 4 261 | 262 | #define CURL_SOCKET_TIMEOUT CURL_SOCKET_BAD 263 | 264 | #define CURL_CSELECT_IN 0x01 265 | #define CURL_CSELECT_OUT 0x02 266 | #define CURL_CSELECT_ERR 0x04 267 | 268 | typedef int (*curl_socket_callback)(CURL *easy, /* easy handle */ 269 | curl_socket_t s, /* socket */ 270 | int what, /* see above */ 271 | void *userp, /* private callback 272 | pointer */ 273 | void *socketp); /* private socket 274 | pointer */ 275 | /* 276 | * Name: curl_multi_timer_callback 277 | * 278 | * Desc: Called by libcurl whenever the library detects a change in the 279 | * maximum number of milliseconds the app is allowed to wait before 280 | * curl_multi_socket() or curl_multi_perform() must be called 281 | * (to allow libcurl's timed events to take place). 282 | * 283 | * Returns: The callback should return zero. 284 | */ 285 | typedef int (*curl_multi_timer_callback)(CURLM *multi, /* multi handle */ 286 | long timeout_ms, /* see above */ 287 | void *userp); /* private callback 288 | pointer */ 289 | 290 | CURL_EXTERN CURLMcode curl_multi_socket(CURLM *multi_handle, curl_socket_t s, 291 | int *running_handles); 292 | 293 | CURL_EXTERN CURLMcode curl_multi_socket_action(CURLM *multi_handle, 294 | curl_socket_t s, 295 | int ev_bitmask, 296 | int *running_handles); 297 | 298 | CURL_EXTERN CURLMcode curl_multi_socket_all(CURLM *multi_handle, 299 | int *running_handles); 300 | 301 | #ifndef CURL_ALLOW_OLD_MULTI_SOCKET 302 | /* This macro below was added in 7.16.3 to push users who recompile to use 303 | the new curl_multi_socket_action() instead of the old curl_multi_socket() 304 | */ 305 | #define curl_multi_socket(x,y,z) curl_multi_socket_action(x,y,0,z) 306 | #endif 307 | 308 | /* 309 | * Name: curl_multi_timeout() 310 | * 311 | * Desc: Returns the maximum number of milliseconds the app is allowed to 312 | * wait before curl_multi_socket() or curl_multi_perform() must be 313 | * called (to allow libcurl's timed events to take place). 314 | * 315 | * Returns: CURLM error code. 316 | */ 317 | CURL_EXTERN CURLMcode curl_multi_timeout(CURLM *multi_handle, 318 | long *milliseconds); 319 | 320 | #undef CINIT /* re-using the same name as in curl.h */ 321 | 322 | #ifdef CURL_ISOCPP 323 | #define CINIT(name,type,num) CURLMOPT_ ## name = CURLOPTTYPE_ ## type + num 324 | #else 325 | /* The macro "##" is ISO C, we assume pre-ISO C doesn't support it. */ 326 | #define LONG CURLOPTTYPE_LONG 327 | #define OBJECTPOINT CURLOPTTYPE_OBJECTPOINT 328 | #define FUNCTIONPOINT CURLOPTTYPE_FUNCTIONPOINT 329 | #define OFF_T CURLOPTTYPE_OFF_T 330 | #define CINIT(name,type,number) CURLMOPT_/**/name = type + number 331 | #endif 332 | 333 | typedef enum { 334 | /* This is the socket callback function pointer */ 335 | CINIT(SOCKETFUNCTION, FUNCTIONPOINT, 1), 336 | 337 | /* This is the argument passed to the socket callback */ 338 | CINIT(SOCKETDATA, OBJECTPOINT, 2), 339 | 340 | /* set to 1 to enable pipelining for this multi handle */ 341 | CINIT(PIPELINING, LONG, 3), 342 | 343 | /* This is the timer callback function pointer */ 344 | CINIT(TIMERFUNCTION, FUNCTIONPOINT, 4), 345 | 346 | /* This is the argument passed to the timer callback */ 347 | CINIT(TIMERDATA, OBJECTPOINT, 5), 348 | 349 | /* maximum number of entries in the connection cache */ 350 | CINIT(MAXCONNECTS, LONG, 6), 351 | 352 | /* maximum number of (pipelining) connections to one host */ 353 | CINIT(MAX_HOST_CONNECTIONS, LONG, 7), 354 | 355 | /* maximum number of requests in a pipeline */ 356 | CINIT(MAX_PIPELINE_LENGTH, LONG, 8), 357 | 358 | /* a connection with a content-length longer than this 359 | will not be considered for pipelining */ 360 | CINIT(CONTENT_LENGTH_PENALTY_SIZE, OFF_T, 9), 361 | 362 | /* a connection with a chunk length longer than this 363 | will not be considered for pipelining */ 364 | CINIT(CHUNK_LENGTH_PENALTY_SIZE, OFF_T, 10), 365 | 366 | /* a list of site names(+port) that are blacklisted from 367 | pipelining */ 368 | CINIT(PIPELINING_SITE_BL, OBJECTPOINT, 11), 369 | 370 | /* a list of server types that are blacklisted from 371 | pipelining */ 372 | CINIT(PIPELINING_SERVER_BL, OBJECTPOINT, 12), 373 | 374 | /* maximum number of open connections in total */ 375 | CINIT(MAX_TOTAL_CONNECTIONS, LONG, 13), 376 | 377 | /* This is the server push callback function pointer */ 378 | CINIT(PUSHFUNCTION, FUNCTIONPOINT, 14), 379 | 380 | /* This is the argument passed to the server push callback */ 381 | CINIT(PUSHDATA, OBJECTPOINT, 15), 382 | 383 | CURLMOPT_LASTENTRY /* the last unused */ 384 | } CURLMoption; 385 | 386 | 387 | /* 388 | * Name: curl_multi_setopt() 389 | * 390 | * Desc: Sets options for the multi handle. 391 | * 392 | * Returns: CURLM error code. 393 | */ 394 | CURL_EXTERN CURLMcode curl_multi_setopt(CURLM *multi_handle, 395 | CURLMoption option, ...); 396 | 397 | 398 | /* 399 | * Name: curl_multi_assign() 400 | * 401 | * Desc: This function sets an association in the multi handle between the 402 | * given socket and a private pointer of the application. This is 403 | * (only) useful for curl_multi_socket uses. 404 | * 405 | * Returns: CURLM error code. 406 | */ 407 | CURL_EXTERN CURLMcode curl_multi_assign(CURLM *multi_handle, 408 | curl_socket_t sockfd, void *sockp); 409 | 410 | 411 | /* 412 | * Name: curl_push_callback 413 | * 414 | * Desc: This callback gets called when a new stream is being pushed by the 415 | * server. It approves or denies the new stream. 416 | * 417 | * Returns: CURL_PUSH_OK or CURL_PUSH_DENY. 418 | */ 419 | #define CURL_PUSH_OK 0 420 | #define CURL_PUSH_DENY 1 421 | 422 | struct curl_pushheaders; /* forward declaration only */ 423 | 424 | CURL_EXTERN char *curl_pushheader_bynum(struct curl_pushheaders *h, 425 | size_t num); 426 | CURL_EXTERN char *curl_pushheader_byname(struct curl_pushheaders *h, 427 | const char *name); 428 | 429 | typedef int (*curl_push_callback)(CURL *parent, 430 | CURL *easy, 431 | size_t num_headers, 432 | struct curl_pushheaders *headers, 433 | void *userp); 434 | 435 | #ifdef __cplusplus 436 | } /* end of extern "C" */ 437 | #endif 438 | 439 | #endif 440 | -------------------------------------------------------------------------------- /liburl/include/curl/stdcheaders.h: -------------------------------------------------------------------------------- 1 | #ifndef __STDC_HEADERS_H 2 | #define __STDC_HEADERS_H 3 | /*************************************************************************** 4 | * _ _ ____ _ 5 | * Project ___| | | | _ \| | 6 | * / __| | | | |_) | | 7 | * | (__| |_| | _ <| |___ 8 | * \___|\___/|_| \_\_____| 9 | * 10 | * Copyright (C) 1998 - 2010, Daniel Stenberg, , et al. 11 | * 12 | * This software is licensed as described in the file COPYING, which 13 | * you should have received as part of this distribution. The terms 14 | * are also available at https://curl.haxx.se/docs/copyright.html. 15 | * 16 | * You may opt to use, copy, modify, merge, publish, distribute and/or sell 17 | * copies of the Software, and permit persons to whom the Software is 18 | * furnished to do so, under the terms of the COPYING file. 19 | * 20 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY 21 | * KIND, either express or implied. 22 | * 23 | ***************************************************************************/ 24 | 25 | #include 26 | 27 | size_t fread (void *, size_t, size_t, FILE *); 28 | size_t fwrite (const void *, size_t, size_t, FILE *); 29 | 30 | int strcasecmp(const char *, const char *); 31 | int strncasecmp(const char *, const char *, size_t); 32 | 33 | #endif /* __STDC_HEADERS_H */ 34 | -------------------------------------------------------------------------------- /liburl/include/curl/typecheck-gcc.h: -------------------------------------------------------------------------------- 1 | #ifndef __CURL_TYPECHECK_GCC_H 2 | #define __CURL_TYPECHECK_GCC_H 3 | /*************************************************************************** 4 | * _ _ ____ _ 5 | * Project ___| | | | _ \| | 6 | * / __| | | | |_) | | 7 | * | (__| |_| | _ <| |___ 8 | * \___|\___/|_| \_\_____| 9 | * 10 | * Copyright (C) 1998 - 2015, Daniel Stenberg, , et al. 11 | * 12 | * This software is licensed as described in the file COPYING, which 13 | * you should have received as part of this distribution. The terms 14 | * are also available at https://curl.haxx.se/docs/copyright.html. 15 | * 16 | * You may opt to use, copy, modify, merge, publish, distribute and/or sell 17 | * copies of the Software, and permit persons to whom the Software is 18 | * furnished to do so, under the terms of the COPYING file. 19 | * 20 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY 21 | * KIND, either express or implied. 22 | * 23 | ***************************************************************************/ 24 | 25 | /* wraps curl_easy_setopt() with typechecking */ 26 | 27 | /* To add a new kind of warning, add an 28 | * if(_curl_is_sometype_option(_curl_opt)) 29 | * if(!_curl_is_sometype(value)) 30 | * _curl_easy_setopt_err_sometype(); 31 | * block and define _curl_is_sometype_option, _curl_is_sometype and 32 | * _curl_easy_setopt_err_sometype below 33 | * 34 | * NOTE: We use two nested 'if' statements here instead of the && operator, in 35 | * order to work around gcc bug #32061. It affects only gcc 4.3.x/4.4.x 36 | * when compiling with -Wlogical-op. 37 | * 38 | * To add an option that uses the same type as an existing option, you'll just 39 | * need to extend the appropriate _curl_*_option macro 40 | */ 41 | #define curl_easy_setopt(handle, option, value) \ 42 | __extension__ ({ \ 43 | __typeof__ (option) _curl_opt = option; \ 44 | if(__builtin_constant_p(_curl_opt)) { \ 45 | if(_curl_is_long_option(_curl_opt)) \ 46 | if(!_curl_is_long(value)) \ 47 | _curl_easy_setopt_err_long(); \ 48 | if(_curl_is_off_t_option(_curl_opt)) \ 49 | if(!_curl_is_off_t(value)) \ 50 | _curl_easy_setopt_err_curl_off_t(); \ 51 | if(_curl_is_string_option(_curl_opt)) \ 52 | if(!_curl_is_string(value)) \ 53 | _curl_easy_setopt_err_string(); \ 54 | if(_curl_is_write_cb_option(_curl_opt)) \ 55 | if(!_curl_is_write_cb(value)) \ 56 | _curl_easy_setopt_err_write_callback(); \ 57 | if((_curl_opt) == CURLOPT_READFUNCTION) \ 58 | if(!_curl_is_read_cb(value)) \ 59 | _curl_easy_setopt_err_read_cb(); \ 60 | if((_curl_opt) == CURLOPT_IOCTLFUNCTION) \ 61 | if(!_curl_is_ioctl_cb(value)) \ 62 | _curl_easy_setopt_err_ioctl_cb(); \ 63 | if((_curl_opt) == CURLOPT_SOCKOPTFUNCTION) \ 64 | if(!_curl_is_sockopt_cb(value)) \ 65 | _curl_easy_setopt_err_sockopt_cb(); \ 66 | if((_curl_opt) == CURLOPT_OPENSOCKETFUNCTION) \ 67 | if(!_curl_is_opensocket_cb(value)) \ 68 | _curl_easy_setopt_err_opensocket_cb(); \ 69 | if((_curl_opt) == CURLOPT_PROGRESSFUNCTION) \ 70 | if(!_curl_is_progress_cb(value)) \ 71 | _curl_easy_setopt_err_progress_cb(); \ 72 | if((_curl_opt) == CURLOPT_DEBUGFUNCTION) \ 73 | if(!_curl_is_debug_cb(value)) \ 74 | _curl_easy_setopt_err_debug_cb(); \ 75 | if((_curl_opt) == CURLOPT_SSL_CTX_FUNCTION) \ 76 | if(!_curl_is_ssl_ctx_cb(value)) \ 77 | _curl_easy_setopt_err_ssl_ctx_cb(); \ 78 | if(_curl_is_conv_cb_option(_curl_opt)) \ 79 | if(!_curl_is_conv_cb(value)) \ 80 | _curl_easy_setopt_err_conv_cb(); \ 81 | if((_curl_opt) == CURLOPT_SEEKFUNCTION) \ 82 | if(!_curl_is_seek_cb(value)) \ 83 | _curl_easy_setopt_err_seek_cb(); \ 84 | if(_curl_is_cb_data_option(_curl_opt)) \ 85 | if(!_curl_is_cb_data(value)) \ 86 | _curl_easy_setopt_err_cb_data(); \ 87 | if((_curl_opt) == CURLOPT_ERRORBUFFER) \ 88 | if(!_curl_is_error_buffer(value)) \ 89 | _curl_easy_setopt_err_error_buffer(); \ 90 | if((_curl_opt) == CURLOPT_STDERR) \ 91 | if(!_curl_is_FILE(value)) \ 92 | _curl_easy_setopt_err_FILE(); \ 93 | if(_curl_is_postfields_option(_curl_opt)) \ 94 | if(!_curl_is_postfields(value)) \ 95 | _curl_easy_setopt_err_postfields(); \ 96 | if((_curl_opt) == CURLOPT_HTTPPOST) \ 97 | if(!_curl_is_arr((value), struct curl_httppost)) \ 98 | _curl_easy_setopt_err_curl_httpost(); \ 99 | if(_curl_is_slist_option(_curl_opt)) \ 100 | if(!_curl_is_arr((value), struct curl_slist)) \ 101 | _curl_easy_setopt_err_curl_slist(); \ 102 | if((_curl_opt) == CURLOPT_SHARE) \ 103 | if(!_curl_is_ptr((value), CURLSH)) \ 104 | _curl_easy_setopt_err_CURLSH(); \ 105 | } \ 106 | curl_easy_setopt(handle, _curl_opt, value); \ 107 | }) 108 | 109 | /* wraps curl_easy_getinfo() with typechecking */ 110 | /* FIXME: don't allow const pointers */ 111 | #define curl_easy_getinfo(handle, info, arg) \ 112 | __extension__ ({ \ 113 | __typeof__ (info) _curl_info = info; \ 114 | if(__builtin_constant_p(_curl_info)) { \ 115 | if(_curl_is_string_info(_curl_info)) \ 116 | if(!_curl_is_arr((arg), char *)) \ 117 | _curl_easy_getinfo_err_string(); \ 118 | if(_curl_is_long_info(_curl_info)) \ 119 | if(!_curl_is_arr((arg), long)) \ 120 | _curl_easy_getinfo_err_long(); \ 121 | if(_curl_is_double_info(_curl_info)) \ 122 | if(!_curl_is_arr((arg), double)) \ 123 | _curl_easy_getinfo_err_double(); \ 124 | if(_curl_is_slist_info(_curl_info)) \ 125 | if(!_curl_is_arr((arg), struct curl_slist *)) \ 126 | _curl_easy_getinfo_err_curl_slist(); \ 127 | } \ 128 | curl_easy_getinfo(handle, _curl_info, arg); \ 129 | }) 130 | 131 | /* TODO: typechecking for curl_share_setopt() and curl_multi_setopt(), 132 | * for now just make sure that the functions are called with three 133 | * arguments 134 | */ 135 | #define curl_share_setopt(share,opt,param) curl_share_setopt(share,opt,param) 136 | #define curl_multi_setopt(handle,opt,param) curl_multi_setopt(handle,opt,param) 137 | 138 | 139 | /* the actual warnings, triggered by calling the _curl_easy_setopt_err* 140 | * functions */ 141 | 142 | /* To define a new warning, use _CURL_WARNING(identifier, "message") */ 143 | #define _CURL_WARNING(id, message) \ 144 | static void __attribute__((__warning__(message))) \ 145 | __attribute__((__unused__)) __attribute__((__noinline__)) \ 146 | id(void) { __asm__(""); } 147 | 148 | _CURL_WARNING(_curl_easy_setopt_err_long, 149 | "curl_easy_setopt expects a long argument for this option") 150 | _CURL_WARNING(_curl_easy_setopt_err_curl_off_t, 151 | "curl_easy_setopt expects a curl_off_t argument for this option") 152 | _CURL_WARNING(_curl_easy_setopt_err_string, 153 | "curl_easy_setopt expects a " 154 | "string (char* or char[]) argument for this option" 155 | ) 156 | _CURL_WARNING(_curl_easy_setopt_err_write_callback, 157 | "curl_easy_setopt expects a curl_write_callback argument for this option") 158 | _CURL_WARNING(_curl_easy_setopt_err_read_cb, 159 | "curl_easy_setopt expects a curl_read_callback argument for this option") 160 | _CURL_WARNING(_curl_easy_setopt_err_ioctl_cb, 161 | "curl_easy_setopt expects a curl_ioctl_callback argument for this option") 162 | _CURL_WARNING(_curl_easy_setopt_err_sockopt_cb, 163 | "curl_easy_setopt expects a curl_sockopt_callback argument for this option") 164 | _CURL_WARNING(_curl_easy_setopt_err_opensocket_cb, 165 | "curl_easy_setopt expects a " 166 | "curl_opensocket_callback argument for this option" 167 | ) 168 | _CURL_WARNING(_curl_easy_setopt_err_progress_cb, 169 | "curl_easy_setopt expects a curl_progress_callback argument for this option") 170 | _CURL_WARNING(_curl_easy_setopt_err_debug_cb, 171 | "curl_easy_setopt expects a curl_debug_callback argument for this option") 172 | _CURL_WARNING(_curl_easy_setopt_err_ssl_ctx_cb, 173 | "curl_easy_setopt expects a curl_ssl_ctx_callback argument for this option") 174 | _CURL_WARNING(_curl_easy_setopt_err_conv_cb, 175 | "curl_easy_setopt expects a curl_conv_callback argument for this option") 176 | _CURL_WARNING(_curl_easy_setopt_err_seek_cb, 177 | "curl_easy_setopt expects a curl_seek_callback argument for this option") 178 | _CURL_WARNING(_curl_easy_setopt_err_cb_data, 179 | "curl_easy_setopt expects a " 180 | "private data pointer as argument for this option") 181 | _CURL_WARNING(_curl_easy_setopt_err_error_buffer, 182 | "curl_easy_setopt expects a " 183 | "char buffer of CURL_ERROR_SIZE as argument for this option") 184 | _CURL_WARNING(_curl_easy_setopt_err_FILE, 185 | "curl_easy_setopt expects a FILE* argument for this option") 186 | _CURL_WARNING(_curl_easy_setopt_err_postfields, 187 | "curl_easy_setopt expects a void* or char* argument for this option") 188 | _CURL_WARNING(_curl_easy_setopt_err_curl_httpost, 189 | "curl_easy_setopt expects a struct curl_httppost* argument for this option") 190 | _CURL_WARNING(_curl_easy_setopt_err_curl_slist, 191 | "curl_easy_setopt expects a struct curl_slist* argument for this option") 192 | _CURL_WARNING(_curl_easy_setopt_err_CURLSH, 193 | "curl_easy_setopt expects a CURLSH* argument for this option") 194 | 195 | _CURL_WARNING(_curl_easy_getinfo_err_string, 196 | "curl_easy_getinfo expects a pointer to char * for this info") 197 | _CURL_WARNING(_curl_easy_getinfo_err_long, 198 | "curl_easy_getinfo expects a pointer to long for this info") 199 | _CURL_WARNING(_curl_easy_getinfo_err_double, 200 | "curl_easy_getinfo expects a pointer to double for this info") 201 | _CURL_WARNING(_curl_easy_getinfo_err_curl_slist, 202 | "curl_easy_getinfo expects a pointer to struct curl_slist * for this info") 203 | 204 | /* groups of curl_easy_setops options that take the same type of argument */ 205 | 206 | /* To add a new option to one of the groups, just add 207 | * (option) == CURLOPT_SOMETHING 208 | * to the or-expression. If the option takes a long or curl_off_t, you don't 209 | * have to do anything 210 | */ 211 | 212 | /* evaluates to true if option takes a long argument */ 213 | #define _curl_is_long_option(option) \ 214 | (0 < (option) && (option) < CURLOPTTYPE_OBJECTPOINT) 215 | 216 | #define _curl_is_off_t_option(option) \ 217 | ((option) > CURLOPTTYPE_OFF_T) 218 | 219 | /* evaluates to true if option takes a char* argument */ 220 | #define _curl_is_string_option(option) \ 221 | ((option) == CURLOPT_ACCEPT_ENCODING || \ 222 | (option) == CURLOPT_CAINFO || \ 223 | (option) == CURLOPT_CAPATH || \ 224 | (option) == CURLOPT_COOKIE || \ 225 | (option) == CURLOPT_COOKIEFILE || \ 226 | (option) == CURLOPT_COOKIEJAR || \ 227 | (option) == CURLOPT_COOKIELIST || \ 228 | (option) == CURLOPT_CRLFILE || \ 229 | (option) == CURLOPT_CUSTOMREQUEST || \ 230 | (option) == CURLOPT_DEFAULT_PROTOCOL || \ 231 | (option) == CURLOPT_DNS_INTERFACE || \ 232 | (option) == CURLOPT_DNS_LOCAL_IP4 || \ 233 | (option) == CURLOPT_DNS_LOCAL_IP6 || \ 234 | (option) == CURLOPT_DNS_SERVERS || \ 235 | (option) == CURLOPT_EGDSOCKET || \ 236 | (option) == CURLOPT_FTPPORT || \ 237 | (option) == CURLOPT_FTP_ACCOUNT || \ 238 | (option) == CURLOPT_FTP_ALTERNATIVE_TO_USER || \ 239 | (option) == CURLOPT_INTERFACE || \ 240 | (option) == CURLOPT_ISSUERCERT || \ 241 | (option) == CURLOPT_KEYPASSWD || \ 242 | (option) == CURLOPT_KRBLEVEL || \ 243 | (option) == CURLOPT_LOGIN_OPTIONS || \ 244 | (option) == CURLOPT_MAIL_AUTH || \ 245 | (option) == CURLOPT_MAIL_FROM || \ 246 | (option) == CURLOPT_NETRC_FILE || \ 247 | (option) == CURLOPT_NOPROXY || \ 248 | (option) == CURLOPT_PASSWORD || \ 249 | (option) == CURLOPT_PINNEDPUBLICKEY || \ 250 | (option) == CURLOPT_PROXY || \ 251 | (option) == CURLOPT_PROXYPASSWORD || \ 252 | (option) == CURLOPT_PROXYUSERNAME || \ 253 | (option) == CURLOPT_PROXYUSERPWD || \ 254 | (option) == CURLOPT_PROXY_SERVICE_NAME || \ 255 | (option) == CURLOPT_RANDOM_FILE || \ 256 | (option) == CURLOPT_RANGE || \ 257 | (option) == CURLOPT_REFERER || \ 258 | (option) == CURLOPT_RTSP_SESSION_ID || \ 259 | (option) == CURLOPT_RTSP_STREAM_URI || \ 260 | (option) == CURLOPT_RTSP_TRANSPORT || \ 261 | (option) == CURLOPT_SERVICE_NAME || \ 262 | (option) == CURLOPT_SOCKS5_GSSAPI_SERVICE || \ 263 | (option) == CURLOPT_SSH_HOST_PUBLIC_KEY_MD5 || \ 264 | (option) == CURLOPT_SSH_KNOWNHOSTS || \ 265 | (option) == CURLOPT_SSH_PRIVATE_KEYFILE || \ 266 | (option) == CURLOPT_SSH_PUBLIC_KEYFILE || \ 267 | (option) == CURLOPT_SSLCERT || \ 268 | (option) == CURLOPT_SSLCERTTYPE || \ 269 | (option) == CURLOPT_SSLENGINE || \ 270 | (option) == CURLOPT_SSLKEY || \ 271 | (option) == CURLOPT_SSLKEYTYPE || \ 272 | (option) == CURLOPT_SSL_CIPHER_LIST || \ 273 | (option) == CURLOPT_TLSAUTH_PASSWORD || \ 274 | (option) == CURLOPT_TLSAUTH_TYPE || \ 275 | (option) == CURLOPT_TLSAUTH_USERNAME || \ 276 | (option) == CURLOPT_UNIX_SOCKET_PATH || \ 277 | (option) == CURLOPT_URL || \ 278 | (option) == CURLOPT_USERAGENT || \ 279 | (option) == CURLOPT_USERNAME || \ 280 | (option) == CURLOPT_USERPWD || \ 281 | (option) == CURLOPT_XOAUTH2_BEARER || \ 282 | 0) 283 | 284 | /* evaluates to true if option takes a curl_write_callback argument */ 285 | #define _curl_is_write_cb_option(option) \ 286 | ((option) == CURLOPT_HEADERFUNCTION || \ 287 | (option) == CURLOPT_WRITEFUNCTION) 288 | 289 | /* evaluates to true if option takes a curl_conv_callback argument */ 290 | #define _curl_is_conv_cb_option(option) \ 291 | ((option) == CURLOPT_CONV_TO_NETWORK_FUNCTION || \ 292 | (option) == CURLOPT_CONV_FROM_NETWORK_FUNCTION || \ 293 | (option) == CURLOPT_CONV_FROM_UTF8_FUNCTION) 294 | 295 | /* evaluates to true if option takes a data argument to pass to a callback */ 296 | #define _curl_is_cb_data_option(option) \ 297 | ((option) == CURLOPT_CHUNK_DATA || \ 298 | (option) == CURLOPT_CLOSESOCKETDATA || \ 299 | (option) == CURLOPT_DEBUGDATA || \ 300 | (option) == CURLOPT_FNMATCH_DATA || \ 301 | (option) == CURLOPT_HEADERDATA || \ 302 | (option) == CURLOPT_INTERLEAVEDATA || \ 303 | (option) == CURLOPT_IOCTLDATA || \ 304 | (option) == CURLOPT_OPENSOCKETDATA || \ 305 | (option) == CURLOPT_PRIVATE || \ 306 | (option) == CURLOPT_PROGRESSDATA || \ 307 | (option) == CURLOPT_READDATA || \ 308 | (option) == CURLOPT_SEEKDATA || \ 309 | (option) == CURLOPT_SOCKOPTDATA || \ 310 | (option) == CURLOPT_SSH_KEYDATA || \ 311 | (option) == CURLOPT_SSL_CTX_DATA || \ 312 | (option) == CURLOPT_WRITEDATA || \ 313 | 0) 314 | 315 | /* evaluates to true if option takes a POST data argument (void* or char*) */ 316 | #define _curl_is_postfields_option(option) \ 317 | ((option) == CURLOPT_POSTFIELDS || \ 318 | (option) == CURLOPT_COPYPOSTFIELDS || \ 319 | 0) 320 | 321 | /* evaluates to true if option takes a struct curl_slist * argument */ 322 | #define _curl_is_slist_option(option) \ 323 | ((option) == CURLOPT_HTTP200ALIASES || \ 324 | (option) == CURLOPT_HTTPHEADER || \ 325 | (option) == CURLOPT_MAIL_RCPT || \ 326 | (option) == CURLOPT_POSTQUOTE || \ 327 | (option) == CURLOPT_PREQUOTE || \ 328 | (option) == CURLOPT_PROXYHEADER || \ 329 | (option) == CURLOPT_QUOTE || \ 330 | (option) == CURLOPT_RESOLVE || \ 331 | (option) == CURLOPT_TELNETOPTIONS || \ 332 | 0) 333 | 334 | /* groups of curl_easy_getinfo infos that take the same type of argument */ 335 | 336 | /* evaluates to true if info expects a pointer to char * argument */ 337 | #define _curl_is_string_info(info) \ 338 | (CURLINFO_STRING < (info) && (info) < CURLINFO_LONG) 339 | 340 | /* evaluates to true if info expects a pointer to long argument */ 341 | #define _curl_is_long_info(info) \ 342 | (CURLINFO_LONG < (info) && (info) < CURLINFO_DOUBLE) 343 | 344 | /* evaluates to true if info expects a pointer to double argument */ 345 | #define _curl_is_double_info(info) \ 346 | (CURLINFO_DOUBLE < (info) && (info) < CURLINFO_SLIST) 347 | 348 | /* true if info expects a pointer to struct curl_slist * argument */ 349 | #define _curl_is_slist_info(info) \ 350 | (CURLINFO_SLIST < (info)) 351 | 352 | 353 | /* typecheck helpers -- check whether given expression has requested type*/ 354 | 355 | /* For pointers, you can use the _curl_is_ptr/_curl_is_arr macros, 356 | * otherwise define a new macro. Search for __builtin_types_compatible_p 357 | * in the GCC manual. 358 | * NOTE: these macros MUST NOT EVALUATE their arguments! The argument is 359 | * the actual expression passed to the curl_easy_setopt macro. This 360 | * means that you can only apply the sizeof and __typeof__ operators, no 361 | * == or whatsoever. 362 | */ 363 | 364 | /* XXX: should evaluate to true iff expr is a pointer */ 365 | #define _curl_is_any_ptr(expr) \ 366 | (sizeof(expr) == sizeof(void*)) 367 | 368 | /* evaluates to true if expr is NULL */ 369 | /* XXX: must not evaluate expr, so this check is not accurate */ 370 | #define _curl_is_NULL(expr) \ 371 | (__builtin_types_compatible_p(__typeof__(expr), __typeof__(NULL))) 372 | 373 | /* evaluates to true if expr is type*, const type* or NULL */ 374 | #define _curl_is_ptr(expr, type) \ 375 | (_curl_is_NULL(expr) || \ 376 | __builtin_types_compatible_p(__typeof__(expr), type *) || \ 377 | __builtin_types_compatible_p(__typeof__(expr), const type *)) 378 | 379 | /* evaluates to true if expr is one of type[], type*, NULL or const type* */ 380 | #define _curl_is_arr(expr, type) \ 381 | (_curl_is_ptr((expr), type) || \ 382 | __builtin_types_compatible_p(__typeof__(expr), type [])) 383 | 384 | /* evaluates to true if expr is a string */ 385 | #define _curl_is_string(expr) \ 386 | (_curl_is_arr((expr), char) || \ 387 | _curl_is_arr((expr), signed char) || \ 388 | _curl_is_arr((expr), unsigned char)) 389 | 390 | /* evaluates to true if expr is a long (no matter the signedness) 391 | * XXX: for now, int is also accepted (and therefore short and char, which 392 | * are promoted to int when passed to a variadic function) */ 393 | #define _curl_is_long(expr) \ 394 | (__builtin_types_compatible_p(__typeof__(expr), long) || \ 395 | __builtin_types_compatible_p(__typeof__(expr), signed long) || \ 396 | __builtin_types_compatible_p(__typeof__(expr), unsigned long) || \ 397 | __builtin_types_compatible_p(__typeof__(expr), int) || \ 398 | __builtin_types_compatible_p(__typeof__(expr), signed int) || \ 399 | __builtin_types_compatible_p(__typeof__(expr), unsigned int) || \ 400 | __builtin_types_compatible_p(__typeof__(expr), short) || \ 401 | __builtin_types_compatible_p(__typeof__(expr), signed short) || \ 402 | __builtin_types_compatible_p(__typeof__(expr), unsigned short) || \ 403 | __builtin_types_compatible_p(__typeof__(expr), char) || \ 404 | __builtin_types_compatible_p(__typeof__(expr), signed char) || \ 405 | __builtin_types_compatible_p(__typeof__(expr), unsigned char)) 406 | 407 | /* evaluates to true if expr is of type curl_off_t */ 408 | #define _curl_is_off_t(expr) \ 409 | (__builtin_types_compatible_p(__typeof__(expr), curl_off_t)) 410 | 411 | /* evaluates to true if expr is abuffer suitable for CURLOPT_ERRORBUFFER */ 412 | /* XXX: also check size of an char[] array? */ 413 | #define _curl_is_error_buffer(expr) \ 414 | (_curl_is_NULL(expr) || \ 415 | __builtin_types_compatible_p(__typeof__(expr), char *) || \ 416 | __builtin_types_compatible_p(__typeof__(expr), char[])) 417 | 418 | /* evaluates to true if expr is of type (const) void* or (const) FILE* */ 419 | #if 0 420 | #define _curl_is_cb_data(expr) \ 421 | (_curl_is_ptr((expr), void) || \ 422 | _curl_is_ptr((expr), FILE)) 423 | #else /* be less strict */ 424 | #define _curl_is_cb_data(expr) \ 425 | _curl_is_any_ptr(expr) 426 | #endif 427 | 428 | /* evaluates to true if expr is of type FILE* */ 429 | #define _curl_is_FILE(expr) \ 430 | (__builtin_types_compatible_p(__typeof__(expr), FILE *)) 431 | 432 | /* evaluates to true if expr can be passed as POST data (void* or char*) */ 433 | #define _curl_is_postfields(expr) \ 434 | (_curl_is_ptr((expr), void) || \ 435 | _curl_is_arr((expr), char)) 436 | 437 | /* FIXME: the whole callback checking is messy... 438 | * The idea is to tolerate char vs. void and const vs. not const 439 | * pointers in arguments at least 440 | */ 441 | /* helper: __builtin_types_compatible_p distinguishes between functions and 442 | * function pointers, hide it */ 443 | #define _curl_callback_compatible(func, type) \ 444 | (__builtin_types_compatible_p(__typeof__(func), type) || \ 445 | __builtin_types_compatible_p(__typeof__(func), type*)) 446 | 447 | /* evaluates to true if expr is of type curl_read_callback or "similar" */ 448 | #define _curl_is_read_cb(expr) \ 449 | (_curl_is_NULL(expr) || \ 450 | __builtin_types_compatible_p(__typeof__(expr), __typeof__(fread)) || \ 451 | __builtin_types_compatible_p(__typeof__(expr), curl_read_callback) || \ 452 | _curl_callback_compatible((expr), _curl_read_callback1) || \ 453 | _curl_callback_compatible((expr), _curl_read_callback2) || \ 454 | _curl_callback_compatible((expr), _curl_read_callback3) || \ 455 | _curl_callback_compatible((expr), _curl_read_callback4) || \ 456 | _curl_callback_compatible((expr), _curl_read_callback5) || \ 457 | _curl_callback_compatible((expr), _curl_read_callback6)) 458 | typedef size_t (_curl_read_callback1)(char *, size_t, size_t, void*); 459 | typedef size_t (_curl_read_callback2)(char *, size_t, size_t, const void*); 460 | typedef size_t (_curl_read_callback3)(char *, size_t, size_t, FILE*); 461 | typedef size_t (_curl_read_callback4)(void *, size_t, size_t, void*); 462 | typedef size_t (_curl_read_callback5)(void *, size_t, size_t, const void*); 463 | typedef size_t (_curl_read_callback6)(void *, size_t, size_t, FILE*); 464 | 465 | /* evaluates to true if expr is of type curl_write_callback or "similar" */ 466 | #define _curl_is_write_cb(expr) \ 467 | (_curl_is_read_cb(expr) || \ 468 | __builtin_types_compatible_p(__typeof__(expr), __typeof__(fwrite)) || \ 469 | __builtin_types_compatible_p(__typeof__(expr), curl_write_callback) || \ 470 | _curl_callback_compatible((expr), _curl_write_callback1) || \ 471 | _curl_callback_compatible((expr), _curl_write_callback2) || \ 472 | _curl_callback_compatible((expr), _curl_write_callback3) || \ 473 | _curl_callback_compatible((expr), _curl_write_callback4) || \ 474 | _curl_callback_compatible((expr), _curl_write_callback5) || \ 475 | _curl_callback_compatible((expr), _curl_write_callback6)) 476 | typedef size_t (_curl_write_callback1)(const char *, size_t, size_t, void*); 477 | typedef size_t (_curl_write_callback2)(const char *, size_t, size_t, 478 | const void*); 479 | typedef size_t (_curl_write_callback3)(const char *, size_t, size_t, FILE*); 480 | typedef size_t (_curl_write_callback4)(const void *, size_t, size_t, void*); 481 | typedef size_t (_curl_write_callback5)(const void *, size_t, size_t, 482 | const void*); 483 | typedef size_t (_curl_write_callback6)(const void *, size_t, size_t, FILE*); 484 | 485 | /* evaluates to true if expr is of type curl_ioctl_callback or "similar" */ 486 | #define _curl_is_ioctl_cb(expr) \ 487 | (_curl_is_NULL(expr) || \ 488 | __builtin_types_compatible_p(__typeof__(expr), curl_ioctl_callback) || \ 489 | _curl_callback_compatible((expr), _curl_ioctl_callback1) || \ 490 | _curl_callback_compatible((expr), _curl_ioctl_callback2) || \ 491 | _curl_callback_compatible((expr), _curl_ioctl_callback3) || \ 492 | _curl_callback_compatible((expr), _curl_ioctl_callback4)) 493 | typedef curlioerr (_curl_ioctl_callback1)(CURL *, int, void*); 494 | typedef curlioerr (_curl_ioctl_callback2)(CURL *, int, const void*); 495 | typedef curlioerr (_curl_ioctl_callback3)(CURL *, curliocmd, void*); 496 | typedef curlioerr (_curl_ioctl_callback4)(CURL *, curliocmd, const void*); 497 | 498 | /* evaluates to true if expr is of type curl_sockopt_callback or "similar" */ 499 | #define _curl_is_sockopt_cb(expr) \ 500 | (_curl_is_NULL(expr) || \ 501 | __builtin_types_compatible_p(__typeof__(expr), curl_sockopt_callback) || \ 502 | _curl_callback_compatible((expr), _curl_sockopt_callback1) || \ 503 | _curl_callback_compatible((expr), _curl_sockopt_callback2)) 504 | typedef int (_curl_sockopt_callback1)(void *, curl_socket_t, curlsocktype); 505 | typedef int (_curl_sockopt_callback2)(const void *, curl_socket_t, 506 | curlsocktype); 507 | 508 | /* evaluates to true if expr is of type curl_opensocket_callback or 509 | "similar" */ 510 | #define _curl_is_opensocket_cb(expr) \ 511 | (_curl_is_NULL(expr) || \ 512 | __builtin_types_compatible_p(__typeof__(expr), curl_opensocket_callback) ||\ 513 | _curl_callback_compatible((expr), _curl_opensocket_callback1) || \ 514 | _curl_callback_compatible((expr), _curl_opensocket_callback2) || \ 515 | _curl_callback_compatible((expr), _curl_opensocket_callback3) || \ 516 | _curl_callback_compatible((expr), _curl_opensocket_callback4)) 517 | typedef curl_socket_t (_curl_opensocket_callback1) 518 | (void *, curlsocktype, struct curl_sockaddr *); 519 | typedef curl_socket_t (_curl_opensocket_callback2) 520 | (void *, curlsocktype, const struct curl_sockaddr *); 521 | typedef curl_socket_t (_curl_opensocket_callback3) 522 | (const void *, curlsocktype, struct curl_sockaddr *); 523 | typedef curl_socket_t (_curl_opensocket_callback4) 524 | (const void *, curlsocktype, const struct curl_sockaddr *); 525 | 526 | /* evaluates to true if expr is of type curl_progress_callback or "similar" */ 527 | #define _curl_is_progress_cb(expr) \ 528 | (_curl_is_NULL(expr) || \ 529 | __builtin_types_compatible_p(__typeof__(expr), curl_progress_callback) || \ 530 | _curl_callback_compatible((expr), _curl_progress_callback1) || \ 531 | _curl_callback_compatible((expr), _curl_progress_callback2)) 532 | typedef int (_curl_progress_callback1)(void *, 533 | double, double, double, double); 534 | typedef int (_curl_progress_callback2)(const void *, 535 | double, double, double, double); 536 | 537 | /* evaluates to true if expr is of type curl_debug_callback or "similar" */ 538 | #define _curl_is_debug_cb(expr) \ 539 | (_curl_is_NULL(expr) || \ 540 | __builtin_types_compatible_p(__typeof__(expr), curl_debug_callback) || \ 541 | _curl_callback_compatible((expr), _curl_debug_callback1) || \ 542 | _curl_callback_compatible((expr), _curl_debug_callback2) || \ 543 | _curl_callback_compatible((expr), _curl_debug_callback3) || \ 544 | _curl_callback_compatible((expr), _curl_debug_callback4) || \ 545 | _curl_callback_compatible((expr), _curl_debug_callback5) || \ 546 | _curl_callback_compatible((expr), _curl_debug_callback6) || \ 547 | _curl_callback_compatible((expr), _curl_debug_callback7) || \ 548 | _curl_callback_compatible((expr), _curl_debug_callback8)) 549 | typedef int (_curl_debug_callback1) (CURL *, 550 | curl_infotype, char *, size_t, void *); 551 | typedef int (_curl_debug_callback2) (CURL *, 552 | curl_infotype, char *, size_t, const void *); 553 | typedef int (_curl_debug_callback3) (CURL *, 554 | curl_infotype, const char *, size_t, void *); 555 | typedef int (_curl_debug_callback4) (CURL *, 556 | curl_infotype, const char *, size_t, const void *); 557 | typedef int (_curl_debug_callback5) (CURL *, 558 | curl_infotype, unsigned char *, size_t, void *); 559 | typedef int (_curl_debug_callback6) (CURL *, 560 | curl_infotype, unsigned char *, size_t, const void *); 561 | typedef int (_curl_debug_callback7) (CURL *, 562 | curl_infotype, const unsigned char *, size_t, void *); 563 | typedef int (_curl_debug_callback8) (CURL *, 564 | curl_infotype, const unsigned char *, size_t, const void *); 565 | 566 | /* evaluates to true if expr is of type curl_ssl_ctx_callback or "similar" */ 567 | /* this is getting even messier... */ 568 | #define _curl_is_ssl_ctx_cb(expr) \ 569 | (_curl_is_NULL(expr) || \ 570 | __builtin_types_compatible_p(__typeof__(expr), curl_ssl_ctx_callback) || \ 571 | _curl_callback_compatible((expr), _curl_ssl_ctx_callback1) || \ 572 | _curl_callback_compatible((expr), _curl_ssl_ctx_callback2) || \ 573 | _curl_callback_compatible((expr), _curl_ssl_ctx_callback3) || \ 574 | _curl_callback_compatible((expr), _curl_ssl_ctx_callback4) || \ 575 | _curl_callback_compatible((expr), _curl_ssl_ctx_callback5) || \ 576 | _curl_callback_compatible((expr), _curl_ssl_ctx_callback6) || \ 577 | _curl_callback_compatible((expr), _curl_ssl_ctx_callback7) || \ 578 | _curl_callback_compatible((expr), _curl_ssl_ctx_callback8)) 579 | typedef CURLcode (_curl_ssl_ctx_callback1)(CURL *, void *, void *); 580 | typedef CURLcode (_curl_ssl_ctx_callback2)(CURL *, void *, const void *); 581 | typedef CURLcode (_curl_ssl_ctx_callback3)(CURL *, const void *, void *); 582 | typedef CURLcode (_curl_ssl_ctx_callback4)(CURL *, const void *, const void *); 583 | #ifdef HEADER_SSL_H 584 | /* hack: if we included OpenSSL's ssl.h, we know about SSL_CTX 585 | * this will of course break if we're included before OpenSSL headers... 586 | */ 587 | typedef CURLcode (_curl_ssl_ctx_callback5)(CURL *, SSL_CTX, void *); 588 | typedef CURLcode (_curl_ssl_ctx_callback6)(CURL *, SSL_CTX, const void *); 589 | typedef CURLcode (_curl_ssl_ctx_callback7)(CURL *, const SSL_CTX, void *); 590 | typedef CURLcode (_curl_ssl_ctx_callback8)(CURL *, const SSL_CTX, 591 | const void *); 592 | #else 593 | typedef _curl_ssl_ctx_callback1 _curl_ssl_ctx_callback5; 594 | typedef _curl_ssl_ctx_callback1 _curl_ssl_ctx_callback6; 595 | typedef _curl_ssl_ctx_callback1 _curl_ssl_ctx_callback7; 596 | typedef _curl_ssl_ctx_callback1 _curl_ssl_ctx_callback8; 597 | #endif 598 | 599 | /* evaluates to true if expr is of type curl_conv_callback or "similar" */ 600 | #define _curl_is_conv_cb(expr) \ 601 | (_curl_is_NULL(expr) || \ 602 | __builtin_types_compatible_p(__typeof__(expr), curl_conv_callback) || \ 603 | _curl_callback_compatible((expr), _curl_conv_callback1) || \ 604 | _curl_callback_compatible((expr), _curl_conv_callback2) || \ 605 | _curl_callback_compatible((expr), _curl_conv_callback3) || \ 606 | _curl_callback_compatible((expr), _curl_conv_callback4)) 607 | typedef CURLcode (*_curl_conv_callback1)(char *, size_t length); 608 | typedef CURLcode (*_curl_conv_callback2)(const char *, size_t length); 609 | typedef CURLcode (*_curl_conv_callback3)(void *, size_t length); 610 | typedef CURLcode (*_curl_conv_callback4)(const void *, size_t length); 611 | 612 | /* evaluates to true if expr is of type curl_seek_callback or "similar" */ 613 | #define _curl_is_seek_cb(expr) \ 614 | (_curl_is_NULL(expr) || \ 615 | __builtin_types_compatible_p(__typeof__(expr), curl_seek_callback) || \ 616 | _curl_callback_compatible((expr), _curl_seek_callback1) || \ 617 | _curl_callback_compatible((expr), _curl_seek_callback2)) 618 | typedef CURLcode (*_curl_seek_callback1)(void *, curl_off_t, int); 619 | typedef CURLcode (*_curl_seek_callback2)(const void *, curl_off_t, int); 620 | 621 | 622 | #endif /* __CURL_TYPECHECK_GCC_H */ 623 | -------------------------------------------------------------------------------- /minihttp.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio 2013 4 | VisualStudioVersion = 12.0.21005.1 5 | MinimumVisualStudioVersion = 10.0.40219.1 6 | Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "minihttp", "minihttp\minihttp.vcxproj", "{3046249E-24CF-4AA1-9BBE-6A69F782D744}" 7 | EndProject 8 | Global 9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 10 | Debug|Win32 = Debug|Win32 11 | Release|Win32 = Release|Win32 12 | EndGlobalSection 13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 14 | {3046249E-24CF-4AA1-9BBE-6A69F782D744}.Debug|Win32.ActiveCfg = Debug|Win32 15 | {3046249E-24CF-4AA1-9BBE-6A69F782D744}.Debug|Win32.Build.0 = Debug|Win32 16 | {3046249E-24CF-4AA1-9BBE-6A69F782D744}.Release|Win32.ActiveCfg = Release|Win32 17 | {3046249E-24CF-4AA1-9BBE-6A69F782D744}.Release|Win32.Build.0 = Release|Win32 18 | EndGlobalSection 19 | GlobalSection(SolutionProperties) = preSolution 20 | HideSolutionNode = FALSE 21 | EndGlobalSection 22 | EndGlobal 23 | -------------------------------------------------------------------------------- /minihttp/CMiniHttp.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anhkgg/minihttp/1631b881b0a6da933a8ae29faf08f4cf753c1337/minihttp/CMiniHttp.cpp -------------------------------------------------------------------------------- /minihttp/CMiniHttp.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anhkgg/minihttp/1631b881b0a6da933a8ae29faf08f4cf753c1337/minihttp/CMiniHttp.h -------------------------------------------------------------------------------- /minihttp/ReadMe.txt: -------------------------------------------------------------------------------- 1 | ======================================================================== 2 | 静态库:minihttp 项目概述 3 | ======================================================================== 4 | 5 | 应用程序向导已为您创建了此 minihttp 库项目。 6 | 7 | 没有为此项目创建源文件。 8 | 9 | 10 | minihttp.vcxproj 11 | 这是使用应用程序向导生成的 VC++ 项目的主项目文件,其中包含生成该文件的 Visual C++ 的版本信息,以及有关使用应用程序向导选择的平台、配置和项目功能的信息。 12 | 13 | minihttp.vcxproj.filters 14 | 这是使用“应用程序向导”生成的 VC++ 项目筛选器文件。它包含有关项目文件与筛选器之间的关联信息。在 IDE 中,通过这种关联,在特定节点下以分组形式显示具有相似扩展名的文件。例如,“.cpp”文件与“源文件”筛选器关联。 15 | 16 | ///////////////////////////////////////////////////////////////////////////// 17 | 其他注释: 18 | 19 | 应用程序向导使用“TODO:”注释来指示应添加或自定义的源代码部分。 20 | 21 | ///////////////////////////////////////////////////////////////////////////// 22 | -------------------------------------------------------------------------------- /minihttp/minihttp.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anhkgg/minihttp/1631b881b0a6da933a8ae29faf08f4cf753c1337/minihttp/minihttp.cpp -------------------------------------------------------------------------------- /minihttp/minihttp.vcxproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | Debug 6 | Win32 7 | 8 | 9 | Release 10 | Win32 11 | 12 | 13 | 14 | {3046249E-24CF-4AA1-9BBE-6A69F782D744} 15 | Win32Proj 16 | minihttp 17 | 10.0.17134.0 18 | 19 | 20 | 21 | Application 22 | true 23 | v141 24 | Unicode 25 | false 26 | 27 | 28 | Application 29 | false 30 | v141 31 | true 32 | Unicode 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | Level3 50 | Disabled 51 | WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions) 52 | 53 | 54 | Console 55 | true 56 | %(AdditionalDependencies) 57 | 58 | 59 | 60 | 61 | Level3 62 | 63 | 64 | MaxSpeed 65 | true 66 | true 67 | WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions) 68 | 69 | 70 | Console 71 | true 72 | true 73 | true 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | -------------------------------------------------------------------------------- /minihttp/minihttp.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {4FC737F1-C7A5-4376-A066-2A32D752A2FF} 6 | cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx 7 | 8 | 9 | {93995380-89BD-4b04-88EB-625FBE52EBFB} 10 | h;hh;hpp;hxx;hm;inl;inc;xsd 11 | 12 | 13 | {67DA6AB6-F800-4c08-8B7A-83BB121AAD01} 14 | rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 源文件 23 | 24 | 25 | 源文件 26 | 27 | 28 | 29 | 30 | 头文件 31 | 32 | 33 | 头文件 34 | 35 | 36 | -------------------------------------------------------------------------------- /minihttp/stdafx.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | --------------------------------------------------------------------------------