Make debugger-helping enums extern'd and define onces elsewhere.

This commit is contained in:
rocky
2005-02-05 12:37:35 +00:00
parent d958f062ea
commit b58349ba1a
6 changed files with 40 additions and 26 deletions

View File

@@ -1,5 +1,5 @@
/* /*
$Id: cdda.h,v 1.15 2005/02/05 04:23:21 rocky Exp $ $Id: cdda.h,v 1.16 2005/02/05 12:37:35 rocky Exp $
Copyright (C) 2004, 2005 Rocky Bernstein <rocky@panix.com> Copyright (C) 2004, 2005 Rocky Bernstein <rocky@panix.com>
Copyright (C) 2001 Xiph.org Copyright (C) 2001 Xiph.org
@@ -32,7 +32,7 @@
#include <cdio/cdio.h> #include <cdio/cdio.h>
#include <cdio/paranoia.h> #include <cdio/paranoia.h>
enum { extern enum paranoia_cdda_enums {
CDDA_MESSAGE_FORGETIT = 0, CDDA_MESSAGE_FORGETIT = 0,
CDDA_MESSAGE_PRINTIT = 1, CDDA_MESSAGE_PRINTIT = 1,
CDDA_MESSAGE_LOGIT = 2, CDDA_MESSAGE_LOGIT = 2,
@@ -127,7 +127,7 @@ struct cdrom_drive_s {
be helpful in debuggers where wants just to refer to the CDDA_TEST_ be helpful in debuggers where wants just to refer to the CDDA_TEST_
names and get something. names and get something.
*/ */
enum { extern enum paranoia_jitter_enums {
CDDA_TEST_JITTER_SMALL = 1, CDDA_TEST_JITTER_SMALL = 1,
CDDA_TEST_JITTER_LARGE = 2, CDDA_TEST_JITTER_LARGE = 2,
CDDA_TEST_JITTER_MASSIVE = 3, CDDA_TEST_JITTER_MASSIVE = 3,

View File

@@ -1,5 +1,5 @@
/* /*
$Id: iso9660.h,v 1.59 2005/02/05 04:23:21 rocky Exp $ $Id: iso9660.h,v 1.60 2005/02/05 12:37:35 rocky Exp $
Copyright (C) 2000 Herbert Valerio Riedel <hvr@gnu.org> Copyright (C) 2000 Herbert Valerio Riedel <hvr@gnu.org>
Copyright (C) 2003, 2004, 2005 Rocky Bernstein <rocky@panix.com> Copyright (C) 2003, 2004, 2005 Rocky Bernstein <rocky@panix.com>
@@ -50,7 +50,7 @@
to be helpful in debuggers where wants just to refer to the to be helpful in debuggers where wants just to refer to the
ISO_*_ names and get something. ISO_*_ names and get something.
*/ */
enum { extern enum iso_enums1 {
ISO_PVD_SECTOR = 16, /**< Sector of Primary Volume Descriptor */ ISO_PVD_SECTOR = 16, /**< Sector of Primary Volume Descriptor */
ISO_EVD_SECTOR = 17, /**< Sector of End Volume Descriptor */ ISO_EVD_SECTOR = 17, /**< Sector of End Volume Descriptor */
LEN_ISONAME = 31, /**< size in bytes of the filename LEN_ISONAME = 31, /**< size in bytes of the filename
@@ -71,19 +71,19 @@ enum {
to be helpful in debuggers where wants just to refer to the to be helpful in debuggers where wants just to refer to the
ISO_*_ names and get something. ISO_*_ names and get something.
*/ */
enum { extern enum iso_flag_enums {
ISO_FILE = 0, /**<, Not really a flag... */ ISO_FILE = 0, /**< Not really a flag... */
ISO_EXISTENCE = 1, /**< Do not make existence known (hidden) */ ISO_EXISTENCE = 1, /**< Do not make existence known (hidden) */
ISO_DIRECTORY = 2, /**< This file is a directory */ ISO_DIRECTORY = 2, /**< This file is a directory */
ISO_ASSOCIATED = 4, /**< This file is an associated file */ ISO_ASSOCIATED = 4, /**< This file is an associated file */
ISO_RECORD = 8, /**<, Record format in extended attr. != 0 */ ISO_RECORD = 8, /**< Record format in extended attr. != 0 */
ISO_PROECTION = 16, /**< No read/execute perm. in ext. attr. */ ISO_PROECTION = 16, /**< No read/execute perm. in ext. attr. */
ISO_DRESERVED1 = 32, /**<, Reserved bit 5 */ ISO_DRESERVED1 = 32, /**<, Reserved bit 5 */
ISO_DRESERVED2 = 64, /**<, Reserved bit 6 */ ISO_DRESERVED2 = 64, /**<, Reserved bit 6 */
ISO_MULTIEXTENT = 128, /**< Not final entry of a mult. ext. file */ ISO_MULTIEXTENT = 128, /**< Not final entry of a mult. ext. file */
} iso_flag_enums; } iso_flag_enums;
enum { extern enum iso_vd_enums {
ISO_VD_PRIMARY = 1, /**< Is in any ISO-9660 */ ISO_VD_PRIMARY = 1, /**< Is in any ISO-9660 */
ISO_VD_SUPPLEMENARY = 2, /**< Used by Joliet */ ISO_VD_SUPPLEMENARY = 2, /**< Used by Joliet */
ISO_VD_END = 255 ISO_VD_END = 255

View File

@@ -1,5 +1,5 @@
/* /*
$Id: sector.h,v 1.32 2005/02/05 04:23:21 rocky Exp $ $Id: sector.h,v 1.33 2005/02/05 12:37:35 rocky Exp $
Copyright (C) 2000 Herbert Valerio Riedel <hvr@gnu.org> Copyright (C) 2000 Herbert Valerio Riedel <hvr@gnu.org>
Copyright (C) 2003, 2004, 2005 Rocky Bernstein <rocky@panix.com> Copyright (C) 2003, 2004, 2005 Rocky Bernstein <rocky@panix.com>
@@ -129,7 +129,7 @@
be helpful in debuggers where wants just to refer to the CDIO_CD_ be helpful in debuggers where wants just to refer to the CDIO_CD_
names and get something. names and get something.
*/ */
enum { extern enum cdio_cd_enums {
CDIO_CD_MINS = 74, /**< max. minutes per CD, not really CDIO_CD_MINS = 74, /**< max. minutes per CD, not really
a limit */ a limit */
CDIO_CD_SECS_PER_MIN = 60, /**< seconds per minute */ CDIO_CD_SECS_PER_MIN = 60, /**< seconds per minute */
@@ -210,7 +210,7 @@
is to be helpful in debuggers where wants just to refer to the is to be helpful in debuggers where wants just to refer to the
CDIO_CDROM_* names and get something. CDIO_CDROM_* names and get something.
*/ */
enum { extern enum cdio_cdrom_enums {
CDIO_CDROM_LBA =0x01, /**< "logical block": first frame is #0 */ CDIO_CDROM_LBA =0x01, /**< "logical block": first frame is #0 */
CDIO_CDROM_MSF =0x02, /**< "minute-second-frame": binary, not CDIO_CDROM_MSF =0x02, /**< "minute-second-frame": binary, not
BCD here! */ BCD here! */
@@ -234,7 +234,7 @@
program it is to be helpful in debuggers where wants just to refer program it is to be helpful in debuggers where wants just to refer
to the M2*_SECTOR_SIZE names and get something. to the M2*_SECTOR_SIZE names and get something.
*/ */
enum { extern enum m2_sector_enums {
M2F2_SECTOR_SIZE = 2324, M2F2_SECTOR_SIZE = 2324,
M2SUB_SECTOR_SIZE = 2332, M2SUB_SECTOR_SIZE = 2332,
M2RAW_SECTOR_SIZE = 2336 M2RAW_SECTOR_SIZE = 2336

View File

@@ -1,5 +1,5 @@
/* /*
$Id: common_interface.c,v 1.12 2005/01/27 03:10:06 rocky Exp $ $Id: common_interface.c,v 1.13 2005/02/05 12:37:35 rocky Exp $
Copyright (C) 2004, 2005 Rocky Bernstein <rocky@panix.com> Copyright (C) 2004, 2005 Rocky Bernstein <rocky@panix.com>
Copyright (C) 1998, 2002 Monty monty@xiph.org Copyright (C) 1998, 2002 Monty monty@xiph.org
@@ -31,6 +31,10 @@
#include "utils.h" #include "utils.h"
#include "smallft.h" #include "smallft.h"
/* Variables to hold debugger-helping enumerations */
enum paranoia_cdda_enums;
enum paranoia_jitter_enums;
/*! Determine Endian-ness of the CD-drive based on reading data from /*! Determine Endian-ness of the CD-drive based on reading data from
it. Some drives return audio data Big Endian while some (most) it. Some drives return audio data Big Endian while some (most)
return data Little Endian. Drives known to return data bigendian are return data Little Endian. Drives known to return data bigendian are

View File

@@ -1,5 +1,5 @@
/* /*
$Id: sector.c,v 1.2 2005/02/05 04:25:14 rocky Exp $ $Id: sector.c,v 1.3 2005/02/05 12:37:35 rocky Exp $
Copyright (C) 2004, 2005 Rocky Bernstein <rocky@panix.com> Copyright (C) 2004, 2005 Rocky Bernstein <rocky@panix.com>
Copyright (C) 2000 Herbert Valerio Riedel <hvr@gnu.org> Copyright (C) 2000 Herbert Valerio Riedel <hvr@gnu.org>
@@ -35,12 +35,17 @@
#include <ctype.h> #include <ctype.h>
static const char _rcsid[] = "$Id: sector.c,v 1.2 2005/02/05 04:25:14 rocky Exp $"; static const char _rcsid[] = "$Id: sector.c,v 1.3 2005/02/05 12:37:35 rocky Exp $";
/*! String of bytes used to identify the beginning of a Mode 1 or /*! String of bytes used to identify the beginning of a Mode 1 or
Mode 2 sector. */ Mode 2 sector. */
const uint8_t CDIO_SECTOR_SYNC_HEADER[CDIO_CD_SYNC_SIZE] = const uint8_t CDIO_SECTOR_SYNC_HEADER[CDIO_CD_SYNC_SIZE] =
{0, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0}; {0, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0};
/* Variables to hold debugger-helping enumerations */
enum cdio_cd_enums;
enum cdio_cdrom_enums;
enum m2_sector_enums;
lba_t lba_t
cdio_lba_to_lsn (lba_t lba) cdio_lba_to_lsn (lba_t lba)

View File

@@ -1,8 +1,8 @@
/* /*
$Id: iso9660.c,v 1.1 2004/12/18 17:29:32 rocky Exp $ $Id: iso9660.c,v 1.2 2005/02/05 12:37:35 rocky Exp $
Copyright (C) 2000 Herbert Valerio Riedel <hvr@gnu.org> Copyright (C) 2000 Herbert Valerio Riedel <hvr@gnu.org>
Copyright (C) 2003, 2004 Rocky Bernstein <rocky@panix.com> Copyright (C) 2003, 2004, 2005 Rocky Bernstein <rocky@panix.com>
This program is free software; you can redistribute it and/or modify This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by it under the terms of the GNU General Public License as published by
@@ -37,7 +37,12 @@
#include <stdio.h> #include <stdio.h>
#endif #endif
static const char _rcsid[] = "$Id: iso9660.c,v 1.1 2004/12/18 17:29:32 rocky Exp $"; static const char _rcsid[] = "$Id: iso9660.c,v 1.2 2005/02/05 12:37:35 rocky Exp $";
/* Variables to hold debugger-helping enumerations */
enum iso_enums1 iso_enums1;
enum iso_flag_enums iso_flag_enums;
enum iso_vd_enums iso_vd_enums;
/* some parameters... */ /* some parameters... */
#define SYSTEM_ID "CD-RTOS CD-BRIDGE" #define SYSTEM_ID "CD-RTOS CD-BRIDGE"