[0] | 1 | //libroar.h: |
---|
| 2 | |
---|
[690] | 3 | /* |
---|
[3110] | 4 | * Copyright (C) Philipp 'ph3-der-loewe' Schafft - 2008, 2009, 2010 |
---|
[690] | 5 | * |
---|
| 6 | * This file is part of libroar a part of RoarAudio, |
---|
| 7 | * a cross-platform sound system for both, home and professional use. |
---|
| 8 | * See README for details. |
---|
| 9 | * |
---|
| 10 | * This file is free software; you can redistribute it and/or modify |
---|
| 11 | * it under the terms of the GNU General Public License version 3 |
---|
| 12 | * as published by the Free Software Foundation. |
---|
| 13 | * |
---|
| 14 | * libroar is distributed in the hope that it will be useful, |
---|
| 15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
| 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
---|
| 17 | * GNU General Public License for more details. |
---|
| 18 | * |
---|
| 19 | * You should have received a copy of the GNU General Public License |
---|
| 20 | * along with this software; see the file COPYING. If not, write to |
---|
[3517] | 21 | * the Free Software Foundation, 51 Franklin Street, Fifth Floor, |
---|
| 22 | * Boston, MA 02110-1301, USA. |
---|
[690] | 23 | * |
---|
| 24 | * NOTE for everyone want's to change something and send patches: |
---|
| 25 | * read README and HACKING! There a addition information on |
---|
| 26 | * the license of this document you need to read before you send |
---|
| 27 | * any patches. |
---|
| 28 | * |
---|
| 29 | * NOTE for uses of non-GPL (LGPL,...) software using libesd, libartsc |
---|
| 30 | * or libpulse*: |
---|
| 31 | * The libs libroaresd, libroararts and libroarpulse link this lib |
---|
| 32 | * and are therefore GPL. Because of this it may be illigal to use |
---|
| 33 | * them with any software that uses libesd, libartsc or libpulse*. |
---|
| 34 | */ |
---|
| 35 | |
---|
[0] | 36 | #ifndef _LIBROAR_H_ |
---|
| 37 | #define _LIBROAR_H_ |
---|
| 38 | |
---|
[4299] | 39 | //#define ROAR_DBG_PREFIX "libroar" |
---|
[0] | 40 | |
---|
[474] | 41 | #include <roaraudio.h> |
---|
| 42 | |
---|
[1351] | 43 | #include <stdarg.h> |
---|
| 44 | |
---|
[1386] | 45 | #ifdef ROAR_HAVE_WAIT |
---|
[1254] | 46 | #include <sys/wait.h> |
---|
[1386] | 47 | #endif |
---|
[1254] | 48 | |
---|
[1425] | 49 | #ifdef ROAR_HAVE_H_FCNTL |
---|
[0] | 50 | #include <fcntl.h> |
---|
[1425] | 51 | #endif |
---|
[1374] | 52 | |
---|
[3056] | 53 | #ifdef ROAR_HAVE_H_SIGNAL |
---|
[1418] | 54 | #include <signal.h> |
---|
| 55 | #endif |
---|
| 56 | |
---|
[3611] | 57 | #ifdef ROAR_HAVE_SYSLOG |
---|
| 58 | #include <syslog.h> |
---|
| 59 | #endif |
---|
| 60 | |
---|
[1374] | 61 | #ifdef ROAR_HAVE_BSDSOCKETS |
---|
| 62 | |
---|
[1075] | 63 | #ifndef ROAR_TARGET_WIN32 |
---|
[322] | 64 | #include <sys/socket.h> |
---|
[1374] | 65 | #ifdef ROAR_HAVE_IPV4 |
---|
[726] | 66 | #include <netinet/in_systm.h> |
---|
[322] | 67 | #include <netinet/in.h> |
---|
| 68 | #include <netinet/ip.h> |
---|
[1374] | 69 | #endif |
---|
[902] | 70 | #include <sys/uio.h> |
---|
[3805] | 71 | |
---|
| 72 | #ifdef ROAR_HAVE_UNIX |
---|
| 73 | #include <sys/un.h> |
---|
[1075] | 74 | #endif |
---|
[3805] | 75 | #endif |
---|
| 76 | |
---|
[501] | 77 | #ifdef ROAR_HAVE_LIBDNET |
---|
| 78 | #include <netdnet/dn.h> |
---|
| 79 | #include <netdnet/dnetdb.h> |
---|
| 80 | #endif |
---|
[3805] | 81 | |
---|
[529] | 82 | #ifdef ROAR_HAVE_IPX |
---|
[528] | 83 | #include <netipx/ipx.h> |
---|
| 84 | #endif |
---|
[0] | 85 | |
---|
[1374] | 86 | #endif /* ROAR_HAVE_BSDSOCKETS */ |
---|
| 87 | |
---|
[1322] | 88 | #ifdef ROAR_HAVE_LIBSSL |
---|
| 89 | #include <openssl/bio.h> |
---|
| 90 | #include <openssl/evp.h> |
---|
| 91 | #endif |
---|
| 92 | |
---|
[1996] | 93 | #ifdef ROAR_HAVE_LIBSLP |
---|
| 94 | #include <slp.h> |
---|
[3203] | 95 | #ifdef ROAR_HAVE_H_SYS_TIME |
---|
| 96 | #include <sys/time.h> |
---|
| 97 | #endif |
---|
| 98 | #ifdef ROAR_HAVE_H_TIME |
---|
| 99 | #include <time.h> |
---|
| 100 | #endif |
---|
[1996] | 101 | #endif |
---|
| 102 | |
---|
[3297] | 103 | #if defined(ROAR_HAVE_LIBDL) |
---|
| 104 | #include <dlfcn.h> |
---|
| 105 | #endif |
---|
| 106 | |
---|
[3371] | 107 | #ifdef ROAR_HAVE_LIBX11 |
---|
| 108 | #include <X11/Xlib.h> |
---|
| 109 | #include <X11/Xatom.h> |
---|
| 110 | #endif |
---|
| 111 | |
---|
[797] | 112 | #include "error.h" |
---|
[2477] | 113 | #include "config.h" |
---|
[3376] | 114 | #include "keyval.h" |
---|
[3958] | 115 | #include "env.h" |
---|
[3297] | 116 | #include "roardl.h" |
---|
[2648] | 117 | #include "debug.h" |
---|
[2976] | 118 | #include "memmgr.h" |
---|
[1280] | 119 | #include "stack.h" |
---|
[1297] | 120 | #include "buffer.h" |
---|
[2812] | 121 | #include "nnode.h" |
---|
[2058] | 122 | #include "vio_ctl.h" |
---|
[588] | 123 | #include "vio.h" |
---|
[3969] | 124 | #include "vio_buffer.h" |
---|
[3994] | 125 | #include "vio_buffer_store.h" |
---|
[1255] | 126 | #include "vio_cmd.h" |
---|
[1274] | 127 | #include "vio_ops.h" |
---|
[2060] | 128 | #include "vio_string.h" |
---|
[1274] | 129 | #include "vio_magic.h" |
---|
[1347] | 130 | #include "vio_bio.h" |
---|
[2059] | 131 | #include "vio_stdio.h" |
---|
[1347] | 132 | #include "vio_stack.h" |
---|
[2981] | 133 | #include "vio_jumbo.h" |
---|
[1300] | 134 | #include "vio_pipe.h" |
---|
[1331] | 135 | #include "vio_socket.h" |
---|
[3315] | 136 | #include "vio_winsock.h" |
---|
[1347] | 137 | #include "vio_proto.h" |
---|
[3272] | 138 | #include "vio_rtp.h" |
---|
[1506] | 139 | #include "vio_select.h" |
---|
[1326] | 140 | // dstr needs to have access to all other VIOs, so it must be included last |
---|
[1321] | 141 | #include "vio_dstr.h" |
---|
[3109] | 142 | #include "vio_tantalos.h" |
---|
[2812] | 143 | #include "client.h" |
---|
[0] | 144 | #include "basic.h" |
---|
| 145 | #include "stream.h" |
---|
| 146 | #include "simple.h" |
---|
[808] | 147 | #include "cdrom.h" |
---|
[0] | 148 | #include "auth.h" |
---|
| 149 | #include "socket.h" |
---|
| 150 | #include "ctl.h" |
---|
[94] | 151 | #include "meta.h" |
---|
[320] | 152 | #include "file.h" |
---|
[347] | 153 | #include "acl.h" |
---|
[1232] | 154 | #include "pinentry.h" |
---|
[1288] | 155 | #include "sshaskpass.h" |
---|
[2000] | 156 | #include "roarslp.h" |
---|
[3632] | 157 | #include "display.h" |
---|
[3370] | 158 | #include "roarx11.h" |
---|
[3567] | 159 | #include "beep.h" |
---|
[4263] | 160 | #include "ltm.h" |
---|
[4172] | 161 | #include "vs.h" |
---|
[4300] | 162 | #include "enumdev.h" |
---|
[4302] | 163 | #include "notify.h" |
---|
[4314] | 164 | #include "notify_proxy.h" |
---|
[4341] | 165 | #include "asyncctl.h" |
---|
[0] | 166 | |
---|
[2067] | 167 | // some basic macros: |
---|
| 168 | #define ROAR_MAX2(a,b) ((a) > (b) ? (a) : (b)) |
---|
| 169 | #define ROAR_MIN2(a,b) ((a) < (b) ? (a) : (b)) |
---|
| 170 | |
---|
| 171 | #define ROAR_MAX3(a,b,c) ROAR_MAX2(ROAR_MAX2(a,b),c) |
---|
| 172 | #define ROAR_MIN3(a,b,c) ROAR_MIN2(ROAR_MIN2(a,b),c) |
---|
| 173 | |
---|
| 174 | #define ROAR_MAX4(a,b,c,d) ROAR_MAX2(ROAR_MAX2(a,b),ROAR_MAX2(c,d)) |
---|
| 175 | #define ROAR_MIN4(a,b,c,d) ROAR_MIN2(ROAR_MIN2(a,b),ROAR_MIN2(c,d)) |
---|
| 176 | |
---|
| 177 | #define ROAR_MAX ROAR_MAX2 |
---|
| 178 | #define ROAR_MIN ROAR_MIN2 |
---|
| 179 | |
---|
[0] | 180 | #endif |
---|
| 181 | |
---|
| 182 | //ll |
---|