diff options
author | Curl Upstream <curl-library@cool.haxx.se> | 2014-09-10 06:07:58 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2014-10-08 19:53:25 (GMT) |
commit | 3fe5d9bff98b4716e219516c30d71462495324f4 (patch) | |
tree | cd369c3f671882cefde2f68a1ac8146f97c6bc84 /lib/amigaos.c | |
parent | f086cb372e41035260fcd9b4ed3d2cfb272f138f (diff) | |
download | CMake-3fe5d9bff98b4716e219516c30d71462495324f4.zip CMake-3fe5d9bff98b4716e219516c30d71462495324f4.tar.gz CMake-3fe5d9bff98b4716e219516c30d71462495324f4.tar.bz2 |
curl 7.38.0 (reduced)
Extract upstream curl using the following shell code.
url=git://github.com/bagder/curl.git &&
v=7.38.0 &&
r=202aa9f7 &&
paths="
CMake/*
CMakeLists.txt
COPYING
include/curl/*.h
include/curl/curlbuild.h.cmake
lib/*.c
lib/*.h
lib/CMakeLists.txt
lib/Makefile.inc
lib/curl_config.h.cmake
lib/libcurl.rc
lib/vtls/*.c
lib/vtls/*.h
" &&
mkdir curl-$v-g$r-reduced &&
git clone $url curl-git &&
date=$(cd curl-git && git log -n 1 --format='%cd' $r) &&
(cd curl-git && git checkout $r &&
git archive --format=tar $r -- $paths) |
(cd curl-$v-g$r-reduced && tar xv &&
rm lib/config-*.h) &&
echo "g$r date: $date"
Diffstat (limited to 'lib/amigaos.c')
-rw-r--r-- | lib/amigaos.c | 67 |
1 files changed, 35 insertions, 32 deletions
diff --git a/lib/amigaos.c b/lib/amigaos.c index e26119b..34f95e9 100644 --- a/lib/amigaos.c +++ b/lib/amigaos.c @@ -5,7 +5,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 1998 - 2005, Daniel Stenberg, <daniel@haxx.se>, et al. + * Copyright (C) 1998 - 2012, Daniel Stenberg, <daniel@haxx.se>, et al. * * This software is licensed as described in the file COPYING, which * you should have received as part of this distribution. The terms @@ -18,12 +18,16 @@ * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY * KIND, either express or implied. * - * $Id$ ***************************************************************************/ -#include "amigaos.h" +#include "curl_setup.h" + +#if defined(__AMIGA__) && !defined(__ixemul__) + #include <amitcp/socketbasetags.h> +#include "amigaos.h" + struct Library *SocketBase = NULL; extern int errno, h_errno; @@ -31,44 +35,43 @@ extern int errno, h_errno; #include <stabs.h> void __request(const char *msg); #else -# define __request( msg ) Printf( msg "\n\a") +# define __request( msg ) Printf( msg "\n\a") #endif -void amiga_cleanup() +void Curl_amiga_cleanup() { - if(SocketBase) { - CloseLibrary(SocketBase); - SocketBase = NULL; - } + if(SocketBase) { + CloseLibrary(SocketBase); + SocketBase = NULL; + } } -BOOL amiga_init() +bool Curl_amiga_init() { - if(!SocketBase) - SocketBase = OpenLibrary("bsdsocket.library", 4); - - if(!SocketBase) { - __request("No TCP/IP Stack running!"); - return FALSE; - } - - if(SocketBaseTags( - SBTM_SETVAL(SBTC_ERRNOPTR(sizeof(errno))), (ULONG) &errno, -// SBTM_SETVAL(SBTC_HERRNOLONGPTR), (ULONG) &h_errno, - SBTM_SETVAL(SBTC_LOGTAGPTR), (ULONG) "cURL", - TAG_DONE)) { - - __request("SocketBaseTags ERROR"); - return FALSE; - } - + if(!SocketBase) + SocketBase = OpenLibrary("bsdsocket.library", 4); + + if(!SocketBase) { + __request("No TCP/IP Stack running!"); + return FALSE; + } + + if(SocketBaseTags(SBTM_SETVAL(SBTC_ERRNOPTR(sizeof(errno))), (ULONG) &errno, + SBTM_SETVAL(SBTC_LOGTAGPTR), (ULONG) "cURL", + TAG_DONE)) { + __request("SocketBaseTags ERROR"); + return FALSE; + } + #ifndef __libnix__ - atexit(amiga_cleanup); + atexit(Curl_amiga_cleanup); #endif - - return TRUE; + + return TRUE; } #ifdef __libnix__ -ADD2EXIT(amiga_cleanup,-50); +ADD2EXIT(Curl_amiga_cleanup,-50); #endif + +#endif /* __AMIGA__ && ! __ixemul__ */ |