1 /***************************************************************************
3 * Project ___| | | | _ \| |
5 * | (__| |_| | _ <| |___
6 * \___|\___/|_| \_\_____|
8 * Copyright (C) 1998 - 2007, Daniel Stenberg, <daniel@haxx.se>, et al.
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 http://curl.haxx.se/docs/copyright.html.
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.
18 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
19 * KIND, either express or implied.
21 * $Id: amigaos.c,v 1.1.1.1 2008-09-23 16:32:05 hoffman Exp $
22 ***************************************************************************/
24 #ifdef __AMIGA__ /* Any AmigaOS flavour */
27 #include <amitcp/socketbasetags.h>
29 struct Library
*SocketBase
= NULL
;
30 extern int errno
, h_errno
;
34 void __request(const char *msg
);
36 # define __request( msg ) Printf( msg "\n\a")
42 CloseLibrary(SocketBase
);
50 SocketBase
= OpenLibrary("bsdsocket.library", 4);
53 __request("No TCP/IP Stack running!");
58 SBTM_SETVAL(SBTC_ERRNOPTR(sizeof(errno
))), (ULONG
) &errno
,
59 // SBTM_SETVAL(SBTC_HERRNOLONGPTR), (ULONG) &h_errno,
60 SBTM_SETVAL(SBTC_LOGTAGPTR
), (ULONG
) "cURL",
63 __request("SocketBaseTags ERROR");
68 atexit(amiga_cleanup
);
75 ADD2EXIT(amiga_cleanup
,-50);
78 #endif /* __AMIGA__ */