KCompactDisc

wm_config.h
1#ifndef WM_CONFIG_H
2#define WM_CONFIG_H
3/*
4 * This file is part of WorkMan, the civilized CD player library
5 * Copyright (C) 1991-1997 by Steven Grimm <koreth@midwinter.com>
6 * Copyright (C) by Dirk Försterling <milliByte@DeathsDoor.com>
7 *
8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either
11 * version 2 of the License, or (at your option) any later version.
12 *
13 * This library 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 GNU
16 * Library General Public License for more details.
17 *
18 * You should have received a copy of the GNU Library General Public
19 * License along with this library; if not, write to the Free
20 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
21 *
22 **********************************************************************
23 *
24 * This file consists of several parts. First, there's a generic,
25 * platform independent part. Set needed options there.
26 * The following parts are platform dependent. You may search for the
27 * names listed below and then set your OS specific options there.
28 * Don't be surprised, if there are no options for your OS. They aren't
29 * needed in any case.
30 *
31 * The default values should produce a functional WorkMan on every
32 * platform.
33 *
34 *********************
35 * Current platforms:
36 *********************
37 * BSD386
38 * FreeBSD
39 * HP-UX
40 * Irix (SGI)
41 * Linux
42 * News (Sony NewsOS)
43 * OpenBSD
44 * OSF1
45 * Sun (SunOS/Solaris, Sparc or x86)
46 * SVR4
47 * Ultrix
48 * AIX
49 *
50 * The above order corresponds with the order of the platform specific
51 * options below.
52 */
53
54/******************************************************************
55 * generic options
56 ******************************************************************
57 ** ** *** **** ** **** ** * ** ** ** * **
58 * * * *** **** * * *** * ** ** *** * * * * * * **
59 * * *** **** ** *** ** ** ** * * ** * * **
60 * * * *** **** **** *** * ** ** *** * * * * *** **
61 * * * * ** **** * * ** ** **** ** * * *** **
62 ******************************************************************/
63
64/*
65 * If your CD-ROM drive closes its tray if the device is opened, then
66 * the next define can make WorkMans "Eject" button an "open/close"
67 * button. If it disturbs you, just comment it out.
68 *
69 * ### this is preliminary. It may have no effect for you ###
70 */
71#define CAN_CLOSE 1
72
73/*
74 * Define the following if you want the balance slider to
75 * decrease one channel's volume while increasing the other's
76 */
77/* #define SYMETRIC_BALANCE 1 */
78
79
80/******************************************************************
81 * BSD386
82 ******************************************************************
83 *** **** *** ******* ** **** **** ************
84 *** ** ** ****** * ***** ****** ** ** ** ***************
85 *** ****** **** ** *** ***** ***** *** ************
86 *** ** ****** ** * *** ******** ** ** ** ** ***********
87 *** **** *** *** ****** **** **** ************
88 ******************************************************************/
89#if defined(__bsdi__) || defined(__bsdi)
90
91/*
92 * This lets you use the SoundBlaster Mixer on BSD/386
93 */
94#define SOUNDBLASTER 1
95
96#define DEFAULT_CD_DEVICE "/dev/rsr2c"
97
98#endif /* __bsdi__ (BSD/386) */
99
100/******************************************************************
101 * FreeBSD
102 ******************************************************************
103 *** ** *** ** ** **** *** ***********
104 *** ****** ** ** ****** ****** ** ** ****** * **********
105 *** **** *** **** **** ****** **** ** *********
106 *** ****** ** ** ****** ****** ** ****** ** * **********
107 *** ****** ** ** ** ** **** *** ***********
108 ******************************************************************/
109#if defined(__FreeBSD__) || defined(__FreeBSD) || defined(__DragonFly__) || defined(__FreeBSD_kernel__)
110
111#if (defined(__FreeBSD_version) && __FreeBSD_version >= 500100) || defined(__DragonFly__) || defined(__FreeBSD_kernel__)
112#define DEFAULT_CD_DEVICE "/dev/acd0"
113#else
114#define DEFAULT_CD_DEVICE "/dev/acd0c"
115#endif
116
117#endif /* freebsd */
118
119#if defined(__OpenBSD__)
120#define DEFAULT_CD_DEVICE find_cdrom()
121#endif
122
123/******************************************************************
124 * NetBSD
125 ******************************************************************
126 *** *** ** ** ** **** *** *****************
127 *** ** ** ******** **** ** ** ****** * ****************
128 *** * * ** ****** **** ****** **** ** ***************
129 *** ** ** ******** **** ** ****** ** * ****************
130 *** *** ** **** **** **** *** *****************
131 ******************************************************************/
132#if defined(__NetBSD__) || defined(__NetBSD)
133
134#if defined(__i386__)
135 #define DEFAULT_CD_DEVICE "/dev/rcd0d"
136#else
137 #define DEFAULT_CD_DEVICE "/dev/rcd0c"
138#endif
139
140#endif /* netbsd */
141
142/******************************************************************
143 * HP-UX
144 ******************************************************************
145 *** ** ** ********* ** ** ** ***************************
146 *** ** ** ** ******** ** *** ****************************
147 *** ** *** ** ** **** *****************************
148 *** ** ** ************ ** *** ****************************
149 *** ** ** ************* *** ** ***************************
150 ******************************************************************/
151#if defined(hpux) || defined (__hpux)
152
153#define DEFAULT_CD_DEVICE "/dev/rscsi"
154
155#endif /* hpux */
156
157/******************************************************************
158 * Irix
159 ******************************************************************
160 *** ** *** ** ** *********************************
161 ***** **** ** **** ***** **********************************
162 ***** **** ***** ****** ***********************************
163 ***** **** ** **** ***** **********************************
164 *** ** ** ** ** ** *********************************
165 ******************************************************************/
166#if defined(sgi) || defined(__sgi)
167
168#define DEFAULT_CD_DEVICE "/dev/scsi/sc0d6l0"
169
170#endif /* sgi IRIX */
171
172/******************************************************************
173 * Linux
174 ******************************************************************
175 *** ****** ** *** ** ** ** ** ***********************
176 *** ******** **** ** ** ** *** ************************
177 *** ******** **** * * ** ** **** *************************
178 *** ******** **** ** ** ** *** ************************
179 *** ** ** *** *** *** ** ***********************
180 ******************************************************************/
181#if defined(__linux__)
182
183/*
184 * Uncomment the following line to have WorkMan send SCSI commands
185 * directly to the CD-ROM drive. If you have a SCSI drive you
186 * probably want this, but it will cause WorkMan to not work on IDE
187 * drives.
188 */
189/*#define LINUX_SCSI_PASSTHROUGH 1*/
190
191/*
192 * Which device should be opened by WorkMan at default?
193 */
194#define DEFAULT_CD_DEVICE "/dev/cdrom"
195#define WMLIB_CDDA_BUILD 1
196#define COUNT_CDDA_BLOCKS 10
197
198/*
199 * Uncomment the following if you use the sbpcd or mcdx device driver.
200 * It shouldn't hurt if you use it on other devices. It'll be nice to
201 * hear from non-sbpcd (or mcdx) users if this is right.
202 */
203/*#define SBPCD_HACK 1*/
204
205/*
206 * Linux Soundcard support
207 * Disabled by default, because some people rely on it
208 */
209/* #define OSS_SUPPORT 1 */
210
211/*
212 * This has nothing to do with the above.
213 */
214
215/* #define CURVED_VOLUME */
216
217/*
218 * Uncomment the following if you want to try out a better responding
219 * WorkMan, especially with IDE drives. This may work with non-IDE
220 * drives as well. But it may be possible, that it doesn't work at all.
221 * If your drive/driver combination cannot handle the faster access,
222 * the driver will usually hang and you have to reboot your machine.
223 */
224/* #define FAST_IDE 1 */
225
226/*
227 * There are two alternative ways of checking a device containing a
228 * mounted filesystem. Define BSD_MOUNTTEST for the test using
229 * getmntent(). Undefine it for using the SVR4 ustat().
230 * I built in the choice, because it's not clear which method should
231 * be used in Linux. The ustat manpage tells us since 1995, that
232 * fstat() should be used, but I'm too dumb to do so.
233 */
234
235#define BSD_MOUNTTEST
236
237#endif /* __linux */
238
239/******************************************************************
240 * Sony NewsOS
241 ******************************************************************
242 *** *** ** ** ***** *** *****************************
243 *** ** ** ****** ***** ** ********************************
244 *** * * ** **** ** ** **** ******************************
245 *** ** ** ****** * * ****** ****************************
246 *** *** ** ** * *** *****************************
247 ******************************************************************/
248#if defined(__sony_news) || defined(sony_news)
249
250#define DEFAULT_CD_DEVICE "/dev/rsd/b0i6u0p2\0"
251
252#endif
253
254/******************************************************************
255 * OSF1
256 ******************************************************************
257 **** **** *** *** *** *******************************
258 *** ** ** ****** ****** ** *******************************
259 *** ** **** **** *** ***** *******************************
260 *** ** ****** ** **** ****** *******************************
261 **** **** *** *** ***** *****************************
262 ******************************************************************/
263#if defined(__osf__) || defined(__osf)
264
265#define DEFAULT_CD_DEVICE find_cdrom()
266
267#endif
268
269/******************************************************************
270 * SunOS/Solaris
271 ******************************************************************
272 **** *** ** ** *** ***************************************
273 *** ****** ** ** ** ***************************************
274 ***** **** ** ** * * ***************************************
275 ******* ** ** ** ** ***************************************
276 **** **** *** *** ***************************************
277 ******************************************************************/
278#if defined(sun) || defined(__sun)
279
280/*
281 * Define the following for Solaris 2.x
282 * If you don't want WorkMan to try to activate the SPARCstation 5
283 * internal audio input so you get sound from the workstation, comment
284 * out the CODEC define.
285 */
286
287#define SYSV 1
288#define CODEC 1
289#define DEFAULT_CD_DEVICE find_cdrom()
290#define WMLIB_CDDA_BUILD 1
291#define COUNT_CDDA_BLOCKS 15
292
293/*
294 * set the following to "SUNW,CS4231" for Sun and to "SUNW,sb16"
295 * for PC (with SoundBlaster 16) running Solaris x86
296 * (only important if you define CODEC above)
297 */
298#define SUN_AUD_DEV "SUNW,CS4231"
299/*#define SUN_AUD_DEV "SUNW,sbpro"*/
300
301
302#endif
303
304/******************************************************************
305 * SVR4
306 ******************************************************************
307 **** *** **** ** *** * ********************************
308 *** ****** **** ** ** ** * ********************************
309 ***** ***** ** *** *** *******************************
310 ******* *** ** *** ** ***** ********************************
311 **** ***** **** ** ***** ********************************
312 ******************************************************************/
313#if (defined(SVR4) || defined(__SVR4)) && !defined(sun) && !defined(__sun) && !defined(sony_news) && !defined(__sony_news)
314
315#define DEFAULT_CD_DEVICE "/dev/rcdrom/cd0"
316
317#endif
318
319/******************************************************************
320 * Ultrix
321 ******************************************************************
322 *** ** ** ***** ** *** ** ** ******************
323 *** ** ** ******* **** ** **** ***** *******************
324 *** ** ** ******* **** ***** ****** ********************
325 *** ** ** ******* **** ** **** ***** *******************
326 **** *** *** **** ** ** ** ** ******************
327 ******************************************************************/
328#if defined(ultrix) || defined(__ultrix)
329
330#define DEFAULT_CD_DEVICE find_cdrom()
331
332#endif
333
334/******************************************************************
335 * IBM AIX
336 ******************************************************************
337 **** *** ** ** *****************************************
338 *** ** **** ***** ******************************************
339 *** **** ****** *******************************************
340 *** ** **** ***** ******************************************
341 *** ** ** ** ** *****************************************
342 ******************************************************************/
343#if defined(AIXV3) || defined(__AIXV3)
344
345#define DEFAULT_CD_DEVICE "/dev/cd0"
346
347#endif /* IBM AIX */
348
349/******************************************************************/
350
351#include <stdio.h>
352
353#define DEBUG
354#ifdef DEBUG
355 #if defined(__SUNPRO_C) || defined(__SUNPRO_CC)
356 #define DEBUGLOG(...) fprintf(stderr, __VA_ARGS__)
357 #else
358 #define DEBUGLOG(fmt, args...) fprintf(stderr, fmt, ##args)
359 #endif
360#else
361 #define DEBUGLOG(fmt, args...)
362#endif
363#if defined(__SUNPRO_C) || defined(__SUNPRO_CC)
364 #define ERRORLOG(...) fprintf(stderr, __VA_ARGS__)
365#else
366 #define ERRORLOG(fmt, args...) fprintf(stderr, fmt, ##args)
367#endif
368
369#endif /* WM_CONFIG_H */
370
371
372
373
374
375
376
377
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 17:00:58 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.