#
-SUBDIRS = doc include man src test
+SUBDIRS = doc include man src test build flac.pbproj obj
DISTCLEANFILES = libtool-disable-static
COPYING.LGPL \
Makefile.lite \
autogen.sh \
- build \
depcomp \
- flac.pbproj \
strip_fPIC.sh
AUTOMAKE_OPTIONS = foreign
# clean : remove all non-distro files
#
-.PHONY: doc libFLAC libFLAC++ libOggFLAC libOggFLAC++ share plugin_xmms flac metaflac test_libFLAC test_libFLAC++ test_libOggFLAC test_libOggFLAC++ test_streams
-all: doc libFLAC libFLAC++ libOggFLAC libOggFLAC++ share plugin_xmms flac metaflac test_libFLAC test_libFLAC++ test_libOggFLAC test_libOggFLAC++ test_streams
+.PHONY: doc libFLAC libFLAC++ libOggFLAC libOggFLAC++ share plugin_common plugin_xmms flac metaflac test_libFLAC test_libFLAC++ test_libOggFLAC test_libOggFLAC++ test_streams
+all: doc libFLAC libFLAC++ libOggFLAC libOggFLAC++ share plugin_common plugin_xmms flac metaflac test_libFLAC test_libFLAC++ test_libOggFLAC test_libOggFLAC++ test_streams
DEFAULT_CONFIG = release
metaflac: libFLAC share
(cd src/$@ ; $(MAKE) -f Makefile.lite $(CONFIG))
-plugin_xmms: libFLAC
+plugin_common: libFLAC
+ (cd src/$@ ; $(MAKE) -f Makefile.lite $(CONFIG))
+
+plugin_xmms: libFLAC plugin_common
(cd src/$@ ; $(MAKE) -f Makefile.lite $(CONFIG))
test_streams: libFLAC
-(cd src/share ; $(MAKE) -f Makefile.lite clean)
-(cd src/flac ; $(MAKE) -f Makefile.lite clean)
-(cd src/metaflac ; $(MAKE) -f Makefile.lite clean)
+ -(cd src/plugin_common ; $(MAKE) -f Makefile.lite clean)
-(cd src/plugin_xmms ; $(MAKE) -f Makefile.lite clean)
-(cd src/test_libFLAC ; $(MAKE) -f Makefile.lite clean)
-(cd src/test_libFLAC++ ; $(MAKE) -f Makefile.lite clean)
SHARE_LIBS='$(top_builddir)/src/share/libutf8.a $(top_builddir)/src/share/libgetopt.a'
dnl check for i18n(internationalization); these are from libiconv/gettext
-AM_WITH_NLS
AM_ICONV
AM_LANGINFO_CODESET
src/libOggFLAC++/Makefile \
src/flac/Makefile \
src/metaflac/Makefile \
+ src/monkeys_audio_utilities/flac_mac/Makefile \
+ src/monkeys_audio_utilities/flac_ren/Makefile \
+ src/monkeys_audio_utilities/Makefile \
+ src/plugin_common/Makefile \
+ src/plugin_winamp2/Makefile \
+ src/plugin_winamp3/Makefile \
src/plugin_xmms/Makefile \
src/share/Makefile \
src/test_libFLAC/Makefile \
src/test_libFLAC++/Makefile \
+ src/test_libOggFLAC/Makefile \
+ src/test_libOggFLAC++/Makefile \
src/test_streams/Makefile \
include/Makefile \
include/FLAC/Makefile \
include/FLAC/ordinals.h \
include/FLAC++/Makefile \
+ include/OggFLAC/Makefile \
+ include/OggFLAC++/Makefile \
include/share/Makefile \
doc/Makefile \
doc/html/Makefile \
doc/html/ru/Makefile \
man/Makefile \
test/Makefile \
+ build/Makefile \
+ obj/bin/Makefile \
+ obj/lib/Makefile \
+ obj/Makefile \
+ flac.pbproj/Makefile \
)
docdir = $(datadir)/doc/$(PACKAGE)-$(VERSION)
-doc_DATA = \
+doc_DATA = \
FLAC.tag
EXTRA_DIST = Doxyfile Makefile.lite $(doc_DATA)
api
EXTRA_DIST = $(doc_DATA)
+
+# The install targets don't copy whole directories so we have to
+# handle 'api/' specially:
+install-data-local:
+ $(mkinstalldirs) $(DESTDIR)$(docdir)/api
+ (cd api && $(INSTALL_DATA) * $(DESTDIR)$(docdir)/api)
+uninstall-local:
+ rm -rf $(DESTDIR)$(docdir)/api
if FLaC__HAS_OGG
OGGFLAC_DIRS = libOggFLAC libOggFLAC++
-#@@@@ tests not written yet: test_libOggFLAC++
-OGGFLAC_TEST_DIRS = test_libOggFLAC
+OGGFLAC_TEST_DIRS = test_libOggFLAC test_libOggFLAC++
endif
-EXTRA_DIST = \
- monkeys_audio_utilities \
- plugin_winamp2 \
- plugin_winamp3
-
SUBDIRS = \
libFLAC \
libFLAC++ \
share \
flac \
metaflac \
+ monkeys_audio_utilities \
+ plugin_common \
$(XMMS_DIRS) \
+ plugin_winamp2 \
+ plugin_winamp3 \
test_libFLAC \
test_libFLAC++ \
$(OGGFLAC_TEST_DIRS) \
bin_PROGRAMS = flac
CFLAGS = @CFLAGS@ @OGG_CFLAGS@
+if FLaC__HAS_OGG
+NEED_OGGFLAC_LIB = $(top_builddir)/src/libOggFLAC/libOggFLAC.la
+endif
+
EXTRA_DIST = \
Makefile.lite \
Makefile.vc
encode.h \
file.h
-flac_LDADD = $(top_builddir)/src/libFLAC/libFLAC.la @OGG_LIBS@ @SHARE_LIBS@ -lm
+flac_LDADD = $(NEED_OGGFLAC_LIB) $(top_builddir)/src/libFLAC/libFLAC.la @OGG_LIBS@ @SHARE_LIBS@ -lm
{
DecoderSession decoder_session;
- if(!DecoderSession_construct(&decoder_session, options.common.is_ogg, options.common.verbose, /*is_wave_out=*/true, options.common.continue_through_decode_errors, analysis_mode, aopts, options.common.skip, infilename, outfilename))
+ if(!
+ DecoderSession_construct(
+ &decoder_session,
+#ifdef FLAC__HAS_OGG
+ options.common.is_ogg,
+#else
+ /*is_ogg=*/false,
+#endif
+ options.common.verbose,
+ /*is_wave_out=*/true,
+ options.common.continue_through_decode_errors,
+ analysis_mode,
+ aopts,
+ options.common.skip,
+ infilename,
+ outfilename
+ )
+ )
return 1;
if(!DecoderSession_init_decoder(&decoder_session, infilename))
decoder_session.is_big_endian = options.is_big_endian;
decoder_session.is_unsigned_samples = options.is_unsigned_samples;
- if(!DecoderSession_construct(&decoder_session, options.common.is_ogg, options.common.verbose, /*is_wave_out=*/false, options.common.continue_through_decode_errors, analysis_mode, aopts, options.common.skip, infilename, outfilename))
+ if(!
+ DecoderSession_construct(
+ &decoder_session,
+#ifdef FLAC__HAS_OGG
+ options.common.is_ogg,
+#else
+ /*is_ogg=*/false,
+#endif
+ options.common.verbose,
+ /*is_wave_out=*/false,
+ options.common.continue_through_decode_errors,
+ analysis_mode,
+ aopts,
+ options.common.skip,
+ infilename,
+ outfilename
+ )
+ )
return 1;
if(!DecoderSession_init_decoder(&decoder_session, infilename))
{
#ifdef FLAC__HAS_OGG
d->is_ogg = is_ogg;
+#else
+ (void)is_ogg;
#endif
d->verbose = verbose;
(void)lookahead; /* silence compiler warning about unused parameter */
(void)lookahead_length; /* silence compiler warning about unused parameter */
- if(!EncoderSession_construct(&encoder_session, options.common.use_ogg, options.common.verify, options.common.verbose, infile, infilename, outfilename))
+ if(!
+ EncoderSession_construct(
+ &encoder_session,
+#ifdef FLAC__HAS_OGG
+ options.common.use_ogg,
+#else
+ /*use_ogg=*/false,
+#endif
+ options.common.verify,
+ options.common.verbose,
+ infile,
+ infilename,
+ outfilename
+ )
+ )
return 1;
/* lookahead[] already has "FORMxxxxAIFF", do sub-chunks */
(void)lookahead;
(void)lookahead_length;
- if(!EncoderSession_construct(&encoder_session, options.common.use_ogg, options.common.verify, options.common.verbose, infile, infilename, outfilename))
+ if(!
+ EncoderSession_construct(
+ &encoder_session,
+#ifdef FLAC__HAS_OGG
+ options.common.use_ogg,
+#else
+ /*use_ogg=*/false,
+#endif
+ options.common.verify,
+ options.common.verbose,
+ infile,
+ infilename,
+ outfilename
+ )
+ )
return 1;
/*
FLAC__ASSERT(!options.common.sector_align || options.sample_rate == 44100);
FLAC__ASSERT(!options.common.sector_align || infilesize >= 0);
- if(!EncoderSession_construct(&encoder_session, options.common.use_ogg, options.common.verify, options.common.verbose, infile, infilename, outfilename))
+ if(!
+ EncoderSession_construct(
+ &encoder_session,
+#ifdef FLAC__HAS_OGG
+ options.common.use_ogg,
+#else
+ /*use_ogg=*/false,
+#endif
+ options.common.verify,
+ options.common.verbose,
+ infile,
+ infilename,
+ outfilename
+ )
+ )
return 1;
/* get the file length */
#ifdef FLAC__HAS_OGG
e->use_ogg = use_ogg;
+#else
+ (void)use_ogg;
#endif
e->verify = verify;
e->verbose = verbose;
endif
CFLAGS = @CFLAGS@ $(DEBUGCFLAGS)
-SUBDIRS = $(ARCH_SUBDIRS) include .
+SUBDIRS = include .
m4datadir = $(datadir)/aclocal
m4data_DATA = libOggFLAC.m4
# Free Software Foundation, Inc., 59 Temple Place - Suite 330,
# Boston, MA 02111-1307, USA.
-SUBDIRS = private
+SUBDIRS = protected
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-SUBDIRS = flacmac flacren
+SUBDIRS = flac_mac flac_ren
Makefile.vc \
in2.h \
in_flac.c \
+ in_flac.dsp \
+ in_flac.dsw \
out.h
\r
!IFDEF DEBUG\r
.c.obj:\r
- $(cc) /GX $(cdebug) $(cflags) $(cvarsdll) /I "..\..\include" /I ".\include" -DSTRICT -DVERSION=\"1.0.3\" -YX /Od /D "_DEBUG" $<\r
+ $(cc) /GX $(cdebug) $(cflags) $(cvarsdll) /I "..\..\include" /I ".\include" /I ".." -DSTRICT -DVERSION=\"1.0.3\" -YX /Od /D "_DEBUG" $<\r
!else\r
.c.obj:\r
- $(cc) /O2 $(crelease) $(cflags) $(cvarsdll) /I "..\..\include" /I ".\include" -DSTRICT -DVERSION=\"1.0.3\" -YX -DNODEBUG $<\r
+ $(cc) /O2 $(crelease) $(cflags) $(cvarsdll) /I "..\..\include" /I ".\include" /I ".." -DSTRICT -DVERSION=\"1.0.3\" -YX -DNODEBUG $<\r
!endif\r
\r
C_FILES= \\r
all: in_flac.dll\r
\r
in_flac.dll: $(OBJS)\r
- link.exe /dll /nodefaultlib:libc.lib /libpath:"..\..\obj\lib" -out:../../obj/bin/$*.dll $(OBJS) libFLAC.lib user32.lib kernel32.lib\r
+ link.exe /dll /nodefaultlib:libc.lib /libpath:"..\..\obj\lib" -out:../../obj/bin/$*.dll $(OBJS) libFLAC.lib plugin_common.lib user32.lib kernel32.lib\r
\r
clean:\r
-del *.obj *.pch\r
Makefile.lite \
id3_tag.c
+noinst_HEADERS = \
+ charset.h \
+ configure.h \
+ genres.h \
+ id3_tag.h \
+ mylocale.h \
+ wrap_id3.h
+
CFLAGS = @CFLAGS@ @XMMS_CFLAGS@
xmmsinputplugindir = @XMMS_INPUT_PLUGIN_DIR@
xmmsinputplugin_LTLIBRARIES = libxmms-flac.la
-plugin_sources = plugin.c wrap_id3.c configure.c charset.c
+plugin_sources = configure.c charset.c plugin.c wrap_id3.c
id3v2_sources = id3_tag.c
if FLaC__HAS_ID3LIB
#
LIB_NAME = libxmms-flac
-INCLUDES = $(shell xmms-config --cflags) -I./include -I../../include
-LIBS = ../../obj/lib/libFLAC.a
+INCLUDES = $(shell xmms-config --cflags) -I./include -I../../include -I..
+LIBS = ../../obj/lib/libFLAC.a ../../obj/lib/libplugin-common.a
OBJS = \
- plugin.o \
+ charset.o \
configure.o \
- wrap_id3.o \
- charset.o
-
+ plugin.o \
+ wrap_id3.o
include ../../build/lib.mk
return FALSE;
}
- tmp_file_info->sample_rate = streaminfo.data.stream_info.sample_rate;
- tmp_file_info->channels = streaminfo.data.stream_info.channels;
- tmp_file_info->bits_per_sample = streaminfo.data.stream_info.bits_per_sample;
- tmp_file_info->total_samples = streaminfo.data.stream_info.total_samples;
+ tmp_file_info->sample_rate = streaminfo.data.stream_info.sample_rate;
+ tmp_file_info->channels = streaminfo.data.stream_info.channels;
+ tmp_file_info->bits_per_sample = streaminfo.data.stream_info.bits_per_sample;
+ tmp_file_info->total_samples = streaminfo.data.stream_info.total_samples;
- tmp_file_info->length_in_msec = streaminfo.data.stream_info.total_samples * 10 / (streaminfo.data.stream_info.sample_rate / 100);
+ tmp_file_info->length_in_msec = streaminfo.data.stream_info.total_samples * 10 / (streaminfo.data.stream_info.sample_rate / 100);
return TRUE;
}
static gchar* channel_mode_name(int mode)
{
- static const gchar *channel_mode[] =
- {N_("Mono"), N_("Stereo")};
+ static const gchar *channel_mode[] = {N_("Mono"), N_("Stereo")};
if (mode < 1 || mode > 2)
return "";
return gettext(channel_mode[mode]);
label_set_text(flac_bitrate, _("Bits/Samples: %d"), tmp_file_info->bits_per_sample);
/* tmp_file_info->length_in_msec */
- label_set_text(flac_samplerate, _("Samplerate: %ld Hz"), tmp_file_info->sample_rate);
+ label_set_text(flac_samplerate, _("Samplerate: %ld Hz"), tmp_file_info->sample_rate);
label_set_text(flac_channel, _("Channel: %s"), channel_mode_name(tmp_file_info->channel);
#if 0
label_set_text(flac_fileinfo, _("%d frames\nFilesize: %lu B"), num_frames, ftell(fh));
#endif
}
-
-
flac_cfg.convert_char_set = FALSE;
cfg = xmms_cfg_open_default_file();
+
xmms_cfg_read_boolean(cfg, "flac", "tag_override", &flac_cfg.tag_override);
- if (!xmms_cfg_read_string(cfg, "flac", "tag_format",
- &flac_cfg.tag_format))
+
+ if(!xmms_cfg_read_string(cfg, "flac", "tag_format", &flac_cfg.tag_format))
flac_cfg.tag_format = g_strdup("%p - %t");
xmms_cfg_read_boolean(cfg, "flac", "convert_char_set", &flac_cfg.convert_char_set);
- if (!xmms_cfg_read_string(cfg, "flac", "file_char_set",
- &flac_cfg.file_char_set))
- {
+
+ if(!xmms_cfg_read_string(cfg, "flac", "file_char_set", &flac_cfg.file_char_set))
flac_cfg.file_char_set = get_current_charset();
- }
- if (!xmms_cfg_read_string(cfg, "flac", "user_char_set",
- &flac_cfg.user_char_set))
- {
+
+ if(!xmms_cfg_read_string(cfg, "flac", "user_char_set", &flac_cfg.user_char_set))
flac_cfg.user_char_set = get_current_charset();
- }
decoder_ = FLAC__file_decoder_new();
}
INCLUDES =
noinst_PROGRAMS = test_libOggFLAC
-test_libOggFLAC_LDADD = $(top_builddir)/src/libOggFLAC/libOggFLAC.la $(top_builddir)/src/libOggFLAC/libFLAC.la @OGG_LIBS@ -lm
+test_libOggFLAC_LDADD = $(top_builddir)/src/libOggFLAC/libOggFLAC.la $(top_builddir)/src/libFLAC/libFLAC.la @OGG_LIBS@ -lm
test_libOggFLAC_SOURCES = \
decoders.c \
encoders.c \
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+if FLaC__HAS_OGG
+OGG_TESTS = \
+ ./test_libOggFLAC.sh \
+ ./test_libOggFLAC++.sh
+endif
+
TESTS = \
./test_libFLAC.sh \
./test_libFLAC++.sh \
- ./test_libOggFLAC.sh \
- ./test_libOggFLAC++.sh \
+ $(OGG_TESTS) \
./test_metaflac.sh \
./test_streams.sh \
./test_bins.sh
EXTRA_DIST = \
+ Makefile.lite \
test_libFLAC.sh \
test_libFLAC++.sh \
test_libOggFLAC.sh \