diff --git a/include/cdio/cdtext.h b/include/cdio/cdtext.h index e8d92713..e14e1d5c 100644 --- a/include/cdio/cdtext.h +++ b/include/cdio/cdtext.h @@ -1,5 +1,5 @@ /* - $Id: cdtext.h,v 1.7 2004/09/04 23:49:47 rocky Exp $ + $Id: cdtext.h,v 1.8 2004/09/05 13:03:46 rocky Exp $ Copyright (C) 2004 Rocky Bernstein adapted from cuetools @@ -44,6 +44,7 @@ extern "C" { char *field[MAX_CDTEXT_FIELDS]; }; + /*! \brief A list of all of the CD-Text fields */ typedef enum { CDTEXT_ARRANGER = 0, /**< name(s) of the arranger(s) */ CDTEXT_COMPOSER = 1, /**< name(s) of the composer(s) */ @@ -73,14 +74,16 @@ extern "C" { /*! Free memory assocated with cdtext*/ void cdtext_destroy (cdtext_t *cdtext); - /*! returns the CDTEXT value associated with key at the given track - number. NULL is returned if key is CDTEXT_INVALID or the field is - not set. + /*! returns the string associated with the given field. NULL is + returned if key is CDTEXT_INVALID or the field is not set. + + @see cdio_get_cdtext to retrieve the cdtext structure used as + input here. */ const char *cdtext_get (cdtext_field_t key, const cdtext_t *cdtext); /*! - returns enum of keyword if key is a CD-TEXT keyword, + returns enum of keyword if key is a CD-Text keyword, returns MAX_CDTEXT_FIELDS non-zero otherwise. */ cdtext_field_t cdtext_is_keyword (const char *key); diff --git a/test/Makefile.am b/test/Makefile.am index f975b736..808421e4 100644 --- a/test/Makefile.am +++ b/test/Makefile.am @@ -1,4 +1,4 @@ -# $Id: Makefile.am,v 1.27 2004/07/11 02:33:18 rocky Exp $ +# $Id: Makefile.am,v 1.28 2004/09/05 13:03:46 rocky Exp $ # # Copyright (C) 2003, 2004 Rocky Bernstein # @@ -33,8 +33,12 @@ testassert_LDADD = $(LIBCDIO_LIBS) testdefault_LDADD = $(LIBCDIO_LIBS) testischar_LDADD = $(LIBISO9660_LIBS) $(LIBCDIO_LIBS) testiso9660_LDADD = $(LIBISO9660_LIBS) $(LIBCDIO_LIBS) + testtoc_LDADD = $(LIBCDIO_LIBS) +testtoc_CFLAGS = -DTEST_DIR=\"$(srcdir)\" + testbincue_LDADD = $(LIBCDIO_LIBS) +testbincue_CFLAGS = -DTEST_DIR=\"$(srcdir)\" check_SCRIPTS = check_nrg.sh check_cue.sh check_cd_read.sh \ check_iso.sh check_opts.sh @@ -75,4 +79,6 @@ MOSTLYCLEANFILES = core.* *.dump # learning any more of this awful system than I need to. check-am: make-executable make-executable: check_nrg.sh check_cue.sh - chmod +x *.sh \ No newline at end of file + chmod +x *.sh + if test ! -f cdda.bin ; then $(LN_S) $(srcdir)/cdda.bin cdda.bin ; fi + if test ! -f isofs-m1.bin ; then $(LN_S) $(srcdir)/isofs-m1.bin isofs-m1.bin ; fi diff --git a/test/testbincue.c b/test/testbincue.c index 68fd3bc5..a8eca421 100644 --- a/test/testbincue.c +++ b/test/testbincue.c @@ -1,5 +1,5 @@ /* - $Id: testbincue.c,v 1.2 2004/07/10 01:18:02 rocky Exp $ + $Id: testbincue.c,v 1.3 2004/09/05 13:03:46 rocky Exp $ Copyright (C) 2004 Rocky Bernstein @@ -38,6 +38,10 @@ #endif #include +#ifndef TEST_DIR +#define TEST_DIR "." +#endif + #define NUM_GOOD_CUES 2 #define NUM_BAD_CUES 7 int @@ -59,10 +63,15 @@ main(int argc, const char *argv[]) }; int ret=0; unsigned int i; + char psz_cuefile[500]; + psz_cuefile[sizeof(psz_cuefile)-1] = '\0'; cdio_loglevel_default = (argc > 1) ? CDIO_LOG_DEBUG : CDIO_LOG_INFO; for (i=0; i @@ -38,6 +38,10 @@ #endif #include +#ifndef TEST_DIR +#define TEST_DIR "." +#endif + #define NUM_GOOD_TOCS 15 #define NUM_BAD_TOCS 7 int @@ -72,10 +76,15 @@ main(int argc, const char *argv[]) }; int ret=0; unsigned int i; + char psz_tocfile[500]; + + psz_tocfile[sizeof(psz_tocfile)-1] = '\0'; cdio_loglevel_default = (argc > 1) ? CDIO_LOG_DEBUG : CDIO_LOG_INFO; for (i=0; i