From: Paul Brossier Date: Sun, 14 Aug 2005 18:44:58 +0000 (+0000) Subject: added dummy assignment to make egcs happy, use in woodblock path X-Git-Tag: bzr2git~844 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=6b233fcc367d62ac9badf7d2d3d9bbbfd44c51f2;p=aubio.git added dummy assignment to make egcs happy, use in woodblock path --- diff --git a/examples/Makefile.am b/examples/Makefile.am index 14cb457b..b841077d 100644 --- a/examples/Makefile.am +++ b/examples/Makefile.am @@ -3,7 +3,7 @@ SUBDIRS = tests endif # global flags -AM_CFLAGS = -I$(srcdir)/../src -I$(srcdir)/../ext @LADCCA_CFLAGS@ +AM_CFLAGS = -DAUBIO_PREFIX=\"$(prefix)\" -I$(srcdir)/../src -I$(srcdir)/../ext @LADCCA_CFLAGS@ AM_LDFLAGS = -L../src -L../ext @LADCCA_LIBS@ -laubioext -laubio #AM_SOURCES = utils.c diff --git a/examples/utils.c b/examples/utils.c index 34998a69..46224b08 100644 --- a/examples/utils.c +++ b/examples/utils.c @@ -21,7 +21,7 @@ cca_client_t * aubio_cca_client; /* settings */ const char * output_filename = NULL; const char * input_filename = NULL; -const char * onset_filename = "/usr/share/sounds/aubio/woodblock.aiff"; +const char * onset_filename = AUBIO_PREFIX "/share/sounds/" PACKAGE "/woodblock.aiff"; int frames = 0; int verbose = 0; int usejack = 0; @@ -237,7 +237,8 @@ void examples_common_init(int argc,char ** argv) { woodblock = new_fvec(buffer_size,1); if (output_filename || usejack) { - (onsetfile = new_aubio_sndfile_ro(onset_filename)) || + /* dummy assignement to keep egcs happy */ + isonset = (onsetfile = new_aubio_sndfile_ro(onset_filename)) || (onsetfile = new_aubio_sndfile_ro("sounds/woodblock.aiff")) || (onsetfile = new_aubio_sndfile_ro("../sounds/woodblock.aiff")); }