| 1 |
/* $Id: misc.h,v 1.3 1999/03/10 07:58:03 boyns Exp $ */ |
| 2 |
|
| 3 |
/* |
| 4 |
* Copyright (C) 1993-99 Mark R. Boyns <[email protected]> |
| 5 |
* |
| 6 |
* This file is part of rplay. |
| 7 |
* |
| 8 |
* rplay is free software; you can redistribute it and/or modify |
| 9 |
* it under the terms of the GNU General Public License as published by |
| 10 |
* the Free Software Foundation; either version 2 of the License, or |
| 11 |
* (at your option) any later version. |
| 12 |
* |
| 13 |
* rplay is distributed in the hope that it will be useful, |
| 14 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 15 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 16 |
* GNU General Public License for more details. |
| 17 |
* |
| 18 |
* You should have received a copy of the GNU General Public License |
| 19 |
* along with rplay; see the file COPYING. If not, write to the |
| 20 |
* Free Software Foundation, Inc., |
| 21 |
* 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. |
| 22 |
*/ |
| 23 |
|
| 24 |
|
| 25 |
|
| 26 |
#ifndef _misc_h |
| 27 |
#define _misc_h |
| 28 |
|
| 29 |
#ifdef HAVE_CONFIG_H |
| 30 |
#include "config.h" |
| 31 |
#endif |
| 32 |
#include <sys/types.h> |
| 33 |
|
| 34 |
#ifdef __STDC__ |
| 35 |
extern char *sys_err_str (int error); |
| 36 |
extern int udp_socket (int port); |
| 37 |
extern int tcp_socket (int port); |
| 38 |
extern void fd_nonblock (int fd); |
| 39 |
extern void fd_block (int fd); |
| 40 |
extern int modified (char *filename, time_t since); |
| 41 |
extern char *time2string (time_t t); |
| 42 |
extern int string_to_audio_format (char *string); |
| 43 |
extern char *audio_format_to_string (int format); |
| 44 |
extern int string_to_byte_order (char *string); |
| 45 |
extern char *byte_order_to_string (int byte_order); |
| 46 |
extern int string_to_storage (char *string); |
| 47 |
extern char *storage_to_string (int storage); |
| 48 |
extern int string_to_input (char *string); |
| 49 |
extern char *input_to_string (int input); |
| 50 |
extern char *audio_port_to_string (int port); |
| 51 |
#else |
| 52 |
extern char *sys_err_str ( /* int error */ ); |
| 53 |
extern int udp_socket ( /* int port */ ); |
| 54 |
extern int tcp_socket ( /* int port */ ); |
| 55 |
extern void fd_nonblock ( /* int fd */ ); |
| 56 |
extern void fd_block ( /* int fd */ ); |
| 57 |
extern int modified ( /* char *filename, time_t since */ ); |
| 58 |
extern char *time2string ( /* time_t t */ ); |
| 59 |
extern int string_to_audio_format ( /* char *string */ ); |
| 60 |
extern char *audio_format_to_string ( /* int format */ ); |
| 61 |
extern int string_to_byte_order ( /* char *string */ ); |
| 62 |
extern char *byte_order_to_string ( /* int byte_order */ ); |
| 63 |
extern int string_to_storage ( /* char *string */ ); |
| 64 |
extern char *storage_to_string ( /* int storage */ ); |
| 65 |
extern int string_to_input ( /* char *string */ ); |
| 66 |
extern char *input_to_string ( /* int input */ ); |
| 67 |
extern char *audio_port_to_string ( /* int port */ ); |
| 68 |
#endif |
| 69 |
|
| 70 |
unsigned short little_short ( /* char *p */ ); |
| 71 |
unsigned short big_short ( /* char *p */ ); |
| 72 |
unsigned long little_long ( /* char *p */ ); |
| 73 |
unsigned long big_long ( /* char *p */ ); |
| 74 |
double ConvertFromIeeeExtended ( /* unsigned char *bytes */ ); |
| 75 |
|
| 76 |
#endif /* _misc_h */ |