From b38631b16b3340217b216f6db1abb3a8e304993a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sl=C3=A1vek=20Banko?= Date: Fri, 28 Feb 2020 04:35:53 +0100 Subject: Fix support for GCC hidden visibility. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Slávek Banko (cherry picked from commit 7ee42b7b38da55a4c297397e4ad2f29702a14f4c) --- amarok/src/amarok.h | 6 +++--- amarok/src/collectionbrowser.h | 4 ++-- amarok/src/collectiondb.h | 10 +++++----- amarok/src/debug.h | 9 ++++++--- amarok/src/k3bexporter.h | 4 ++-- amarok/src/mediabrowser.h | 18 +++++++++--------- amarok/src/metadata/audible/CMakeLists.txt | 1 + amarok/src/metadata/audible/Makefile.am | 2 +- amarok/src/metadata/audible/taglib_audiblefile.h | 8 +++++--- amarok/src/metadata/tplugins.h | 3 +++ amarok/src/playlistbrowser.h | 11 ++++++----- amarok/src/plugin/pluginconfig.h | 6 ++++-- amarok/src/statusbar/progressBar.h | 3 ++- amarok/src/statusbar/statusBarBase.h | 4 ++-- amarok/src/tagdialog.h | 9 +++++---- amarok/src/threadmanager.h | 6 ++++-- 16 files changed, 60 insertions(+), 44 deletions(-) diff --git a/amarok/src/amarok.h b/amarok/src/amarok.h index 03b8e31b..955f3b3a 100644 --- a/amarok/src/amarok.h +++ b/amarok/src/amarok.h @@ -172,7 +172,7 @@ namespace Amarok * See bug #103750 for more information. */ //TODO ugly hack, fix TDEProcess for KDE 4.0 - void closeOpenFiles(int out, int in, int err); //defined in scriptmanager.cpp + LIBAMAROK_EXPORT void closeOpenFiles(int out, int in, int err); //defined in scriptmanager.cpp /** * Returns internal code for database type, DbConnection::sqlite, DbConnection::mysql, or DbConnection::postgresql @@ -255,14 +255,14 @@ namespace Amarok * @param url the url. * @return The url of the proxy, or a empty string if no proxy should be used. */ - TQString proxyForUrl(const TQString& url); + LIBAMAROK_EXPORT TQString proxyForUrl(const TQString& url); /** * Returns the proxy that should be used for a given protocol. * @param protocol the protocol. * @return The url of the proxy, or a empty string if no proxy should be used. */ - TQString proxyForProtocol(const TQString& protocol); + LIBAMAROK_EXPORT TQString proxyForProtocol(const TQString& protocol); //////////////////////////////////////////////////////////////////////////////// // class Amarok::ProcIO diff --git a/amarok/src/collectionbrowser.h b/amarok/src/collectionbrowser.h index e5e60ee1..09d5a60d 100644 --- a/amarok/src/collectionbrowser.h +++ b/amarok/src/collectionbrowser.h @@ -110,7 +110,7 @@ class CollectionBrowser: public TQVBox bool m_returnPressed; - static CollectionBrowser *s_instance; + LIBAMAROK_EXPORT static CollectionBrowser *s_instance; // for CatMenuId friend class CollectionItem; @@ -216,7 +216,7 @@ class CollectionView : public TDEListView, public DropProxyTarget int viewMode() const { return m_viewMode; } // Transform "The Who" -> "Who, The" or the other way - static void manipulateThe( TQString &str, bool reverse ); + LIBAMAROK_EXPORT static void manipulateThe( TQString &str, bool reverse ); void setShowDivider(bool show); diff --git a/amarok/src/collectiondb.h b/amarok/src/collectiondb.h index 16ab29a6..edc39f75 100644 --- a/amarok/src/collectiondb.h +++ b/amarok/src/collectiondb.h @@ -751,10 +751,10 @@ class QueryBuilder // Likewise, modes between and notBetween are only supported for numeric filters enum qBuilderFilter { modeNormal = 0, modeLess = 1, modeGreater = 2, modeEndMatch = 3, modeBeginMatch = 4, modeBetween = 5, modeNotBetween = 6}; - QueryBuilder(); + LIBAMAROK_EXPORT QueryBuilder(); - void addReturnValue( int table, TQ_INT64 value, bool caseSensitive = false /* unless value refers to a string */ ); - void addReturnFunctionValue( int function, int table, TQ_INT64 value); + LIBAMAROK_EXPORT void addReturnValue( int table, TQ_INT64 value, bool caseSensitive = false /* unless value refers to a string */ ); + LIBAMAROK_EXPORT void addReturnFunctionValue( int function, int table, TQ_INT64 value); uint countReturnValues(); // Note: the filter chain begins in AND mode @@ -774,7 +774,7 @@ class QueryBuilder void excludeFilter( int tables, TQ_INT64 value, const TQString& filter, int mode = modeNormal, bool exact = false ); void addMatch( int tables, const TQString& match, bool interpretUnknown = true, bool caseSensitive = true ); - void addMatch( int tables, TQ_INT64 value, const TQString& match, bool interpretUnknown = true, bool caseSensitive = true ); + LIBAMAROK_EXPORT void addMatch( int tables, TQ_INT64 value, const TQString& match, bool interpretUnknown = true, bool caseSensitive = true ); void addMatches( int tables, const TQStringList& match, bool interpretUnknown = true, bool caseSensitive = true ); void excludeMatch( int tables, const TQString& match ); void having( int table, TQ_INT64 value, int function, int mode, const TQString& match ); @@ -812,7 +812,7 @@ class QueryBuilder TQString query( bool withDeviceidPlaceholder = false ) { buildQuery( withDeviceidPlaceholder ); return m_query; }; void clear(); - TQStringList run(); + LIBAMAROK_EXPORT TQStringList run(); // Transform a string table.value "field" into enum values // @return true if we succeeded diff --git a/amarok/src/debug.h b/amarok/src/debug.h index c9163a36..6fe48cc0 100644 --- a/amarok/src/debug.h +++ b/amarok/src/debug.h @@ -12,6 +12,9 @@ #include #include +#include "amarok_export.h" + + class TQApplication; extern TQApplication *tqApp; ///@see Debug::Indent @@ -46,7 +49,7 @@ extern TQApplication *tqApp; ///@see Debug::Indent * @see ListStream */ -namespace Debug +namespace Debug LIBAMAROK_EXPORT { extern TQMutex mutex; // defined in app.cpp @@ -133,7 +136,7 @@ using Debug::DebugStream; #define AMAROK_DEPRECATED warning() << "DEPRECATED: " << __PRETTY_FUNCTION__ << endl; -namespace Debug +namespace Debug LIBAMAROK_EXPORT { /** * @class Debug::Block @@ -230,7 +233,7 @@ namespace Debug #include -namespace Debug +namespace Debug LIBAMAROK_EXPORT { /** * @class Debug::List diff --git a/amarok/src/k3bexporter.h b/amarok/src/k3bexporter.h index 5e709f78..2e62618e 100644 --- a/amarok/src/k3bexporter.h +++ b/amarok/src/k3bexporter.h @@ -61,7 +61,7 @@ public: * @param openmode The mode of the album * @param album The album to export */ - void exportAlbum( const TQString &album, int openmode=-1 ); + LIBAMAROK_EXPORT void exportAlbum( const TQString &album, int openmode=-1 ); /** * Exports the album @p album by artist @ artist to K3B. The mode @p openmode will be used @@ -75,7 +75,7 @@ public: * @param openmode The mode of the album * @param artist The artists which tracks to export */ - void exportArtist( const TQString &artist, int openmode=-1 ); + LIBAMAROK_EXPORT void exportArtist( const TQString &artist, int openmode=-1 ); /** * Exports all tracks of the composer @p composer to K3B. The mode @p openmode will be used diff --git a/amarok/src/mediabrowser.h b/amarok/src/mediabrowser.h index cbf5bd40..2b8a9c38 100644 --- a/amarok/src/mediabrowser.h +++ b/amarok/src/mediabrowser.h @@ -144,7 +144,7 @@ class MediaQueue : public TDEListView, public DropProxyTarget void syncPlaylist( const TQString &playlistName, const TQString &sql, bool loading=false ); void syncPlaylist( const TQString &playlistName, const KURL &url, bool loading=false ); void addURL( const KURL& url, MetaBundle *bundle=NULL, const TQString &playlistName=TQString() ); - void addURL( const KURL& url, MediaItem *item ); + LIBAMAROK_EXPORT void addURL( const KURL& url, MediaItem *item ); void addURLs( const KURL::List urls, const TQString &playlistName=TQString() ); void URLsAdded(); // call after finishing adding single urls @@ -169,10 +169,10 @@ class MediaQueue : public TDEListView, public DropProxyTarget }; -class MediaBrowser : public TQVBox +class LIBAMAROK_EXPORT MediaBrowser : public TQVBox { Q_OBJECT - + friend class DeviceConfigureDialog; friend class MediaDevice; friend class MediaView; @@ -184,8 +184,8 @@ class MediaBrowser : public TQVBox enum { CONNECT, DISCONNECT, TRANSFER, CONFIGURE, CUSTOM }; static bool isAvailable(); - LIBAMAROK_EXPORT static MediaBrowser *instance() { return s_instance; } - LIBAMAROK_EXPORT static MediaQueue *queue() { return s_instance ? s_instance->m_queue : 0; } + static MediaBrowser *instance() { return s_instance; } + static MediaQueue *queue() { return s_instance ? s_instance->m_queue : 0; } MediaBrowser( const char *name ); virtual ~MediaBrowser(); @@ -244,7 +244,7 @@ class MediaBrowser : public TQVBox KLineEdit* m_searchEdit; TQTimer *m_timer; - LIBAMAROK_EXPORT static MediaBrowser *s_instance; + static MediaBrowser *s_instance; TQValueList m_devices; TQValueList::iterator m_currentDevice; @@ -280,7 +280,7 @@ class MediaBrowser : public TQVBox class MediaView : public TDEListView { Q_OBJECT - + friend class MediaBrowser; friend class MediaDevice; @@ -295,7 +295,7 @@ class MediaView : public TDEListView MediaView( TQWidget *parent, MediaDevice *device ); virtual ~MediaView(); LIBAMAROK_EXPORT KURL::List nodeBuildDragList( MediaItem* item, int flags=OnlySelected ); - int getSelectedLeaves(MediaItem *parent, TQPtrList *list, int flags=OnlySelected ); + LIBAMAROK_EXPORT int getSelectedLeaves(MediaItem *parent, TQPtrList *list, int flags=OnlySelected ); LIBAMAROK_EXPORT MediaItem *newDirectory( MediaItem* parent ); bool setFilter( const TQString &filter, MediaItem *parent=NULL ); @@ -328,7 +328,7 @@ class MediaView : public TDEListView class LIBAMAROK_EXPORT MediaDevice : public TQObject, public Amarok::Plugin { Q_OBJECT - + friend class DeviceConfigureDialog; friend class TransferDialog; friend class MediaBrowser; diff --git a/amarok/src/metadata/audible/CMakeLists.txt b/amarok/src/metadata/audible/CMakeLists.txt index 304025ee..db20b9ce 100644 --- a/amarok/src/metadata/audible/CMakeLists.txt +++ b/amarok/src/metadata/audible/CMakeLists.txt @@ -11,6 +11,7 @@ include_directories( ${CMAKE_BINARY_DIR} + ${CMAKE_SOURCE_DIR}/amarok/src ${TDE_INCLUDE_DIR} ${TQT_INCLUDE_DIRS} ${TAGLIB_INCLUDE_DIRS} diff --git a/amarok/src/metadata/audible/Makefile.am b/amarok/src/metadata/audible/Makefile.am index 302eeb88..c0d95587 100644 --- a/amarok/src/metadata/audible/Makefile.am +++ b/amarok/src/metadata/audible/Makefile.am @@ -1,6 +1,6 @@ SUBDIRS = -INCLUDES = $(all_includes) $(TAGLIB_CFLAGS) +INCLUDES = -I$(top_srcdir)/amarok/src $(all_includes) $(TAGLIB_CFLAGS) METASOURCES = AUTO libtagaudible_la_LDFLAGS = $(all_libraries) noinst_LTLIBRARIES = libtagaudible.la diff --git a/amarok/src/metadata/audible/taglib_audiblefile.h b/amarok/src/metadata/audible/taglib_audiblefile.h index c1860ae0..e5440bf4 100644 --- a/amarok/src/metadata/audible/taglib_audiblefile.h +++ b/amarok/src/metadata/audible/taglib_audiblefile.h @@ -26,6 +26,8 @@ #ifndef TAGLIB_AUDIBLEFILE_H #define TAGLIB_AUDIBLEFILE_H +#include "amarok_export.h" + #include #include "audibleproperties.h" #include "audibletag.h" @@ -44,14 +46,14 @@ namespace TagLib { * file's audio properties will also be read using \a propertiesStyle. If * false, \a propertiesStyle is ignored. */ - File(const char *file, bool readProperties = true, + LIBAMAROK_EXPORT File(const char *file, bool readProperties = true, Properties::ReadStyle propertiesStyle = Properties::Average, FILE *fp=NULL); /*! * Destroys this instance of the File. */ - virtual ~File(); + LIBAMAROK_EXPORT virtual ~File(); virtual TagLib::Tag *tag() const; @@ -72,7 +74,7 @@ namespace TagLib { void read(bool readProperties, Properties::ReadStyle propertiesStyle); - Audible::Tag *getAudibleTag() const; + LIBAMAROK_EXPORT Audible::Tag *getAudibleTag() const; bool isAudibleFile() const; diff --git a/amarok/src/metadata/tplugins.h b/amarok/src/metadata/tplugins.h index 1ef356fc..c359b241 100644 --- a/amarok/src/metadata/tplugins.h +++ b/amarok/src/metadata/tplugins.h @@ -22,6 +22,9 @@ #ifndef METADATA_TPLUGIN_H #define METADATA_TPLUGIN_H +#include "amarok_export.h" + +LIBAMAROK_EXPORT void registerTaglibPlugins(); #endif diff --git a/amarok/src/playlistbrowser.h b/amarok/src/playlistbrowser.h index f9d40144..bcb63ef2 100644 --- a/amarok/src/playlistbrowser.h +++ b/amarok/src/playlistbrowser.h @@ -11,6 +11,7 @@ #define PLAYLISTBROWSER_H #include "amarokconfig.h" +#include "amarok_export.h" #include "playlistbrowseritem.h" #include "podcastsettings.h" @@ -42,8 +43,8 @@ class PlaylistTrackItem; class PlaylistBrowser : public TQVBox { - Q_OBJECT - + Q_OBJECT + friend class DynamicMode; friend class PlaylistBrowserView; @@ -73,7 +74,7 @@ class PlaylistBrowser : public TQVBox int loadPlaylist( const TQString &playlist, bool force=false ); void addPodcast( TQListViewItem *parent = 0 ); - void addPodcast( const KURL &url, TQListViewItem *parent = 0 ); + LIBAMAROK_EXPORT void addPodcast( const KURL &url, TQListViewItem *parent = 0 ); void loadPodcastsFromDatabase( PlaylistCategory *p = 0 ); void registerPodcastSettings( const TQString &title, const PodcastSettings *settings ); @@ -136,7 +137,7 @@ class PlaylistBrowser : public TQVBox void loadDynamicItems(); private: - PlaylistBrowser( const char* name=0 ); + LIBAMAROK_EXPORT PlaylistBrowser( const char* name=0 ); void polish(); bool m_polished; @@ -192,7 +193,7 @@ class PlaylistBrowser : public TQVBox static KURL::List recurse( const KURL &url ); - static PlaylistBrowser *s_instance; + LIBAMAROK_EXPORT static PlaylistBrowser *s_instance; PlaylistCategory *m_playlistCategory; PlaylistCategory *m_streamsCategory; diff --git a/amarok/src/plugin/pluginconfig.h b/amarok/src/plugin/pluginconfig.h index 054a12b6..b3d240b3 100644 --- a/amarok/src/plugin/pluginconfig.h +++ b/amarok/src/plugin/pluginconfig.h @@ -4,6 +4,8 @@ #ifndef AMAROK_PLUGINCONFIG_H #define AMAROK_PLUGINCONFIG_H +#include "amarok_export.h" + #include class TQWidget; @@ -14,10 +16,10 @@ namespace Amarok * Class to allow user configuration of your plugin; you provide a GUI widget via view() */ - class PluginConfig : public TQObject + class LIBAMAROK_EXPORT PluginConfig : public TQObject { Q_OBJECT - + signals: /** Emit whenever some view setting is changed by the user */ diff --git a/amarok/src/statusbar/progressBar.h b/amarok/src/statusbar/progressBar.h index fdb8ad85..88e7cfb6 100644 --- a/amarok/src/statusbar/progressBar.h +++ b/amarok/src/statusbar/progressBar.h @@ -24,6 +24,7 @@ #ifndef KDE_PROGRESSBAR_H #define KDE_PROGRESSBAR_H +#include "amarok_export.h" #include class TQLabel; @@ -41,7 +42,7 @@ namespace KDE public: /** @param text a 1-6 word description of the progress operation */ - ProgressBar &setDescription( const TQString &text ); + LIBAMAROK_EXPORT ProgressBar &setDescription( const TQString &text ); /** @param text eg. Scanning, Reading. The state of the operation */ ProgressBar &setStatus( const TQString &text ); diff --git a/amarok/src/statusbar/statusBarBase.h b/amarok/src/statusbar/statusBarBase.h index 93df08e8..eda027ce 100644 --- a/amarok/src/statusbar/statusBarBase.h +++ b/amarok/src/statusbar/statusBarBase.h @@ -76,7 +76,7 @@ namespace KDE * @see KDE::ProgressBar */ - class StatusBar : public TQWidget + class LIBAMAROK_EXPORT StatusBar : public TQWidget { Q_OBJECT @@ -122,7 +122,7 @@ namespace KDE * Generally you should use these, as it is very easy for a user to not notice * statusBar messages. */ - void longMessage( const TQString &text, int type = Information ) LIBAMAROK_EXPORT ; + void longMessage( const TQString &text, int type = Information ); void longMessageThreadSafe( const TQString &text, int type = Information ); diff --git a/amarok/src/tagdialog.h b/amarok/src/tagdialog.h index e1493957..42068a39 100644 --- a/amarok/src/tagdialog.h +++ b/amarok/src/tagdialog.h @@ -7,6 +7,7 @@ #define AMAROK_TAGDIALOG_H #include "config.h" +#include "amarok_export.h" #include "htmlview.h" #include "ktrm.h" @@ -33,16 +34,16 @@ namespace TagLib { class TagDialog : public TagDialogBase { Q_OBJECT - + public: enum Changes { NOCHANGE=0, SCORECHANGED=1, TAGSCHANGED=2, LYRICSCHANGED=4, RATINGCHANGED=8, LABELSCHANGED=16 }; enum Tabs { SUMMARYTAB, TAGSTAB, LYRICSTAB, STATSTAB, LABELSTAB }; - TagDialog( const KURL& url, TQWidget* parent = 0 ); - TagDialog( const KURL::List list, TQWidget* parent = 0 ); - TagDialog( const MetaBundle& mb, PlaylistItem* item, TQWidget* parent = 0 ); + LIBAMAROK_EXPORT TagDialog( const KURL& url, TQWidget* parent = 0 ); + LIBAMAROK_EXPORT TagDialog( const KURL::List list, TQWidget* parent = 0 ); + LIBAMAROK_EXPORT TagDialog( const MetaBundle& mb, PlaylistItem* item, TQWidget* parent = 0 ); ~TagDialog(); void setTab( int id ); diff --git a/amarok/src/threadmanager.h b/amarok/src/threadmanager.h index 2c5c8153..06657535 100644 --- a/amarok/src/threadmanager.h +++ b/amarok/src/threadmanager.h @@ -6,6 +6,8 @@ #ifndef THREADMANAGER_H #define THREADMANAGER_H +#include "amarok_export.h" + #include "debug.h" #include //baseclass #include @@ -77,7 +79,7 @@ /// This class is because moc "is really good" (no nested Q_OBJECT classes) -class JobBase : public TQObject { +class LIBAMAROK_EXPORT JobBase : public TQObject { Q_OBJECT @@ -89,7 +91,7 @@ protected: bool m_aborted; }; -class ThreadManager : public TQObject +class LIBAMAROK_EXPORT ThreadManager : public TQObject { public: class Thread; -- cgit v1.2.1