Remove the options to disable MP4/ASF support

This commit is contained in:
Lukáš Lalinský
2011-06-24 08:49:50 +02:00
parent 0b34d4f8ee
commit dd846904cb
18 changed files with 18 additions and 93 deletions

View File

@ -97,26 +97,18 @@ set(tag_HDRS
riff/aiff/aiffproperties.h
riff/wav/wavfile.h
riff/wav/wavproperties.h
asf/asffile.h
asf/asfproperties.h
asf/asftag.h
asf/asfattribute.h
asf/asfpicture.h
mp4/mp4file.h
mp4/mp4atom.h
mp4/mp4tag.h
mp4/mp4item.h
mp4/mp4properties.h
mp4/mp4coverart.h
)
if(WITH_ASF)
set(tag_HDRS ${tag_HDRS}
asf/asffile.h
asf/asfproperties.h
asf/asftag.h
asf/asfattribute.h
asf/asfpicture.h
)
endif()
if(WITH_MP4)
set(tag_HDRS ${tag_HDRS}
mp4/mp4file.h
mp4/mp4atom.h
mp4/mp4tag.h
mp4/mp4item.h
mp4/mp4properties.h
mp4/mp4coverart.h
)
endif()
set(mpeg_SRCS
mpeg/mpegfile.cpp
@ -254,17 +246,12 @@ set(tag_LIB_SRCS
${mpeg_SRCS} ${id3v1_SRCS} ${id3v2_SRCS} ${frames_SRCS} ${ogg_SRCS}
${vorbis_SRCS} ${oggflacs_SRCS} ${mpc_SRCS} ${ape_SRCS} ${toolkit_SRCS} ${flacs_SRCS}
${wavpack_SRCS} ${speex_SRCS} ${trueaudio_SRCS} ${riff_SRCS} ${aiff_SRCS} ${wav_SRCS}
${asf_SRCS} ${mp4_SRCS}
tag.cpp
tagunion.cpp
fileref.cpp
audioproperties.cpp
)
if(WITH_ASF)
set(tag_LIB_SRCS ${tag_LIB_SRCS} ${asf_SRCS})
endif()
if(WITH_MP4)
set(tag_LIB_SRCS ${tag_LIB_SRCS} ${mp4_SRCS})
endif()
add_library(tag ${tag_LIB_SRCS} ${tag_HDRS})

View File

@ -27,8 +27,6 @@
#include <config.h>
#endif
#ifdef WITH_ASF
#include <taglib.h>
#include <tdebug.h>
#include "asfattribute.h"
@ -353,4 +351,3 @@ void ASF::Attribute::setStream(int value)
d->stream = value;
}
#endif

View File

@ -27,8 +27,6 @@
#include <config.h>
#endif
#ifdef WITH_ASF
#include <tdebug.h>
#include <tbytevectorlist.h>
#include <tstring.h>
@ -607,4 +605,3 @@ ByteVector ASF::File::renderString(const String &str, bool includeLength)
return data;
}
#endif

View File

@ -27,8 +27,6 @@
#include <config.h>
#endif
#ifdef WITH_ASF
#include <taglib.h>
#include <tdebug.h>
#include "asfattribute.h"
@ -182,4 +180,3 @@ ASF::Picture ASF::Picture::fromInvalid()
return ret;
}
#endif

View File

@ -27,8 +27,6 @@
#include <config.h>
#endif
#ifdef WITH_ASF
#include <tdebug.h>
#include <tstring.h>
#include "asfproperties.h"
@ -115,4 +113,3 @@ void ASF::Properties::setEncrypted(bool encrypted)
d->encrypted = encrypted;
}
#endif

View File

@ -27,8 +27,6 @@
#include <config.h>
#endif
#ifdef WITH_ASF
#include "asftag.h"
using namespace TagLib;
@ -198,4 +196,3 @@ bool ASF::Tag::isEmpty() const
d->attributeListMap.isEmpty();
}
#endif

View File

@ -147,17 +147,13 @@ StringList FileRef::defaultFileExtensions()
l.append("wv");
l.append("spx");
l.append("tta");
#ifdef TAGLIB_WITH_MP4
l.append("m4a");
l.append("m4b");
l.append("m4p");
l.append("3g2");
l.append("mp4");
#endif
#ifdef TAGLIB_WITH_ASF
l.append("wma");
l.append("asf");
#endif
l.append("aif");
l.append("aiff");
l.append("wav");
@ -246,14 +242,10 @@ File *FileRef::create(FileName fileName, bool readAudioProperties,
return new Ogg::Speex::File(fileName, readAudioProperties, audioPropertiesStyle);
if(ext == "TTA")
return new TrueAudio::File(fileName, readAudioProperties, audioPropertiesStyle);
#ifdef TAGLIB_WITH_MP4
if(ext == "M4A" || ext == "M4B" || ext == "M4P" || ext == "MP4" || ext == "3G2")
return new MP4::File(fileName, readAudioProperties, audioPropertiesStyle);
#endif
#ifdef TAGLIB_WITH_ASF
if(ext == "WMA" || ext == "ASF")
return new ASF::File(fileName, readAudioProperties, audioPropertiesStyle);
#endif
if(ext == "AIF" || ext == "AIFF")
return new RIFF::AIFF::File(fileName, readAudioProperties, audioPropertiesStyle);
if(ext == "WAV")

View File

@ -27,8 +27,6 @@
#include <config.h>
#endif
#ifdef WITH_MP4
#include <tdebug.h>
#include <tstring.h>
#include "mp4atom.h"
@ -198,4 +196,3 @@ MP4::Atoms::path(const char *name1, const char *name2, const char *name3, const
return path;
}
#endif

View File

@ -27,8 +27,6 @@
#include <config.h>
#endif
#ifdef WITH_MP4
#include <taglib.h>
#include <tdebug.h>
#include "mp4coverart.h"
@ -86,4 +84,3 @@ MP4::CoverArt::data() const
return d->data;
}
#endif

View File

@ -27,8 +27,6 @@
#include <config.h>
#endif
#ifdef WITH_MP4
#include <tdebug.h>
#include <tstring.h>
#include "mp4atom.h"
@ -149,4 +147,3 @@ MP4::File::save()
return d->tag->save();
}
#endif

View File

@ -27,8 +27,6 @@
#include <config.h>
#endif
#ifdef WITH_MP4
#include <taglib.h>
#include <tdebug.h>
#include "mp4item.h"
@ -146,4 +144,3 @@ MP4::Item::isValid() const
return d->valid;
}
#endif

View File

@ -27,8 +27,6 @@
#include <config.h>
#endif
#ifdef WITH_MP4
#include <tdebug.h>
#include <tstring.h>
#include "mp4file.h"
@ -186,4 +184,3 @@ MP4::Properties::isEncrypted() const
return d->encrypted;
}
#endif

View File

@ -27,8 +27,6 @@
#include <config.h>
#endif
#ifdef WITH_MP4
#include <tdebug.h>
#include <tstring.h>
#include "mp4atom.h"
@ -638,4 +636,3 @@ MP4::Tag::itemListMap()
return d->items;
}
#endif

View File

@ -1,4 +1,4 @@
/* taglib_config.h. Generated by cmake from taglib_config.h.cmake */
#cmakedefine TAGLIB_WITH_ASF 1
#cmakedefine TAGLIB_WITH_MP4 1
#define TAGLIB_WITH_ASF 1
#define TAGLIB_WITH_MP4 1