(initial) win32 export support

git-svn-id: svn://anonsvn.kde.org/home/kde/trunk/kdesupport/taglib@698835 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
This commit is contained in:
Christian Ehrlicher 2007-08-11 08:29:23 +00:00
parent bfa705669c
commit 30a2edc4a3
5 changed files with 47 additions and 5 deletions

View File

@ -118,7 +118,12 @@ if(ZLIB_FOUND)
TARGET_LINK_LIBRARIES(tag ${ZLIB_LIBRARIES})
endif(ZLIB_FOUND)
SET_TARGET_PROPERTIES(tag PROPERTIES VERSION 1.4.0 SOVERSION 1 INSTALL_NAME_DIR ${LIB_INSTALL_DIR})
SET_TARGET_PROPERTIES(tag PROPERTIES
VERSION 1.4.0
SOVERSION 1
INSTALL_NAME_DIR ${LIB_INSTALL_DIR}
DEFINE_SYMBOL MAKE_TAGLIB_LIB
)
INSTALL(TARGETS tag DESTINATION ${LIB_INSTALL_DIR} )
INSTALL( FILES tag.h fileref.h audioproperties.h DESTINATION ${INCLUDE_INSTALL_DIR}/taglib)
INSTALL( FILES tag.h fileref.h audioproperties.h taglib_export.h DESTINATION ${INCLUDE_INSTALL_DIR}/taglib)

View File

@ -22,6 +22,8 @@
#ifndef TAGLIB_AUDIOPROPERTIES_H
#define TAGLIB_AUDIOPROPERTIES_H
#include "taglib_export.h"
namespace TagLib {
//! A simple, abstract interface to common audio properties
@ -33,7 +35,7 @@ namespace TagLib {
* interface that is sufficient for most applications.
*/
class AudioProperties
class TAGLIB_EXPORT AudioProperties
{
public:

View File

@ -24,6 +24,7 @@
#include <tstringlist.h>
#include "taglib_export.h"
#include "audioproperties.h"
namespace TagLib {
@ -52,7 +53,7 @@ namespace TagLib {
* \see addFileTypeResolver()
*/
class FileRef
class TAGLIB_EXPORT FileRef
{
public:

View File

@ -22,6 +22,7 @@
#ifndef TAGLIB_TAG_H
#define TAGLIB_TAG_H
#include "taglib_export.h"
#include "tstring.h"
namespace TagLib {
@ -36,7 +37,7 @@ namespace TagLib {
* in TagLib::AudioProperties, TagLib::File and TagLib::FileRef.
*/
class Tag
class TAGLIB_EXPORT Tag
{
public:

33
taglib/taglib_export.h Normal file
View File

@ -0,0 +1,33 @@
/*
Copyright (c) 2006 Volker Krause <vkrause@kde.org>
This library is free software; you can redistribute it and/or modify it
under the terms of the GNU Library General Public License as published by
the Free Software Foundation; either version 2 of the License, or (at your
option) any later version.
This library is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
License for more details.
You should have received a copy of the GNU Library General Public License
along with this library; see the file COPYING.LIB. If not, write to the
Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
02110-1301, USA.
*/
#ifndef TAGLIB_EXPORT_H
#define TAGLIB_EXPORT_H
#if defined(_WIN32) || defined(_WIN64)
#ifdef MAKE_TAGLIB_LIB
#define TAGLIB_EXPORT __declspec(dllexport)
#else
#define TAGLIB_EXPORT __declspec(dllimport)
#endif
#else
#define TAGLIB_EXPORT
#endif
#endif