Changes to testpregap.c to allow to build outside of the source tree.

This commit is contained in:
rocky
2008-05-05 23:58:28 +00:00
parent 49defd1cdc
commit 3f266b669b
3 changed files with 17 additions and 11 deletions

View File

@@ -1,4 +1,4 @@
# $Id: Makefile.am,v 1.66 2008/03/28 01:28:50 rocky Exp $
# $Id: Makefile.am,v 1.67 2008/05/05 23:58:28 rocky Exp $
#
# Copyright (C) 2003, 2004, 2006, 2008 Rocky Bernstein <rocky@gnu.org>
#
@@ -88,7 +88,8 @@ check_DATA = vcd_demo.right vcd_demo_vcdinfo.right \
EXTRA_DIST = $(check_SCRIPTS) $(check_DATA) \
check_common_fn check_cue.sh.in check_nrg.sh.in \
testbincue.c.in testnrg.c.in check_iso.sh.in p1.bin p1.cue p1.nrg
testbincue.c.in testpregap.c.in testnrg.c.in \
check_iso.sh.in p1.bin p1.cue p1.nrg
TESTS = $(check_PROGRAMS) $(check_SCRIPTS)
XFAIL_TESTS = testassert

View File

@@ -1,5 +1,5 @@
/*
$Id: testpregap.c,v 1.2 2008/03/22 18:08:25 karl Exp $
$Id: testpregap.c.in,v 1.1 2008/05/05 23:58:28 rocky Exp $
Copyright (C) 2003, 2004, 2005 Rocky Bernstein <rocky@gnu.org>
Copyright (C) 2008 Robert W. Fuller <hydrologiccycle@gmail.com>
@@ -39,6 +39,10 @@
#endif
#include <string.h>
#ifndef TEST_DIR
#define TEST_DIR "@srcdir@"
#endif
static void
log_handler (cdio_log_level_t level, const char message[])
{
@@ -61,14 +65,14 @@ typedef struct _pregap_list_t {
static pregap_list_t pregapList[] =
{
{ "t2.toc", 1, 4425 },
{ "t2.toc", 2, CDIO_INVALID_LSN },
{ "p1.cue", 1, 0 },
{ "p1.cue", 2, 150 },
{ "p1.cue", 3, CDIO_INVALID_LSN },
{ "@srcdir@/t2.toc", 1, 4425 },
{ "@srcdir@/t2.toc", 2, CDIO_INVALID_LSN },
{ "@srcdir@/p1.cue", 1, 0 },
{ "@srcdir@/p1.cue", 2, 150 },
{ "@srcdir@/p1.cue", 3, CDIO_INVALID_LSN },
/* { "p1.nrg", 1, 0 }, Nero did not create the proper pre-gap - bleh */
{ "p1.nrg", 2, 225 },
{ "p1.nrg", 3, CDIO_INVALID_LSN }
{ "@srcdir@/p1.nrg", 2, 225 },
{ "@srcdir@/p1.nrg", 3, CDIO_INVALID_LSN }
};
#define NELEMS(v) (sizeof(v) / sizeof(v[0]))