aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2006-10-11 18:08:08 +0000
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2006-10-11 18:08:08 +0000
commit89eb9efed2ba392eb08dabab9aaa8a8c18d0393d (patch)
tree588ae0ac1f4ef007429f7554d2ef7326448232ef
parent9627465047b95a09a63530aa0d87a1e7d4a77130 (diff)
downloadpaludis-89eb9efed2ba392eb08dabab9aaa8a8c18d0393d.tar.gz
paludis-89eb9efed2ba392eb08dabab9aaa8a8c18d0393d.tar.xz
More visibility work. Force disable visibility for now, since we're triggering a ld.so bug
-rw-r--r--configure.ac22
-rw-r--r--paludis/environment/default/Makefile.am2
-rw-r--r--paludis/environment/default/default_config.hh4
-rw-r--r--paludis/environment/default/default_environment.hh2
-rw-r--r--paludis/environment/no_config/Makefile.am2
-rw-r--r--paludis/environment/no_config/no_config_environment.cc2
-rw-r--r--paludis/environment/no_config/no_config_environment.hh2
-rw-r--r--paludis/environment/test/Makefile.am2
-rw-r--r--paludis/environment/test/test_environment.hh2
-rw-r--r--paludis/qa/Makefile.am.m42
-rw-r--r--paludis/qa/check.hh2
-rw-r--r--paludis/qa/check_result.hh2
-rw-r--r--paludis/qa/ebuild_check.hh4
-rw-r--r--paludis/qa/file_check.hh4
-rw-r--r--paludis/repositories/cran/Makefile.am2
-rw-r--r--paludis/repositories/cran/cran_dep_parser.hh2
-rw-r--r--paludis/repositories/cran/cran_description.hh6
-rw-r--r--paludis/repositories/cran/cran_installed_repository.cc13
-rw-r--r--paludis/repositories/cran/cran_installed_repository.hh12
-rw-r--r--paludis/repositories/cran/cran_repository.cc12
-rw-r--r--paludis/repositories/cran/cran_repository.hh11
-rw-r--r--paludis/repositories/fake/Makefile.am2
-rw-r--r--paludis/repositories/fake/fake_installed_repository.hh2
-rw-r--r--paludis/repositories/fake/fake_repository.hh2
-rw-r--r--paludis/repositories/fake/fake_repository_base.hh2
-rw-r--r--paludis/repositories/nothing/Makefile.am2
-rw-r--r--paludis/repositories/nothing/nothing_repository.cc12
-rw-r--r--paludis/repositories/nothing/nothing_repository.hh9
-rw-r--r--paludis/repositories/portage/Makefile.am2
-rw-r--r--paludis/repositories/portage/glsa.hh6
-rw-r--r--paludis/repositories/portage/make_ebin_repository.cc12
-rw-r--r--paludis/repositories/portage/make_ebin_repository.hh10
-rw-r--r--paludis/repositories/portage/make_ebuild_repository.cc15
-rw-r--r--paludis/repositories/portage/make_ebuild_repository.hh21
-rw-r--r--paludis/repositories/portage/portage_repository.hh2
-rw-r--r--paludis/repositories/portage/portage_repository_ebin_entries.cc11
-rw-r--r--paludis/repositories/portage/portage_repository_ebin_entries.hh12
-rw-r--r--paludis/repositories/portage/portage_repository_ebuild_entries.cc12
-rw-r--r--paludis/repositories/portage/portage_repository_ebuild_entries.hh12
-rw-r--r--paludis/repositories/portage/portage_repository_entries.hh4
-rw-r--r--paludis/repositories/portage/portage_repository_exceptions.hh2
-rw-r--r--paludis/repositories/portage/portage_repository_news.hh4
-rw-r--r--paludis/repositories/portage/portage_repository_profile.hh2
-rw-r--r--paludis/repositories/portage/portage_repository_profile_file.hh2
-rw-r--r--paludis/repositories/portage/portage_repository_sets.hh2
-rw-r--r--paludis/repositories/vdb/Makefile.am2
-rw-r--r--paludis/repositories/vdb/vdb_repository.cc12
-rw-r--r--paludis/repositories/vdb/vdb_repository.hh14
48 files changed, 169 insertions, 133 deletions
diff --git a/configure.ac b/configure.ac
index 025d26c..2f200e2 100644
--- a/configure.ac
+++ b/configure.ac
@@ -246,6 +246,15 @@ then
do
if echo "${LDFLAGS} ${CFLAGS} ${CXXFLAGS}" | grep "$x" >/dev/null ; then
AC_MSG_RESULT([$x])
+ if test $x = "as-needed" ; then
+ echo "You shouldn't have as-needed as a global flag. It makes the linker break" 1>&2
+ echo "legitimate code. For more details, read http://ciaranm.org/show_post.pl?post_id=13" 1>&2
+ fi
+ if test $x = "visibility" ; then
+ echo "Don't use visibility except for applications that're designed for" 1>&2
+ echo "it. At present, Paludis can't be used with visibility because of what" 1>&2
+ echo "appears to be an ld.so bug." 1>&2
+ fi
AC_MSG_ERROR([Bad ricer. No bagel.])
fi
done
@@ -335,12 +344,13 @@ AC_SUBST([PALUDIS_CXXFLAGS_NO_WOLD_STYLE_CAST])
AC_SUBST([PALUDIS_CXXFLAGS_NO_WSHADOW])
AC_SUBST([PALUDIS_CXXFLAGS_NO_WREDUNDANT_DECLS])
-AC_MSG_CHECKING([whether to enable visibility])
-AC_ARG_ENABLE([visibility],
- AS_HELP_STRING([--enable-visibility], [Enable visibility (g++-4.1)]),
- [ENABLE_VISIBILITY=$enableval],
- [ENABLE_VISIBILITY=no])
-AC_MSG_RESULT([$ENABLE_VISIBILITY])
+dnl AC_MSG_CHECKING([whether to enable visibility])
+dnl AC_ARG_ENABLE([visibility],
+dnl AS_HELP_STRING([--enable-visibility], [Enable visibility (g++-4.1)]),
+dnl [ENABLE_VISIBILITY=$enableval],
+dnl [ENABLE_VISIBILITY=no])
+dnl AC_MSG_RESULT([$ENABLE_VISIBILITY])
+ENABLE_VISIBILITY=no
AC_SUBST([ENABLE_VISIBILITY])
if test "x$ENABLE_VISIBILITY" = "xyes" ; then
AC_MSG_CHECKING([for appropriate compiler visibility flags])
diff --git a/paludis/environment/default/Makefile.am b/paludis/environment/default/Makefile.am
index 5f336c9..9ca00d0 100644
--- a/paludis/environment/default/Makefile.am
+++ b/paludis/environment/default/Makefile.am
@@ -1,6 +1,6 @@
CLEANFILES = *~ gmon.out *.gcov *.gcno *.gcda
MAINTAINERCLEANFILES = Makefile.in
-AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@
+AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@ @PALUDIS_CXXFLAGS_VISIBILITY@
DEFS= \
-DSYSCONFDIR=\"$(sysconfdir)\" \
-DLIBEXECDIR=\"$(libexecdir)\" \
diff --git a/paludis/environment/default/default_config.hh b/paludis/environment/default/default_config.hh
index 45e995d..03a09f5 100644
--- a/paludis/environment/default/default_config.hh
+++ b/paludis/environment/default/default_config.hh
@@ -49,7 +49,7 @@ namespace paludis
* \ingroup grpexceptions
* \ingroup grpdefaultconfig
*/
- class DefaultConfigError : public ConfigurationError
+ class PALUDIS_VISIBLE DefaultConfigError : public ConfigurationError
{
public:
/**
@@ -67,7 +67,7 @@ namespace paludis
*
* \ingroup grpdefaultconfig
*/
- class DefaultConfig :
+ class PALUDIS_VISIBLE DefaultConfig :
public InstantiationPolicy<DefaultConfig, instantiation_method::SingletonAsNeededTag>,
private PrivateImplementationPattern<DefaultConfig>
{
diff --git a/paludis/environment/default/default_environment.hh b/paludis/environment/default/default_environment.hh
index 8fbc704..058a246 100644
--- a/paludis/environment/default/default_environment.hh
+++ b/paludis/environment/default/default_environment.hh
@@ -37,7 +37,7 @@ namespace paludis
*
* \ingroup grpdefaultenvironment
*/
- class DefaultEnvironment :
+ class PALUDIS_VISIBLE DefaultEnvironment :
public Environment,
public InstantiationPolicy<DefaultEnvironment, instantiation_method::SingletonAsNeededTag>
{
diff --git a/paludis/environment/no_config/Makefile.am b/paludis/environment/no_config/Makefile.am
index f36efb0..4c45031 100644
--- a/paludis/environment/no_config/Makefile.am
+++ b/paludis/environment/no_config/Makefile.am
@@ -1,7 +1,7 @@
CLEANFILES = *~ gmon.out *.gcov *.gcno *.gcda ihateautomake.cc ihateautomake.o
DISTCLEANFILES = no_config_environment-sr.hh no_config_environment-sr.cc
MAINTAINERCLEANFILES = Makefile.in
-AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@
+AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@ @PALUDIS_CXXFLAGS_VISIBILITY@
DEFS= \
-DSYSCONFDIR=\"$(sysconfdir)\" \
-DLIBEXECDIR=\"$(libexecdir)\" \
diff --git a/paludis/environment/no_config/no_config_environment.cc b/paludis/environment/no_config/no_config_environment.cc
index 7ab925e..b9022fa 100644
--- a/paludis/environment/no_config/no_config_environment.cc
+++ b/paludis/environment/no_config/no_config_environment.cc
@@ -99,6 +99,8 @@ namespace paludis
}
}
};
+
+ /* This goat is for Dave Wickham */
}
NoConfigEnvironment::NoConfigEnvironment(const NoConfigEnvironmentParams & params) :
diff --git a/paludis/environment/no_config/no_config_environment.hh b/paludis/environment/no_config/no_config_environment.hh
index 5215cc2..37837f1 100644
--- a/paludis/environment/no_config/no_config_environment.hh
+++ b/paludis/environment/no_config/no_config_environment.hh
@@ -29,7 +29,7 @@ namespace paludis
{
#include <paludis/environment/no_config/no_config_environment-sr.hh>
- class NoConfigEnvironment :
+ class PALUDIS_VISIBLE NoConfigEnvironment :
private PrivateImplementationPattern<NoConfigEnvironment>,
public Environment
{
diff --git a/paludis/environment/test/Makefile.am b/paludis/environment/test/Makefile.am
index a69574e..b48bf1b 100644
--- a/paludis/environment/test/Makefile.am
+++ b/paludis/environment/test/Makefile.am
@@ -1,6 +1,6 @@
CLEANFILES = *~ gmon.out *.gcov *.gcno *.gcda ihateautomake.cc ihateautomake.o
MAINTAINERCLEANFILES = Makefile.in
-AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@
+AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@ @PALUDIS_CXXFLAGS_VISIBILITY@
DEFS= \
-DSYSCONFDIR=\"$(sysconfdir)\" \
-DLIBEXECDIR=\"$(libexecdir)\" \
diff --git a/paludis/environment/test/test_environment.hh b/paludis/environment/test/test_environment.hh
index 586aa10..d9b1178 100644
--- a/paludis/environment/test/test_environment.hh
+++ b/paludis/environment/test/test_environment.hh
@@ -38,7 +38,7 @@ namespace paludis
*
* \ingroup grptestenvironment
*/
- class TestEnvironment : public Environment
+ class PALUDIS_VISIBLE TestEnvironment : public Environment
{
public:
/**
diff --git a/paludis/qa/Makefile.am.m4 b/paludis/qa/Makefile.am.m4
index 10bd983..705a268 100644
--- a/paludis/qa/Makefile.am.m4
+++ b/paludis/qa/Makefile.am.m4
@@ -91,7 +91,7 @@ CLEANFILES = *~ gmon.out *.gcov *.gcno *.gcda
MAINTAINERCLEANFILES = Makefile.in Makefile.am qa.hh
DISTCLEANFILES = srcleanlist
BUILT_SOURCES = srcleanlist qa.hh
-AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@
+AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@ @PALUDIS_CXXFLAGS_VISIBILITY@
DEFS= \
-DSYSCONFDIR=\"$(sysconfdir)\" \
-DLIBEXECDIR=\"$(libexecdir)\" \
diff --git a/paludis/qa/check.hh b/paludis/qa/check.hh
index ae70588..82a9c47 100644
--- a/paludis/qa/check.hh
+++ b/paludis/qa/check.hh
@@ -38,7 +38,7 @@ namespace paludis
*
* \ingroup QA
*/
- class Check :
+ class PALUDIS_VISIBLE Check :
private InstantiationPolicy<Check, instantiation_method::NonCopyableTag>
{
protected:
diff --git a/paludis/qa/check_result.hh b/paludis/qa/check_result.hh
index 402ecab..c7f2717 100644
--- a/paludis/qa/check_result.hh
+++ b/paludis/qa/check_result.hh
@@ -39,7 +39,7 @@ namespace paludis
*
* \ingroup QA
*/
- class CheckResult
+ class PALUDIS_VISIBLE CheckResult
{
private:
std::list<Message> _messages;
diff --git a/paludis/qa/ebuild_check.hh b/paludis/qa/ebuild_check.hh
index f1b9339..330d8a4 100644
--- a/paludis/qa/ebuild_check.hh
+++ b/paludis/qa/ebuild_check.hh
@@ -36,7 +36,7 @@ namespace paludis
#include <paludis/qa/ebuild_check-sr.hh>
- class EbuildCheck :
+ class PALUDIS_VISIBLE EbuildCheck :
public Check,
public InternalCounted<EbuildCheck>
{
@@ -47,7 +47,7 @@ namespace paludis
virtual CheckResult operator() (const EbuildCheckData &) const = 0;
};
- class NoSuchEbuildCheckTypeError :
+ class PALUDIS_VISIBLE NoSuchEbuildCheckTypeError :
public Exception
{
public:
diff --git a/paludis/qa/file_check.hh b/paludis/qa/file_check.hh
index 877b4cf..fd07fca 100644
--- a/paludis/qa/file_check.hh
+++ b/paludis/qa/file_check.hh
@@ -42,7 +42,7 @@ namespace paludis
*
* \ingroup QA
*/
- class FileCheck :
+ class PALUDIS_VISIBLE FileCheck :
public Check,
public InternalCounted<FileCheck>
{
@@ -53,7 +53,7 @@ namespace paludis
virtual CheckResult operator() (const FSEntry &) const = 0;
};
- class NoSuchFileCheckTypeError :
+ class PALUDIS_VISIBLE NoSuchFileCheckTypeError :
public Exception
{
public:
diff --git a/paludis/repositories/cran/Makefile.am b/paludis/repositories/cran/Makefile.am
index b70a133..cb681c0 100644
--- a/paludis/repositories/cran/Makefile.am
+++ b/paludis/repositories/cran/Makefile.am
@@ -2,7 +2,7 @@ CLEANFILES = *~ gmon.out *.gcov *.gcno *.gcda
DISTCLEANFILES = cran_repository-sr.hh cran_repository-sr.cc
MAINTAINERCLEANFILES = Makefile.in
-AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@
+AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@ @PALUDIS_CXXFLAGS_VISIBILITY@
DEFS= \
-DSYSCONFDIR=\"$(sysconfdir)\" \
-DLIBEXECDIR=\"$(libexecdir)\" \
diff --git a/paludis/repositories/cran/cran_dep_parser.hh b/paludis/repositories/cran/cran_dep_parser.hh
index caa6aa3..69bdd80 100644
--- a/paludis/repositories/cran/cran_dep_parser.hh
+++ b/paludis/repositories/cran/cran_dep_parser.hh
@@ -12,7 +12,7 @@ namespace paludis
*
* \ingroup grpdepparser
*/
- struct CRANDepParser
+ struct PALUDIS_VISIBLE CRANDepParser
{
static DepAtom::ConstPointer parse(const std::string & s);
};
diff --git a/paludis/repositories/cran/cran_description.hh b/paludis/repositories/cran/cran_description.hh
index 2d34ee1..45f354e 100644
--- a/paludis/repositories/cran/cran_description.hh
+++ b/paludis/repositories/cran/cran_description.hh
@@ -28,7 +28,7 @@ namespace paludis
/**
* CRANDescription as used by CRANRepository and CRANInstalledRepository
*/
- struct CRANDescription
+ struct PALUDIS_VISIBLE CRANDescription
{
/// Our package name.
QualifiedPackageName name;
@@ -77,7 +77,7 @@ namespace paludis
*
* \ingroup grpcrandesc
*/
- struct ComparePackage
+ struct PALUDIS_VISIBLE ComparePackage
{
bool operator() (const QualifiedPackageName & c, const CRANDescription & d) const
{
@@ -95,7 +95,7 @@ namespace paludis
*
* \ingroup grpcrandesc
*/
- struct CompareVersion
+ struct PALUDIS_VISIBLE CompareVersion
{
bool operator() (const std::pair<QualifiedPackageName, VersionSpec> & c,
const CRANDescription & d) const
diff --git a/paludis/repositories/cran/cran_installed_repository.cc b/paludis/repositories/cran/cran_installed_repository.cc
index 053315f..a34a1c8 100644
--- a/paludis/repositories/cran/cran_installed_repository.cc
+++ b/paludis/repositories/cran/cran_installed_repository.cc
@@ -584,3 +584,16 @@ CRANInstalledRepository::remove_from_world(const QualifiedPackageName & n) const
std::copy(world_lines.begin(), world_lines.end(),
std::ostream_iterator<std::string>(world_file, "\n"));
}
+
+#ifdef PALUDIS_ENABLE_VISIBILITY
+# pragma GCC visibility push(default)
+#endif
+namespace
+{
+ const RepositoryMaker::RegisterMaker register_cran_installed_repository PALUDIS_ATTRIBUTE((used)) (
+ "cran_installed", &CRANInstalledRepository::make_cran_installed_repository);
+}
+#ifdef PALUDIS_ENABLE_VISIBILITY
+# pragma GCC visibility pop
+#endif
+
diff --git a/paludis/repositories/cran/cran_installed_repository.hh b/paludis/repositories/cran/cran_installed_repository.hh
index c531af5..6f82e17 100644
--- a/paludis/repositories/cran/cran_installed_repository.hh
+++ b/paludis/repositories/cran/cran_installed_repository.hh
@@ -43,7 +43,7 @@ namespace paludis
*
* \ingroup grpcraninstrepository
*/
- class CRANInstalledRepository :
+ class PALUDIS_VISIBLE CRANInstalledRepository :
public Repository,
public RepositoryInstalledInterface,
public RepositoryUninstallableInterface,
@@ -124,7 +124,7 @@ namespace paludis
* \ingroup grpcraninstrepository
* \ingroup grpexceptions
*/
- class CRANInstalledRepositoryConfigurationError : public ConfigurationError
+ class PALUDIS_VISIBLE CRANInstalledRepositoryConfigurationError : public ConfigurationError
{
public:
/**
@@ -132,14 +132,6 @@ namespace paludis
*/
CRANInstalledRepositoryConfigurationError(const std::string & msg) throw ();
};
-
- /**
- * Register the CRAN Installed repository format.
- *
- * \ingroup grpcraninstrepository
- */
- static const RepositoryMaker::RegisterMaker register_cran_installed_repository(
- "cran_installed", &CRANInstalledRepository::make_cran_installed_repository);
}
#endif
diff --git a/paludis/repositories/cran/cran_repository.cc b/paludis/repositories/cran/cran_repository.cc
index e75aace..7ab4ac2 100644
--- a/paludis/repositories/cran/cran_repository.cc
+++ b/paludis/repositories/cran/cran_repository.cc
@@ -623,3 +623,15 @@ CRANRepository::invalidate() const
_imp->invalidate();
}
+#ifdef PALUDIS_ENABLE_VISIBILITY
+# pragma GCC visibility push(default)
+#endif
+namespace
+{
+ const RepositoryMaker::RegisterMaker register_cran_repository PALUDIS_ATTRIBUTE((used)) (
+ "cran", &CRANRepository::make_cran_repository);
+}
+#ifdef PALUDIS_ENABLE_VISIBILITY
+# pragma GCC visibility pop
+#endif
+
diff --git a/paludis/repositories/cran/cran_repository.hh b/paludis/repositories/cran/cran_repository.hh
index 25376b7..fcaf61b 100644
--- a/paludis/repositories/cran/cran_repository.hh
+++ b/paludis/repositories/cran/cran_repository.hh
@@ -43,7 +43,7 @@ namespace paludis
*
* \ingroup grpcranrepository
*/
- class CRANRepository :
+ class PALUDIS_VISIBLE CRANRepository :
public Repository,
public RepositoryInstallableInterface,
public RepositorySyncableInterface,
@@ -124,7 +124,7 @@ namespace paludis
* \ingroup grpexceptions
* \ingroup grpportagerepository
*/
- class CRANRepositoryConfigurationError : public ConfigurationError
+ class PALUDIS_VISIBLE CRANRepositoryConfigurationError : public ConfigurationError
{
public:
/**
@@ -132,13 +132,6 @@ namespace paludis
*/
CRANRepositoryConfigurationError(const std::string & msg) throw ();
};
-
- /**
- * Register CRANRepository.
- */
- static const RepositoryMaker::RegisterMaker register_cran_repository(
- "cran", &CRANRepository::make_cran_repository);
-
}
#endif
diff --git a/paludis/repositories/fake/Makefile.am b/paludis/repositories/fake/Makefile.am
index e7ef33d..820ba2a 100644
--- a/paludis/repositories/fake/Makefile.am
+++ b/paludis/repositories/fake/Makefile.am
@@ -1,7 +1,7 @@
CLEANFILES = *~ gmon.out *.gcov *.gcno *.gcda
MAINTAINERCLEANFILES = Makefile.in
-AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@
+AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@ @PALUDIS_CXXFLAGS_VISIBILITY@
DEFS= \
-DSYSCONFDIR=\"$(sysconfdir)\" \
-DLIBEXECDIR=\"$(libexecdir)\" \
diff --git a/paludis/repositories/fake/fake_installed_repository.hh b/paludis/repositories/fake/fake_installed_repository.hh
index c85eeee..899a916 100644
--- a/paludis/repositories/fake/fake_installed_repository.hh
+++ b/paludis/repositories/fake/fake_installed_repository.hh
@@ -24,7 +24,7 @@
namespace paludis
{
- class FakeInstalledRepository :
+ class PALUDIS_VISIBLE FakeInstalledRepository :
public FakeRepositoryBase,
public RepositoryInstalledInterface
{
diff --git a/paludis/repositories/fake/fake_repository.hh b/paludis/repositories/fake/fake_repository.hh
index 81770a1..a39c42f 100644
--- a/paludis/repositories/fake/fake_repository.hh
+++ b/paludis/repositories/fake/fake_repository.hh
@@ -24,7 +24,7 @@
namespace paludis
{
- class FakeRepository :
+ class PALUDIS_VISIBLE FakeRepository :
public FakeRepositoryBase,
public RepositoryInstallableInterface
{
diff --git a/paludis/repositories/fake/fake_repository_base.hh b/paludis/repositories/fake/fake_repository_base.hh
index 03e3a1f..287e7d6 100644
--- a/paludis/repositories/fake/fake_repository_base.hh
+++ b/paludis/repositories/fake/fake_repository_base.hh
@@ -39,7 +39,7 @@ namespace paludis
* \see FakeInstalledRepository
* \ingroup grpfakerepository
*/
- class FakeRepositoryBase :
+ class PALUDIS_VISIBLE FakeRepositoryBase :
public Repository,
public RepositoryMaskInterface,
public RepositoryUseInterface,
diff --git a/paludis/repositories/nothing/Makefile.am b/paludis/repositories/nothing/Makefile.am
index 191a2c8..54b1338 100644
--- a/paludis/repositories/nothing/Makefile.am
+++ b/paludis/repositories/nothing/Makefile.am
@@ -2,7 +2,7 @@ CLEANFILES = *~ gmon.out *.gcov *.gcno *.gcda
DISTCLEANFILES = nothing_repository-sr.hh nothing_repository-sr.cc
MAINTAINERCLEANFILES = Makefile.in
-AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@
+AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@ @PALUDIS_CXXFLAGS_VISIBILITY@
DEFS= \
-DSYSCONFDIR=\"$(sysconfdir)\" \
-DLIBEXECDIR=\"$(libexecdir)\" \
diff --git a/paludis/repositories/nothing/nothing_repository.cc b/paludis/repositories/nothing/nothing_repository.cc
index ae896d3..4c9127e 100644
--- a/paludis/repositories/nothing/nothing_repository.cc
+++ b/paludis/repositories/nothing/nothing_repository.cc
@@ -242,3 +242,15 @@ NothingRepository::invalidate() const
{
}
+#ifdef PALUDIS_ENABLE_VISIBILITY
+# pragma GCC visibility push(default)
+#endif
+namespace
+{
+ const RepositoryMaker::RegisterMaker register_nothing_repository PALUDIS_ATTRIBUTE((used)) (
+ "nothing", &NothingRepository::make_nothing_repository);
+}
+#ifdef PALUDIS_ENABLE_VISIBILITY
+# pragma GCC visibility pop
+#endif
+
diff --git a/paludis/repositories/nothing/nothing_repository.hh b/paludis/repositories/nothing/nothing_repository.hh
index 28ae2aa..16cc679 100644
--- a/paludis/repositories/nothing/nothing_repository.hh
+++ b/paludis/repositories/nothing/nothing_repository.hh
@@ -42,7 +42,7 @@ namespace paludis
*
* \ingroup grpnothingrepository
*/
- class NothingRepository :
+ class PALUDIS_VISIBLE NothingRepository :
public Repository,
public RepositorySyncableInterface,
private PrivateImplementationPattern<NothingRepository>
@@ -110,13 +110,6 @@ namespace paludis
*/
NothingRepositoryConfigurationError(const std::string & msg) throw ();
};
-
- /**
- * Register NothingRepository.
- */
- static const RepositoryMaker::RegisterMaker register_nothing_repository(
- "nothing", &NothingRepository::make_nothing_repository);
-
}
diff --git a/paludis/repositories/portage/Makefile.am b/paludis/repositories/portage/Makefile.am
index 648169d..3d6ff91 100644
--- a/paludis/repositories/portage/Makefile.am
+++ b/paludis/repositories/portage/Makefile.am
@@ -2,7 +2,7 @@ CLEANFILES = *~ gmon.out *.gcov *.gcno *.gcda
DISTCLEANFILES = portage_repository-sr.hh portage_repository-sr.cc glsa-sr.hh glsa-sr.cc
MAINTAINERCLEANFILES = Makefile.in
-AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@
+AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@ @PALUDIS_CXXFLAGS_VISIBILITY@
DEFS= \
-DSYSCONFDIR=\"$(sysconfdir)\" \
-DLIBEXECDIR=\"$(libexecdir)\" \
diff --git a/paludis/repositories/portage/glsa.hh b/paludis/repositories/portage/glsa.hh
index c612d40..dc25d8f 100644
--- a/paludis/repositories/portage/glsa.hh
+++ b/paludis/repositories/portage/glsa.hh
@@ -34,7 +34,7 @@ namespace paludis
#include <paludis/repositories/portage/glsa-sr.hh>
- class GLSAError :
+ class PALUDIS_VISIBLE GLSAError :
public ConfigurationError
{
public:
@@ -47,7 +47,7 @@ namespace paludis
///\}
};
- class GLSAPackage :
+ class PALUDIS_VISIBLE GLSAPackage :
private PrivateImplementationPattern<GLSAPackage>,
public InternalCounted<GLSAPackage>
{
@@ -71,7 +71,7 @@ namespace paludis
QualifiedPackageName name() const;
};
- class GLSA :
+ class PALUDIS_VISIBLE GLSA :
private PrivateImplementationPattern<GLSA>,
public InternalCounted<GLSA>
{
diff --git a/paludis/repositories/portage/make_ebin_repository.cc b/paludis/repositories/portage/make_ebin_repository.cc
index b4b2ca5..66acaee 100644
--- a/paludis/repositories/portage/make_ebin_repository.cc
+++ b/paludis/repositories/portage/make_ebin_repository.cc
@@ -100,3 +100,15 @@ paludis::make_ebin_repository(
.buildroot(buildroot)));
}
+#ifdef PALUDIS_ENABLE_VISIBILITY
+# pragma GCC visibility push(default)
+#endif
+namespace
+{
+ const RepositoryMaker::RegisterMaker register_portage_ebin_repository PALUDIS_ATTRIBUTE((used)) (
+ "ebin", &make_ebin_repository);
+}
+#ifdef PALUDIS_ENABLE_VISIBILITY
+# pragma GCC visibility pop
+#endif
+
diff --git a/paludis/repositories/portage/make_ebin_repository.hh b/paludis/repositories/portage/make_ebin_repository.hh
index 1569f9a..efcf2ce 100644
--- a/paludis/repositories/portage/make_ebin_repository.hh
+++ b/paludis/repositories/portage/make_ebin_repository.hh
@@ -27,15 +27,7 @@ namespace paludis
CountedPtr<Repository>
make_ebin_repository(const Environment * const,
const PackageDatabase * const,
- AssociativeCollection<std::string, std::string>::ConstPointer);
-
- /**
- * Register PortageRepository for ebins.
- *
- * \ingroup grpportagerepository
- */
- static const RepositoryMaker::RegisterMaker register_portage_ebin_repository(
- "ebin", &make_ebin_repository);
+ AssociativeCollection<std::string, std::string>::ConstPointer) PALUDIS_VISIBLE;
}
diff --git a/paludis/repositories/portage/make_ebuild_repository.cc b/paludis/repositories/portage/make_ebuild_repository.cc
index 6b0dd5a..b43ffed 100644
--- a/paludis/repositories/portage/make_ebuild_repository.cc
+++ b/paludis/repositories/portage/make_ebuild_repository.cc
@@ -142,3 +142,18 @@ paludis::make_portage_repository(
return make_ebuild_repository(env, db, m);
}
+#ifdef PALUDIS_ENABLE_VISIBILITY
+# pragma GCC visibility push(default)
+#endif
+namespace
+{
+ const RepositoryMaker::RegisterMaker register_portage_ebuild_repository PALUDIS_ATTRIBUTE((used)) (
+ "ebuild", &make_ebuild_repository);
+
+ const RepositoryMaker::RegisterMaker register_portage_portage_repository PALUDIS_ATTRIBUTE((used)) (
+ "portage", &make_portage_repository);
+}
+#ifdef PALUDIS_ENABLE_VISIBILITY
+# pragma GCC visibility pop
+#endif
+
diff --git a/paludis/repositories/portage/make_ebuild_repository.hh b/paludis/repositories/portage/make_ebuild_repository.hh
index 4a218e5..83d834f 100644
--- a/paludis/repositories/portage/make_ebuild_repository.hh
+++ b/paludis/repositories/portage/make_ebuild_repository.hh
@@ -27,29 +27,12 @@ namespace paludis
CountedPtr<Repository>
make_ebuild_repository(const Environment * const,
const PackageDatabase * const,
- AssociativeCollection<std::string, std::string>::ConstPointer);
+ AssociativeCollection<std::string, std::string>::ConstPointer) PALUDIS_VISIBLE;
CountedPtr<Repository>
make_portage_repository(const Environment * const,
const PackageDatabase * const,
- AssociativeCollection<std::string, std::string>::ConstPointer);
-
- /**
- * Register PortageRepository for ebuilds.
- *
- * \ingroup grpportagerepository
- */
- static const RepositoryMaker::RegisterMaker register_portage_ebuild_repository(
- "ebuild", &make_ebuild_repository);
-
- /**
- * Register PortageRepository for ebuilds (deprecated format = portage).
- *
- * \ingroup grpportagerepository
- */
- static const RepositoryMaker::RegisterMaker register_portage_portage_repository(
- "portage", &make_portage_repository);
-
+ AssociativeCollection<std::string, std::string>::ConstPointer) PALUDIS_VISIBLE;
}
#endif
diff --git a/paludis/repositories/portage/portage_repository.hh b/paludis/repositories/portage/portage_repository.hh
index f3e805a..fc52d9c 100644
--- a/paludis/repositories/portage/portage_repository.hh
+++ b/paludis/repositories/portage/portage_repository.hh
@@ -44,7 +44,7 @@ namespace paludis
*
* \ingroup grpportagerepository
*/
- class PortageRepository :
+ class PALUDIS_VISIBLE PortageRepository :
public Repository,
public RepositoryMaskInterface,
public RepositoryUseInterface,
diff --git a/paludis/repositories/portage/portage_repository_ebin_entries.cc b/paludis/repositories/portage/portage_repository_ebin_entries.cc
index 3489abd..de948c6 100644
--- a/paludis/repositories/portage/portage_repository_ebin_entries.cc
+++ b/paludis/repositories/portage/portage_repository_ebin_entries.cc
@@ -365,4 +365,15 @@ PortageRepositoryEbinEntries::make_portage_repository_ebin_entries(
return Pointer(new PortageRepositoryEbinEntries(e, r, p));
}
+#ifdef PALUDIS_ENABLE_VISIBILITY
+# pragma GCC visibility push(default)
+#endif
+namespace
+{
+ const PortageRepositoryEntriesMaker::RegisterMaker register_portage_repository_ebin_entries PALUDIS_ATTRIBUTE((used)) (
+ "ebin", &PortageRepositoryEbinEntries::make_portage_repository_ebin_entries);
+}
+#ifdef PALUDIS_ENABLE_VISIBILITY
+# pragma GCC visibility pop
+#endif
diff --git a/paludis/repositories/portage/portage_repository_ebin_entries.hh b/paludis/repositories/portage/portage_repository_ebin_entries.hh
index a2062be..bc7eda7 100644
--- a/paludis/repositories/portage/portage_repository_ebin_entries.hh
+++ b/paludis/repositories/portage/portage_repository_ebin_entries.hh
@@ -40,7 +40,7 @@ namespace paludis
*
* \ingroup grpportagerepository
*/
- class PortageRepositoryEbinEntries :
+ class PALUDIS_VISIBLE PortageRepositoryEbinEntries :
public PortageRepositoryEntries,
private PrivateImplementationPattern<PortageRepositoryEbinEntries>
{
@@ -65,16 +65,6 @@ namespace paludis
virtual void install(const QualifiedPackageName &, const VersionSpec &,
const InstallOptions &, PortageRepositoryProfile::ConstPointer) const;
};
-
- /**
- * Register PortageRepositoryEbinEntries.
- *
- * \ingroup grpportagerepository
- */
- static const PortageRepositoryEntriesMaker::RegisterMaker register_portage_repository_ebin_entries(
- "ebin", &PortageRepositoryEbinEntries::make_portage_repository_ebin_entries);
-
-
}
#endif
diff --git a/paludis/repositories/portage/portage_repository_ebuild_entries.cc b/paludis/repositories/portage/portage_repository_ebuild_entries.cc
index a80398c..562e93c 100644
--- a/paludis/repositories/portage/portage_repository_ebuild_entries.cc
+++ b/paludis/repositories/portage/portage_repository_ebuild_entries.cc
@@ -542,3 +542,15 @@ PortageRepositoryEbuildEntries::make_portage_repository_ebuild_entries(
return Pointer(new PortageRepositoryEbuildEntries(e, r, p));
}
+#ifdef PALUDIS_ENABLE_VISIBILITY
+# pragma GCC visibility push(default)
+#endif
+namespace
+{
+ const PortageRepositoryEntriesMaker::RegisterMaker register_portage_repository_ebuild_entries PALUDIS_ATTRIBUTE((used)) (
+ "ebuild", &PortageRepositoryEbuildEntries::make_portage_repository_ebuild_entries);
+}
+#ifdef PALUDIS_ENABLE_VISIBILITY
+# pragma GCC visibility pop
+#endif
+
diff --git a/paludis/repositories/portage/portage_repository_ebuild_entries.hh b/paludis/repositories/portage/portage_repository_ebuild_entries.hh
index 1859649..a3fb2f8 100644
--- a/paludis/repositories/portage/portage_repository_ebuild_entries.hh
+++ b/paludis/repositories/portage/portage_repository_ebuild_entries.hh
@@ -40,7 +40,7 @@ namespace paludis
*
* \ingroup grpportagerepository
*/
- class PortageRepositoryEbuildEntries :
+ class PALUDIS_VISIBLE PortageRepositoryEbuildEntries :
public PortageRepositoryEntries,
private PrivateImplementationPattern<PortageRepositoryEbuildEntries>
{
@@ -65,16 +65,6 @@ namespace paludis
virtual void install(const QualifiedPackageName &, const VersionSpec &,
const InstallOptions &, PortageRepositoryProfile::ConstPointer) const;
};
-
- /**
- * Register PortageRepositoryEbuildEntries.
- *
- * \ingroup grpportagerepository
- */
- static const PortageRepositoryEntriesMaker::RegisterMaker register_portage_repository_ebuild_entries(
- "ebuild", &PortageRepositoryEbuildEntries::make_portage_repository_ebuild_entries);
-
-
}
#endif
diff --git a/paludis/repositories/portage/portage_repository_entries.hh b/paludis/repositories/portage/portage_repository_entries.hh
index c1647cd..0ba2f7a 100644
--- a/paludis/repositories/portage/portage_repository_entries.hh
+++ b/paludis/repositories/portage/portage_repository_entries.hh
@@ -47,7 +47,7 @@ namespace paludis
*
* \ingroup grpportagerepository
*/
- class PortageRepositoryEntries :
+ class PALUDIS_VISIBLE PortageRepositoryEntries :
public InternalCounted<PortageRepositoryEntries>
{
private:
@@ -101,7 +101,7 @@ namespace paludis
* \ingroup grpexceptions
* \ingroup grprepository
*/
- class NoSuchPortageRepositoryEntriesType : public ConfigurationError
+ class PALUDIS_VISIBLE NoSuchPortageRepositoryEntriesType : public ConfigurationError
{
public:
/**
diff --git a/paludis/repositories/portage/portage_repository_exceptions.hh b/paludis/repositories/portage/portage_repository_exceptions.hh
index 710f558..945182e 100644
--- a/paludis/repositories/portage/portage_repository_exceptions.hh
+++ b/paludis/repositories/portage/portage_repository_exceptions.hh
@@ -37,7 +37,7 @@ namespace paludis
* \ingroup grpexceptions
* \ingroup grpportagerepository
*/
- class PortageRepositoryConfigurationError :
+ class PALUDIS_VISIBLE PortageRepositoryConfigurationError :
public ConfigurationError
{
public:
diff --git a/paludis/repositories/portage/portage_repository_news.hh b/paludis/repositories/portage/portage_repository_news.hh
index 39587ab..2a7dacb 100644
--- a/paludis/repositories/portage/portage_repository_news.hh
+++ b/paludis/repositories/portage/portage_repository_news.hh
@@ -41,7 +41,7 @@ namespace paludis
*
* \ingroup grpportagerepository
*/
- class PortageRepositoryNews :
+ class PALUDIS_VISIBLE PortageRepositoryNews :
private PrivateImplementationPattern<PortageRepositoryNews>,
private InstantiationPolicy<PortageRepositoryNews, instantiation_method::NonCopyableTag>,
public InternalCounted<PortageRepositoryNews>
@@ -64,7 +64,7 @@ namespace paludis
*
* \ingroup grpnewsconfigfile
*/
- class NewsFile :
+ class PALUDIS_VISIBLE NewsFile :
protected ConfigFile,
private PrivateImplementationPattern<NewsFile>
{
diff --git a/paludis/repositories/portage/portage_repository_profile.hh b/paludis/repositories/portage/portage_repository_profile.hh
index b809bd4..c1520dd 100644
--- a/paludis/repositories/portage/portage_repository_profile.hh
+++ b/paludis/repositories/portage/portage_repository_profile.hh
@@ -45,7 +45,7 @@ namespace paludis
*
* \ingroup grpportagerepository
*/
- class PortageRepositoryProfile :
+ class PALUDIS_VISIBLE PortageRepositoryProfile :
private PrivateImplementationPattern<PortageRepositoryProfile>,
private InstantiationPolicy<PortageRepositoryProfile, instantiation_method::NonCopyableTag>,
public InternalCounted<PortageRepositoryProfile>
diff --git a/paludis/repositories/portage/portage_repository_profile_file.hh b/paludis/repositories/portage/portage_repository_profile_file.hh
index c06aa13..2cda5ed 100644
--- a/paludis/repositories/portage/portage_repository_profile_file.hh
+++ b/paludis/repositories/portage/portage_repository_profile_file.hh
@@ -27,7 +27,7 @@
namespace paludis
{
- class ProfileFile :
+ class PALUDIS_VISIBLE ProfileFile :
private PrivateImplementationPattern<ProfileFile>
{
public:
diff --git a/paludis/repositories/portage/portage_repository_sets.hh b/paludis/repositories/portage/portage_repository_sets.hh
index d80a297..85b361b 100644
--- a/paludis/repositories/portage/portage_repository_sets.hh
+++ b/paludis/repositories/portage/portage_repository_sets.hh
@@ -40,7 +40,7 @@ namespace paludis
*
* \ingroup grpportagerepository
*/
- class PortageRepositorySets :
+ class PALUDIS_VISIBLE PortageRepositorySets :
private PrivateImplementationPattern<PortageRepositorySets>,
private InstantiationPolicy<PortageRepositorySets, instantiation_method::NonCopyableTag>,
public InternalCounted<PortageRepositorySets>
diff --git a/paludis/repositories/vdb/Makefile.am b/paludis/repositories/vdb/Makefile.am
index 6ecdd05..5be12db 100644
--- a/paludis/repositories/vdb/Makefile.am
+++ b/paludis/repositories/vdb/Makefile.am
@@ -2,7 +2,7 @@ CLEANFILES = *~ gmon.out *.gcov *.gcno *.gcda
DISTCLEANFILES = vdb_repository-sr.hh vdb_repository-sr.cc
MAINTAINERCLEANFILES = Makefile.in
-AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@
+AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@ @PALUDIS_CXXFLAGS_VISIBILITY@
DEFS= \
-DSYSCONFDIR=\"$(sysconfdir)\" \
-DLIBEXECDIR=\"$(libexecdir)\" \
diff --git a/paludis/repositories/vdb/vdb_repository.cc b/paludis/repositories/vdb/vdb_repository.cc
index 73d3b0a..2b3e163 100644
--- a/paludis/repositories/vdb/vdb_repository.cc
+++ b/paludis/repositories/vdb/vdb_repository.cc
@@ -1165,3 +1165,15 @@ VDBRepository::do_use_expand_value(const UseFlagName & u) const
return u;
}
+#ifdef PALUDIS_ENABLE_VISIBILITY
+# pragma GCC visibility push(default)
+#endif
+namespace
+{
+ const RepositoryMaker::RegisterMaker register_vdb_repository PALUDIS_ATTRIBUTE((used)) (
+ "vdb", &VDBRepository::make_vdb_repository);
+}
+#ifdef PALUDIS_ENABLE_VISIBILITY
+# pragma GCC visibility pop
+#endif
+
diff --git a/paludis/repositories/vdb/vdb_repository.hh b/paludis/repositories/vdb/vdb_repository.hh
index 4144ec7..a1574ed 100644
--- a/paludis/repositories/vdb/vdb_repository.hh
+++ b/paludis/repositories/vdb/vdb_repository.hh
@@ -44,7 +44,7 @@ namespace paludis
*
* \ingroup grpvdbrepository
*/
- class VDBRepository :
+ class PALUDIS_VISIBLE VDBRepository :
public Repository,
public RepositoryInstalledInterface,
public RepositoryUseInterface,
@@ -146,7 +146,7 @@ namespace paludis
* \ingroup grpvdbrepository
* \ingroup grpexceptions
*/
- class VDBRepositoryConfigurationError : public ConfigurationError
+ class PALUDIS_VISIBLE VDBRepositoryConfigurationError : public ConfigurationError
{
public:
/**
@@ -161,7 +161,7 @@ namespace paludis
* \ingroup grpvdbrepository
* \ingroup grpexceptions
*/
- class VDBRepositoryKeyReadError : public ConfigurationError
+ class PALUDIS_VISIBLE VDBRepositoryKeyReadError : public ConfigurationError
{
public:
/**
@@ -169,14 +169,6 @@ namespace paludis
*/
VDBRepositoryKeyReadError(const std::string & msg) throw ();
};
-
- /**
- * Register the VDB repository format.
- *
- * \ingroup grpvdbrepository
- */
- static const RepositoryMaker::RegisterMaker register_vdb_repository(
- "vdb", &VDBRepository::make_vdb_repository);
}
#endif