1 /*         ______   ___    ___
2  *        /\  _  \ /\_ \  /\_ \
3  *        \ \ \L\ \\//\ \ \//\ \      __     __   _ __   ___
4  *         \ \  __ \ \ \ \  \ \ \   /'__`\ /'_ `\/\`'__\/ __`\
5  *          \ \ \/\ \ \_\ \_ \_\ \_/\  __//\ \L\ \ \ \//\ \L\ \
6  *           \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/
7  *            \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/
8  *                                           /\____/
9  *                                           \_/__/
10  *
11  *      Some definitions for internal use by the Unix library code.
12  *
13  *      By Shawn Hargreaves.
14  *
15  *      See readme.txt for copyright information.
16  */
17 
18 #ifndef __al_included_allegro5_aintunix_h
19 #define __al_included_allegro5_aintunix_h
20 
21 #include "allegro5/altime.h"
22 #include "allegro5/path.h"
23 #include "allegro5/internal/aintern_driver.h"
24 
25 /* Need right now for XKeyEvent --pw */
26 #ifdef ALLEGRO_WITH_XWINDOWS
27 #include <X11/Xlib.h>
28 #endif
29 
30 #ifdef __cplusplus
31 extern "C" {
32 #endif
33 
34 ALLEGRO_PATH *_al_unix_get_path(int id);
35 double _al_unix_get_time(void);
36 void _al_unix_rest(double seconds);
37 void _al_unix_init_timeout(ALLEGRO_TIMEOUT *timeout, double seconds);
38 
39 
40 #ifdef __cplusplus
41 }
42 #endif
43 
44 
45 #ifdef ALLEGRO_LINUX
46    #include "allegro5/platform/aintlnx.h"
47 #endif
48 
49 
50 
51 /*----------------------------------------------------------------------*
52  *									*
53  *	New stuff							*
54  *									*
55  *----------------------------------------------------------------------*/
56 
57 /* TODO: integrate this above */
58 
59 #include "allegro5/platform/aintuthr.h"
60 
61 
62 #ifdef __cplusplus
63    extern "C" {
64 #endif
65 
66 /* time */
67 void _al_unix_init_time(void);
68 
69 /* fdwatch */
70 void _al_unix_start_watching_fd(int fd, void (*callback)(void *), void *cb_data);
71 void _al_unix_stop_watching_fd(int fd);
72 
73 /* ljoynu.c */
74 /* This isn't in aintlnx.h because it's needed for the X11 port as well. */
75 #define _ALLEGRO_JOYDRV_LINUX    AL_ID('L','N','X','A')
76 
77 #ifdef ALLEGRO_HAVE_LINUX_INPUT_H
78 AL_VAR(struct ALLEGRO_JOYSTICK_DRIVER, _al_joydrv_linux);
79 #endif
80 
81 /* lhaptic.c */
82 /* This isn't in aintlnx.h because it's needed for the X11 port as well. */
83 #define _ALLEGRO_HAPDRV_LINUX    AL_ID('L','N','X','H')
84 
85 #ifdef ALLEGRO_HAVE_LINUX_INPUT_H
86 AL_VAR(struct ALLEGRO_HAPTIC_DRIVER, _al_hapdrv_linux);
87 #endif
88 
89 
90 #ifdef __cplusplus
91    }
92 #endif
93 
94 
95 #endif
96