aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2009-10-12 18:33:48 +0100
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2009-10-12 18:33:48 +0100
commitf6b265538d15fe0d0b3e7906e0a2ffcd98fec4d5 (patch)
tree1b61a86ee5b9eaf13b2fbf2fda1b3c2febc1c471
parent15792dbb2affa34cb6a9790a53f20ca9a024e72e (diff)
downloadpaludis-f6b265538d15fe0d0b3e7906e0a2ffcd98fec4d5.tar.gz
paludis-f6b265538d15fe0d0b3e7906e0a2ffcd98fec4d5.tar.xz
Don't load repositories from .sos
-rw-r--r--configure.ac26
-rw-r--r--paludis/Makefile.am.m413
-rw-r--r--paludis/repositories/accounts/Makefile.am18
-rw-r--r--paludis/repositories/accounts/registration.cc48
-rw-r--r--paludis/repositories/cran/Makefile.am30
-rw-r--r--paludis/repositories/cran/registration.cc54
-rw-r--r--paludis/repositories/e/Makefile.am54
-rw-r--r--paludis/repositories/e/qa/Makefile.am49
-rw-r--r--paludis/repositories/e/qa/qa.cc20
-rw-r--r--paludis/repositories/e/qa/stray_files_TEST.cc40
-rw-r--r--paludis/repositories/e/registration.cc72
-rw-r--r--paludis/repositories/e/xml_things.cc6
-rw-r--r--paludis/repositories/fake/Makefile.am15
-rw-r--r--paludis/repositories/fake/registration.cc37
-rw-r--r--paludis/repositories/gems/Makefile.am21
-rw-r--r--paludis/repositories/gems/registration.cc54
-rw-r--r--paludis/repositories/unavailable/Makefile.am19
-rw-r--r--paludis/repositories/unavailable/registration.cc34
-rw-r--r--paludis/repositories/unpackaged/Makefile.am20
-rw-r--r--paludis/repositories/unpackaged/registration.cc54
-rw-r--r--paludis/repositories/unwritten/Makefile.am18
-rw-r--r--paludis/repositories/unwritten/registration.cc34
-rw-r--r--paludis/repositories/virtuals/Makefile.am32
-rw-r--r--paludis/repositories/virtuals/registration.cc54
-rw-r--r--paludis/repository_factory-fwd.hh2
-rw-r--r--paludis/repository_factory.cc68
-rw-r--r--paludis/repository_factory.hh6
-rw-r--r--paludis/resolver/Makefile.am4
-rw-r--r--python/Makefile.am2
-rw-r--r--ruby/Makefile.am1
-rw-r--r--src/clients/adjutrix/Makefile.am1
31 files changed, 361 insertions, 545 deletions
diff --git a/configure.ac b/configure.ac
index 5df7fe9..2db7fde 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1284,7 +1284,8 @@ AC_SUBST([VIM_INSTALL_DIR])
dnl }}}
dnl {{{ repositories
-ALL_REPOSITORIES="accounts cran e fake gems unavailable unpackaged unwritten virtuals"
+m4_define(ALL_REPOSITORIES_m4, [accounts,cran,e,fake,gems,unavailable,unpackaged,unwritten,virtuals])
+ALL_REPOSITORIES=`echo ALL_REPOSITORIES_m4 | tr , ' '`
DEFAULT_REPOSITORIES="e fake unavailable unpackaged unwritten virtuals"
AC_MSG_CHECKING([which repositories to build...])
AC_ARG_WITH([repositories],
@@ -1326,10 +1327,27 @@ if echo $repositories | tr ' ' '\n' | grep '^virtuals$' >/dev/null ; then
fi
AM_CONDITIONAL([ENABLE_VIRTUALS_REPOSITORY], test "x$enable_virtuals_repository" = "xyes")
-if echo $repositories | tr ' ' '\n' | grep '^gems$' >/dev/null ; then
- need_syck_check=yes
- need_gem_check=yes
+AC_DEFUN([REPOSITORY_GROUP_IF], [
+if echo $repositories | tr ' ' '\n' | grep '^$1$' >/dev/null ; then
+ AC_DEFINE_UNQUOTED([REPOSITORY_GROUP_IF_$1], [$1], [The $1 repository])
+else
+ AC_DEFINE_UNQUOTED([REPOSITORY_GROUP_IF_$1], [], [Do not have the $1 repository])
fi
+ ])
+
+m4_foreach(reponame, [ALL_REPOSITORIES_m4], [
+REPOSITORY_GROUP_IF(reponame)
+])
+
+AC_DEFINE_UNQUOTED(REPOSITORY_GROUPS_DECLS,
+ m4_foreach(reponame,
+ [ALL_REPOSITORIES_m4],
+ [ struct reponame; ] ) struct semicolon_goes_where { },
+ [Our repository groups])
+
+dnl make sure the code works even if everything's enabled
+REPOSITORY_GROUP_IF(dummy)
+
dnl }}}
dnl {{{ environments
diff --git a/paludis/Makefile.am.m4 b/paludis/Makefile.am.m4
index 9bf8711..d73ebff 100644
--- a/paludis/Makefile.am.m4
+++ b/paludis/Makefile.am.m4
@@ -20,7 +20,6 @@ $1_TEST_LDADD = \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/test/libtest.a \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
libpaludis_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(DYNAMIC_LD_LIBS)
@@ -82,7 +81,7 @@ EXTRA_DIST = about.hh.in Makefile.am.m4 paludis.hh.m4 files.m4 \
testscriptlist srlist srcleanlist selist secleanlist \
hooker.bash \
stripper_TEST_binary.cc
-SUBDIRS = distributions fetchers syncers util selinux . repositories environments args resolver
+SUBDIRS = distributions fetchers syncers util selinux repositories . environments args resolver
BUILT_SOURCES = srcleanlist secleanlist
libpaludis_@PALUDIS_PC_SLOT@_la_SOURCES = filelist
@@ -107,6 +106,15 @@ libpaludissohooks_TEST_@PALUDIS_PC_SLOT@_la_LIBADD = libpaludis_@PALUDIS_PC_SLOT
libpaludis_@PALUDIS_PC_SLOT@_la_LIBADD = \
$(top_builddir)/paludis/selinux/libpaludisselinux_@PALUDIS_PC_SLOT@.la \
+ $(top_builddir)/paludis/repositories/accounts/libpaludisaccountsrepository.la \
+ $(top_builddir)/paludis/repositories/cran/libpaludiscranrepository.la \
+ $(top_builddir)/paludis/repositories/e/libpaludiserepository.la \
+ $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository.la \
+ $(top_builddir)/paludis/repositories/gems/libpaludisgemsrepository.la \
+ $(top_builddir)/paludis/repositories/unavailable/libpaludisunavailablerepository.la \
+ $(top_builddir)/paludis/repositories/unpackaged/libpaludisunpackagedrepository.la \
+ $(top_builddir)/paludis/repositories/unwritten/libpaludisunwrittenrepository.la \
+ $(top_builddir)/paludis/repositories/virtuals/libpaludisvirtualsrepository.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
@DYNAMIC_LD_LIBS@ \
$(PTHREAD_LIBS)
@@ -122,7 +130,6 @@ dep_list_TEST_blockers_LDADD = \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/test/libtest.a \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
libpaludis_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(DYNAMIC_LD_LIBS)
diff --git a/paludis/repositories/accounts/Makefile.am b/paludis/repositories/accounts/Makefile.am
index 9dba7f9..81cfc4b 100644
--- a/paludis/repositories/accounts/Makefile.am
+++ b/paludis/repositories/accounts/Makefile.am
@@ -11,13 +11,9 @@ DEFS= \
-DDATADIR=\"$(datadir)\" \
-DLIBDIR=\"$(libdir)\"
-paludis_repositories_libdir = $(libdir)/paludis/repositories
-paludis_repositories_lib_LTLIBRARIES = libpaludisaccountsrepository_@PALUDIS_PC_SLOT@.la
+noinst_LTLIBRARIES = libpaludisaccountsrepository.la
-paludis_repositories_accounts_includedir = $(includedir)/paludis-$(PALUDIS_PC_SLOT)/paludis/repositories/accounts/
-libpaludisaccountsrepository_@PALUDIS_PC_SLOT@_la_LDFLAGS = -version-info @VERSION_LIB_CURRENT@:@VERSION_LIB_REVISION@:0
-
-paludis_repositories_accounts_include_HEADERS = \
+noinst_HEADERS = \
accounts_exceptions.hh \
accounts_handler.hh \
accounts_repository.hh \
@@ -29,7 +25,7 @@ paludis_repositories_accounts_include_HEADERS = \
accounts_installed_mask.hh \
installed_accounts_id.hh
-libpaludisaccountsrepository_@PALUDIS_PC_SLOT@_la_SOURCES = \
+libpaludisaccountsrepository_la_SOURCES = \
accounts_exceptions.cc \
accounts_handler.cc \
accounts_repository.cc \
@@ -41,17 +37,11 @@ libpaludisaccountsrepository_@PALUDIS_PC_SLOT@_la_SOURCES = \
dummy_accounts_handler.cc \
passwd_accounts_handler.cc \
registration.cc \
- $(paludis_repositories_accounts_include_HEADERS)
-
-libpaludisaccountsrepository_@PALUDIS_PC_SLOT@_la_LIBADD = \
- $(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
- $(DYNAMIC_LD_LIBS)
+ $(noinst_HEADERS)
accounts_repository_TEST_SOURCES = accounts_repository_TEST.cc
accounts_repository_TEST_LDADD = \
- libpaludisaccountsrepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
diff --git a/paludis/repositories/accounts/registration.cc b/paludis/repositories/accounts/registration.cc
index 3131145..67d8f48 100644
--- a/paludis/repositories/accounts/registration.cc
+++ b/paludis/repositories/accounts/registration.cc
@@ -21,6 +21,7 @@
#include <paludis/repositories/accounts/accounts_repository.hh>
#include <paludis/util/set.hh>
#include <paludis/util/destringify.hh>
+#include "config.h"
using namespace paludis;
using namespace paludis::accounts_repository;
@@ -36,29 +37,36 @@ namespace
}
}
-extern "C" void paludis_initialise_repository_so(RepositoryFactory * const factory) PALUDIS_VISIBLE;
-
-void paludis_initialise_repository_so(RepositoryFactory * const factory)
+namespace paludis
{
- std::tr1::shared_ptr<Set<std::string> > accounts_formats(new Set<std::string>);
- accounts_formats->insert("accounts");
+ namespace repository_groups
+ {
+ REPOSITORY_GROUPS_DECLS;
+ }
- factory->add_repository_format(accounts_formats,
- &AccountsRepository::repository_factory_name,
- &generic_importance,
- &AccountsRepository::repository_factory_create,
- &AccountsRepository::repository_factory_dependencies
- );
+ template <>
+ void register_repositories<repository_groups::accounts>(RepositoryFactory * const factory)
+ {
+ std::tr1::shared_ptr<Set<std::string> > accounts_formats(new Set<std::string>);
+ accounts_formats->insert("accounts");
+
+ factory->add_repository_format(accounts_formats,
+ &AccountsRepository::repository_factory_name,
+ &generic_importance,
+ &AccountsRepository::repository_factory_create,
+ &AccountsRepository::repository_factory_dependencies
+ );
- std::tr1::shared_ptr<Set<std::string> > installed_accounts_formats(new Set<std::string>);
- installed_accounts_formats->insert("installed_accounts");
- installed_accounts_formats->insert("installed-accounts");
+ std::tr1::shared_ptr<Set<std::string> > installed_accounts_formats(new Set<std::string>);
+ installed_accounts_formats->insert("installed_accounts");
+ installed_accounts_formats->insert("installed-accounts");
- factory->add_repository_format(installed_accounts_formats,
- &AccountsRepository::repository_factory_installed_name,
- &generic_importance,
- &AccountsRepository::repository_factory_installed_create,
- &AccountsRepository::repository_factory_installed_dependencies
- );
+ factory->add_repository_format(installed_accounts_formats,
+ &AccountsRepository::repository_factory_installed_name,
+ &generic_importance,
+ &AccountsRepository::repository_factory_installed_create,
+ &AccountsRepository::repository_factory_installed_dependencies
+ );
+ }
}
diff --git a/paludis/repositories/cran/Makefile.am b/paludis/repositories/cran/Makefile.am
index 4151921..cfb793c 100644
--- a/paludis/repositories/cran/Makefile.am
+++ b/paludis/repositories/cran/Makefile.am
@@ -11,20 +11,9 @@ DEFS= \
paludis_repositories_libdir = $(libdir)/paludis/repositories
-if MONOLITHIC
+noinst_LTLIBRARIES = libpaludiscranrepository.la
-noinst_LTLIBRARIES = libpaludiscranrepository_@PALUDIS_PC_SLOT@.la
-
-else
-
-paludis_repositories_lib_LTLIBRARIES = libpaludiscranrepository_@PALUDIS_PC_SLOT@.la
-
-endif
-
-paludis_repositories_cran_includedir = $(includedir)/paludis-$(PALUDIS_PC_SLOT)/paludis/repositories/cran/
-libpaludiscranrepository_@PALUDIS_PC_SLOT@_la_LDFLAGS = -version-info @VERSION_LIB_CURRENT@:@VERSION_LIB_REVISION@:0
-
-paludis_repositories_cran_include_HEADERS = \
+noinst_HEADERS = \
cran_package_id.hh \
cran_dep_parser.hh \
cran_repository.hh \
@@ -36,7 +25,7 @@ paludis_repositories_cran_include_HEADERS = \
dep_spec_pretty_printer.hh \
package_dep_spec.hh
-libpaludiscranrepository_@PALUDIS_PC_SLOT@_la_SOURCES = \
+libpaludiscranrepository_la_SOURCES = \
cran_package_id.cc \
cran_dep_parser.cc \
cran_repository.cc \
@@ -50,11 +39,6 @@ libpaludiscranrepository_@PALUDIS_PC_SLOT@_la_SOURCES = \
package_dep_spec.cc \
$(paludis_repositories_cran_include_HEADERS)
-libpaludiscranrepository_@PALUDIS_PC_SLOT@_la_LIBADD = \
- $(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
- $(DYNAMIC_LD_LIBS)
-
TESTS = \
cran_dep_parser_TEST \
cran_repository_TEST \
@@ -65,8 +49,9 @@ cran_dep_parser_TEST_SOURCES = cran_dep_parser_TEST.cc
cran_dep_parser_TEST_LDADD = \
$(top_builddir)/paludis/util/test_extras.o \
- $(top_builddir)/test/libtest.a \
- libpaludiscranrepository_@PALUDIS_PC_SLOT@.la
+ $(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
+ $(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
+ $(top_builddir)/test/libtest.a
cran_dep_parser_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
@@ -75,7 +60,6 @@ cran_installed_repository_TEST_SOURCES = cran_installed_repository_TEST.cc
cran_installed_repository_TEST_LDADD = \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/test/libtest.a \
- libpaludiscranrepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
@@ -88,7 +72,6 @@ cran_repository_TEST_SOURCES = cran_repository_TEST.cc
cran_repository_TEST_LDADD = \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/test/libtest.a \
- libpaludiscranrepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
@@ -101,7 +84,6 @@ description_file_TEST_SOURCES = description_file_TEST.cc
description_file_TEST_LDADD = \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/test/libtest.a \
- libpaludiscranrepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
diff --git a/paludis/repositories/cran/registration.cc b/paludis/repositories/cran/registration.cc
index 8cfe344..d1edb44 100644
--- a/paludis/repositories/cran/registration.cc
+++ b/paludis/repositories/cran/registration.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -22,11 +22,10 @@
#include <paludis/repositories/cran/cran_installed_repository.hh>
#include <paludis/util/set.hh>
#include <paludis/util/destringify.hh>
+#include "config.h"
using namespace paludis;
-extern "C" void paludis_initialise_repository_so(RepositoryFactory * const factory) PALUDIS_VISIBLE;
-
namespace
{
int generic_importance(const Environment * const, const std::tr1::function<std::string (const std::string &)> & f)
@@ -38,29 +37,38 @@ namespace
}
}
-void paludis_initialise_repository_so(RepositoryFactory * const factory)
+namespace paludis
{
- std::tr1::shared_ptr<Set<std::string> > cran_formats(new Set<std::string>);
- cran_formats->insert("cran");
+ namespace repository_groups
+ {
+ REPOSITORY_GROUPS_DECLS;
+ }
- factory->add_repository_format(
- cran_formats,
- &CRANRepository::repository_factory_name,
- &generic_importance,
- &CRANRepository::repository_factory_create,
- &CRANRepository::repository_factory_dependencies
- );
+ template <>
+ void register_repositories<repository_groups::cran>(RepositoryFactory * const factory)
+ {
+ std::tr1::shared_ptr<Set<std::string> > cran_formats(new Set<std::string>);
+ cran_formats->insert("cran");
+
+ factory->add_repository_format(
+ cran_formats,
+ &CRANRepository::repository_factory_name,
+ &generic_importance,
+ &CRANRepository::repository_factory_create,
+ &CRANRepository::repository_factory_dependencies
+ );
- std::tr1::shared_ptr<Set<std::string> > installed_cran_formats(new Set<std::string>);
- installed_cran_formats->insert("installed_cran");
- installed_cran_formats->insert("installed-cran");
+ std::tr1::shared_ptr<Set<std::string> > installed_cran_formats(new Set<std::string>);
+ installed_cran_formats->insert("installed_cran");
+ installed_cran_formats->insert("installed-cran");
- factory->add_repository_format(
- installed_cran_formats,
- &CRANInstalledRepository::repository_factory_name,
- &generic_importance,
- &CRANInstalledRepository::repository_factory_create,
- &CRANInstalledRepository::repository_factory_dependencies
- );
+ factory->add_repository_format(
+ installed_cran_formats,
+ &CRANInstalledRepository::repository_factory_name,
+ &generic_importance,
+ &CRANInstalledRepository::repository_factory_create,
+ &CRANInstalledRepository::repository_factory_dependencies
+ );
+ }
}
diff --git a/paludis/repositories/e/Makefile.am b/paludis/repositories/e/Makefile.am
index 8ff1026..8e13e2b 100644
--- a/paludis/repositories/e/Makefile.am
+++ b/paludis/repositories/e/Makefile.am
@@ -14,17 +14,13 @@ DEFS= \
-DDATADIR=\"$(datadir)\" \
-DLIBDIR=\"$(libdir)\"
-paludis_repositories_libdir = $(libdir)/paludis/repositories
-paludis_repositories_lib_LTLIBRARIES = libpaludiserepository_@PALUDIS_PC_SLOT@.la
+noinst_LTLIBRARIES = libpaludiserepository.la
if ENABLE_XML
lib_LTLIBRARIES = libpaludiserepositoryxmlthings_@PALUDIS_PC_SLOT@.la
endif
-paludis_repositories_e_includedir = $(includedir)/paludis-$(PALUDIS_PC_SLOT)/paludis/repositories/e/
-libpaludiserepository_@PALUDIS_PC_SLOT@_la_LDFLAGS = -version-info @VERSION_LIB_CURRENT@:@VERSION_LIB_REVISION@:0
-
-paludis_repositories_e_include_HEADERS = \
+noinst_HEADERS = \
aa_visitor.hh \
can_skip_phase.hh \
check_fetched_files_visitor.hh \
@@ -87,7 +83,7 @@ paludis_repositories_e_include_HEADERS = \
vdb_repository.hh \
vdb_unmerger.hh
-libpaludiserepository_@PALUDIS_PC_SLOT@_la_SOURCES = \
+libpaludiserepository_la_SOURCES = \
aa_visitor.cc \
can_skip_phase.cc \
check_fetched_files_visitor.cc \
@@ -144,18 +140,11 @@ libpaludiserepository_@PALUDIS_PC_SLOT@_la_SOURCES = \
vdb_merger.cc \
vdb_repository.cc \
vdb_unmerger.cc \
- $(paludis_repositories_e_include_HEADERS)
-
-libpaludiserepository_@PALUDIS_PC_SLOT@_la_LIBADD = \
- $(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
- $(DYNAMIC_LD_LIBS)
+ $(noinst_HEADERS)
e_repository_TEST_SOURCES = e_repository_TEST.cc
e_repository_TEST_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -168,8 +157,6 @@ e_repository_TEST_CXXFLAGS = $(AM_CXXFLAGS) -I$(top_srcdir) @PALUDIS_CXXFLAGS_NO
depend_rdepend_TEST_SOURCES = depend_rdepend_TEST.cc
depend_rdepend_TEST_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -182,8 +169,6 @@ depend_rdepend_TEST_CXXFLAGS = $(AM_CXXFLAGS) -I$(top_srcdir) @PALUDIS_CXXFLAGS_
e_repository_TEST_ever_SOURCES = e_repository_TEST_ever.cc
e_repository_TEST_ever_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -196,8 +181,6 @@ e_repository_TEST_ever_CXXFLAGS = $(AM_CXXFLAGS) -I$(top_srcdir) @PALUDIS_CXXFLA
e_repository_TEST_phases_SOURCES = e_repository_TEST_phases.cc
e_repository_TEST_phases_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -210,8 +193,6 @@ e_repository_TEST_phases_CXXFLAGS = $(AM_CXXFLAGS) -I$(top_srcdir) @PALUDIS_CXXF
e_repository_TEST_exlibs_SOURCES = e_repository_TEST_exlibs.cc
e_repository_TEST_exlibs_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -224,8 +205,6 @@ e_repository_TEST_exlibs_CXXFLAGS = $(AM_CXXFLAGS) -I$(top_srcdir) @PALUDIS_CXXF
e_repository_TEST_replacing_SOURCES = e_repository_TEST_replacing.cc
e_repository_TEST_replacing_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -238,8 +217,6 @@ e_repository_TEST_replacing_CXXFLAGS = $(AM_CXXFLAGS) -I$(top_srcdir) @PALUDIS_C
vdb_repository_TEST_SOURCES = vdb_repository_TEST.cc
vdb_repository_TEST_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -252,8 +229,6 @@ vdb_repository_TEST_CXXFLAGS = $(AM_CXXFLAGS) -I$(top_srcdir) @PALUDIS_CXXFLAGS_
exndbam_repository_TEST_SOURCES = exndbam_repository_TEST.cc
exndbam_repository_TEST_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -266,7 +241,6 @@ exndbam_repository_TEST_CXXFLAGS = $(AM_CXXFLAGS) -I$(top_srcdir) @PALUDIS_CXXFL
vdb_merger_TEST_SOURCES = vdb_merger_TEST.cc
vdb_merger_TEST_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -279,7 +253,6 @@ vdb_merger_TEST_CXXFLAGS = $(AM_CXXFLAGS) -I$(top_srcdir) @PALUDIS_CXXFLAGS_NO_D
vdb_unmerger_TEST_SOURCES = vdb_unmerger_TEST.cc
vdb_unmerger_TEST_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -292,13 +265,10 @@ vdb_unmerger_TEST_CXXFLAGS = $(AM_CXXFLAGS) -I$(top_srcdir) @PALUDIS_CXXFLAGS_NO
e_repository_sets_TEST_SOURCES = e_repository_sets_TEST.cc
e_repository_sets_TEST_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/test/libtest.a \
$(DYNAMIC_LD_LIBS)
@@ -307,8 +277,6 @@ e_repository_sets_TEST_CXXFLAGS = $(AM_CXXFLAGS) -I$(top_srcdir) @PALUDIS_CXXFLA
dep_spec_pretty_printer_TEST_SOURCES = dep_spec_pretty_printer_TEST.cc
dep_spec_pretty_printer_TEST_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -321,8 +289,6 @@ dep_spec_pretty_printer_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING
dep_parser_TEST_SOURCES = dep_parser_TEST.cc
dep_parser_TEST_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -335,8 +301,6 @@ dep_parser_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
aa_visitor_TEST_SOURCES = aa_visitor_TEST.cc
aa_visitor_TEST_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -349,8 +313,6 @@ aa_visitor_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
fetch_visitor_TEST_SOURCES = fetch_visitor_TEST.cc
fetch_visitor_TEST_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -363,8 +325,6 @@ fetch_visitor_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
source_uri_finder_TEST_SOURCES = source_uri_finder_TEST.cc
source_uri_finder_TEST_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -377,8 +337,6 @@ source_uri_finder_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
fix_locked_dependencies_TEST_SOURCES = fix_locked_dependencies_TEST.cc
fix_locked_dependencies_TEST_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -391,8 +349,6 @@ fix_locked_dependencies_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBU
ebuild_flat_metadata_cache_TEST_SOURCES = ebuild_flat_metadata_cache_TEST.cc
ebuild_flat_metadata_cache_TEST_LDADD = \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -530,7 +486,6 @@ libpaludiserepositoryxmlthings_@PALUDIS_PC_SLOT@_la_CXXFLAGS = $(AM_CXXFLAGS) @L
libpaludiserepositoryxmlthings_@PALUDIS_PC_SLOT@_la_LIBADD = \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@LIBXML2DEPS_LIBS@
libpaludiserepositoryxmlthings_@PALUDIS_PC_SLOT@_la_LDFLAGS = -version-info @VERSION_LIB_CURRENT@:@VERSION_LIB_REVISION@:0
@@ -543,7 +498,6 @@ xml_things_TEST_SOURCES = xml_things_TEST.cc
xml_things_TEST_LDADD = \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/test/libtest.a \
- libpaludiserepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
diff --git a/paludis/repositories/e/qa/Makefile.am b/paludis/repositories/e/qa/Makefile.am
index aae19ec..8f9af3e 100644
--- a/paludis/repositories/e/qa/Makefile.am
+++ b/paludis/repositories/e/qa/Makefile.am
@@ -28,8 +28,7 @@ dist_paludis_qa_data_DATA = \
spec_keys_pds_blacklist.SDEPEND.conf \
spec_keys_pds_blacklist.PROVIDE.conf
-paludis_repositories_e_includedir = $(includedir)/paludis-$(PALUDIS_PC_SLOT)/paludis/repositories/e/
-paludis_repositories_e_include_HEADERS = \
+noinst_HEADERS = \
eapi_supported.hh \
metadata_keys.hh \
extractors.hh \
@@ -66,6 +65,9 @@ paludis_repositories_e_include_HEADERS = \
lib_LTLIBRARIES = libpaludiserepositoryqa_@PALUDIS_PC_SLOT@.la
+libpaludiserepositoryqa_@PALUDIS_PC_SLOT@_la_LDFLAGS = \
+ $(PCRECPPDEPS_LIBS)
+
libpaludiserepositoryqa_@PALUDIS_PC_SLOT@_la_SOURCES = \
qa.cc \
eapi_supported.cc \
@@ -103,15 +105,6 @@ libpaludiserepositoryqa_@PALUDIS_PC_SLOT@_la_SOURCES = \
categories.cc \
$(paludis_repositories_e_include_HEADERS)
-libpaludiserepositoryqa_@PALUDIS_PC_SLOT@_la_LDFLAGS = \
- -version-info @VERSION_LIB_CURRENT@:@VERSION_LIB_REVISION@:0 \
- $(PCRECPPDEPS_LIBS)
-
-libpaludiserepositoryqa_@PALUDIS_PC_SLOT@_la_LIBADD = \
- $(top_builddir)/paludis/repositories/e/libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la
-
dist_check_SCRIPTS = \
visibility_TEST_setup.sh \
visibility_TEST_cleanup.sh \
@@ -153,7 +146,6 @@ TESTS = \
extractors_TEST \
homepage_key_TEST \
spec_keys_TEST \
- stray_files_TEST \
default_functions_TEST \
kv_variables_TEST \
visibility_TEST \
@@ -167,8 +159,6 @@ check_PROGRAMS = $(TESTS)
spec_keys_TEST_SOURCES = spec_keys_TEST.cc
spec_keys_TEST_LDADD = \
libpaludiserepositoryqa_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/e/libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -177,24 +167,9 @@ spec_keys_TEST_LDADD = \
spec_keys_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
-stray_files_TEST_SOURCES = stray_files_TEST.cc
-stray_files_TEST_LDADD = \
- libpaludiserepositoryqa_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/e/libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/util/test_extras.o \
- $(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/test/libtest.a
-
-stray_files_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
-
extractors_TEST_SOURCES = extractors_TEST.cc
extractors_TEST_LDADD = \
libpaludiserepositoryqa_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/e/libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -206,8 +181,6 @@ extractors_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
homepage_key_TEST_SOURCES = homepage_key_TEST.cc
homepage_key_TEST_LDADD = \
libpaludiserepositoryqa_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/e/libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -219,8 +192,6 @@ homepage_key_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
visibility_TEST_SOURCES = visibility_TEST.cc
visibility_TEST_LDADD = \
libpaludiserepositoryqa_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/e/libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -232,8 +203,6 @@ visibility_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
default_functions_TEST_SOURCES = default_functions_TEST.cc
default_functions_TEST_LDADD = \
libpaludiserepositoryqa_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/e/libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -245,8 +214,6 @@ default_functions_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
kv_variables_TEST_SOURCES = kv_variables_TEST.cc
kv_variables_TEST_LDADD = \
libpaludiserepositoryqa_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/e/libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -258,8 +225,6 @@ kv_variables_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
misc_files_TEST_SOURCES = misc_files_TEST.cc
misc_files_TEST_LDADD = \
libpaludiserepositoryqa_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/e/libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -271,8 +236,6 @@ misc_files_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
manifest_TEST_SOURCES = manifest_TEST.cc
manifest_TEST_LDADD = \
libpaludiserepositoryqa_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/e/libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -284,8 +247,6 @@ manifest_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
subshell_die_TEST_SOURCES = subshell_die_TEST.cc
subshell_die_TEST_LDADD = \
libpaludiserepositoryqa_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/e/libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -297,8 +258,6 @@ subshell_die_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
function_keyword_TEST_SOURCES = function_keyword_TEST.cc
function_keyword_TEST_LDADD = \
libpaludiserepositoryqa_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/e/libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
diff --git a/paludis/repositories/e/qa/qa.cc b/paludis/repositories/e/qa/qa.cc
index e762390..8aa4ef1 100644
--- a/paludis/repositories/e/qa/qa.cc
+++ b/paludis/repositories/e/qa/qa.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007, 2008 Ciaran McCreesh
+ * Copyright (c) 2007, 2008, 2009 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -31,24 +31,6 @@ namespace paludis
class ERepository;
}
-extern "C"
-{
- void PALUDIS_VISIBLE paludis_initialise_repository_so(paludis::RepositoryFactory * const);
-
- void PALUDIS_VISIBLE check_qa(
- const Environment * const,
- const std::tr1::shared_ptr<const ERepository> &,
- const QACheckProperties &,
- const QACheckProperties &,
- const QAMessageLevel,
- QAReporter &,
- const FSEntry &);
-}
-
-void paludis_initialise_repository_so(paludis::RepositoryFactory * const)
-{
-}
-
void check_qa(
const Environment * const env,
const std::tr1::shared_ptr<const ERepository> & repo,
diff --git a/paludis/repositories/e/qa/stray_files_TEST.cc b/paludis/repositories/e/qa/stray_files_TEST.cc
deleted file mode 100644
index 8607d52..0000000
--- a/paludis/repositories/e/qa/stray_files_TEST.cc
+++ /dev/null
@@ -1,40 +0,0 @@
-/* vim: set sw=4 sts=4 et foldmethod=syntax : */
-
-/*
- * Copyright (c) 2007 Ciaran McCreesh
- *
- * This file is part of the Paludis package manager. Paludis is free software;
- * you can redistribute it and/or modify it under the terms of the GNU General
- * Public License version 2, as published by the Free Software Foundation.
- *
- * Paludis 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 General Public License for more
- * details.
- *
- * You should have received a copy of the GNU General Public License along with
- * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
- * Place, Suite 330, Boston, MA 02111-1307 USA
- */
-
-#include "stray_files.hh"
-#include <test/test_framework.hh>
-#include <test/test_runner.hh>
-
-using namespace paludis;
-using namespace paludis::erepository;
-using namespace test;
-
-namespace test_cases
-{
- struct StrayFilesTest : TestCase
- {
- StrayFilesTest() : TestCase("stray files") { }
-
- void run()
- {
- TEST_CHECK(true);
- }
- } test_stray_files;
-}
-
diff --git a/paludis/repositories/e/registration.cc b/paludis/repositories/e/registration.cc
index b263a83..4000ed2 100644
--- a/paludis/repositories/e/registration.cc
+++ b/paludis/repositories/e/registration.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -25,6 +25,7 @@
#include <paludis/util/wrapped_forward_iterator.hh>
#include <paludis/util/set.hh>
#include <paludis/util/destringify.hh>
+#include "config.h"
using namespace paludis;
@@ -41,42 +42,49 @@ namespace
}
}
-extern "C" void paludis_initialise_repository_so(RepositoryFactory * const factory) PALUDIS_VISIBLE;
-
-void paludis_initialise_repository_so(RepositoryFactory * const factory)
+namespace paludis
{
- std::tr1::shared_ptr<Set<std::string> > ebuild_formats(new Set<std::string>);
- ebuild_formats->insert("ebuild");
- ebuild_formats->insert("exheres");
+ namespace repository_groups
+ {
+ REPOSITORY_GROUPS_DECLS;
+ }
- factory->add_repository_format(
- ebuild_formats,
- &ERepository::repository_factory_name,
- &generic_importance,
- &ERepository::repository_factory_create,
- &ERepository::repository_factory_dependencies
- );
+ template <>
+ void register_repositories<repository_groups::e>(RepositoryFactory * const factory)
+ {
+ std::tr1::shared_ptr<Set<std::string> > ebuild_formats(new Set<std::string>);
+ ebuild_formats->insert("ebuild");
+ ebuild_formats->insert("exheres");
+
+ factory->add_repository_format(
+ ebuild_formats,
+ &ERepository::repository_factory_name,
+ &generic_importance,
+ &ERepository::repository_factory_create,
+ &ERepository::repository_factory_dependencies
+ );
- std::tr1::shared_ptr<Set<std::string> > vdb_formats(new Set<std::string>);
- vdb_formats->insert("vdb");
+ std::tr1::shared_ptr<Set<std::string> > vdb_formats(new Set<std::string>);
+ vdb_formats->insert("vdb");
- factory->add_repository_format(
- vdb_formats,
- &VDBRepository::repository_factory_name,
- &generic_importance,
- &VDBRepository::repository_factory_create,
- &VDBRepository::repository_factory_dependencies
- );
+ factory->add_repository_format(
+ vdb_formats,
+ &VDBRepository::repository_factory_name,
+ &generic_importance,
+ &VDBRepository::repository_factory_create,
+ &VDBRepository::repository_factory_dependencies
+ );
- std::tr1::shared_ptr<Set<std::string> > exndbam_formats(new Set<std::string>);
- exndbam_formats->insert("exndbam");
+ std::tr1::shared_ptr<Set<std::string> > exndbam_formats(new Set<std::string>);
+ exndbam_formats->insert("exndbam");
- factory->add_repository_format(
- exndbam_formats,
- &ExndbamRepository::repository_factory_name,
- &generic_importance,
- &ExndbamRepository::repository_factory_create,
- &ExndbamRepository::repository_factory_dependencies
- );
+ factory->add_repository_format(
+ exndbam_formats,
+ &ExndbamRepository::repository_factory_name,
+ &generic_importance,
+ &ExndbamRepository::repository_factory_create,
+ &ExndbamRepository::repository_factory_dependencies
+ );
+ }
}
diff --git a/paludis/repositories/e/xml_things.cc b/paludis/repositories/e/xml_things.cc
index 9ad1efc..904a4dd 100644
--- a/paludis/repositories/e/xml_things.cc
+++ b/paludis/repositories/e/xml_things.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -437,7 +437,3 @@ namespace paludis
class RepositoryFactory;
}
-extern "C" void PALUDIS_VISIBLE paludis_initialise_repository_so(paludis::RepositoryFactory * const)
-{
-}
-
diff --git a/paludis/repositories/fake/Makefile.am b/paludis/repositories/fake/Makefile.am
index fab6b29..abecc9a 100644
--- a/paludis/repositories/fake/Makefile.am
+++ b/paludis/repositories/fake/Makefile.am
@@ -7,8 +7,6 @@ DEFS= \
-DLIBEXECDIR=\"$(libexecdir)\" \
-DDATADIR=\"$(datadir)\"
-paludis_repositories_libdir = $(libdir)/paludis/repositories
-
TESTS_ENVIRONMENT = env \
PALUDIS_GEMS_DIR="`$(top_srcdir)/paludis/repositories/e/ebuild/utils/canonicalise $(top_srcdir)/paludis/repositories/gems/`" \
PALUDIS_EAPIS_DIR="$(top_srcdir)/paludis/repositories/e/eapis/" \
@@ -34,7 +32,6 @@ EXTRA_DIST = \
dep_parser_TEST.cc
fake_repository_TEST_LDADD = \
- libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
@@ -44,7 +41,6 @@ fake_repository_TEST_LDADD = \
fake_repository_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
fake_installed_repository_TEST_LDADD = \
- libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
@@ -54,7 +50,6 @@ fake_installed_repository_TEST_LDADD = \
fake_installed_repository_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
dep_parser_TEST_LDADD = \
- libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
@@ -72,9 +67,9 @@ fake_installed_repository_TEST_SOURCES = \
dep_parser_TEST_SOURCES = \
dep_parser_TEST.cc
-paludis_repositories_lib_LTLIBRARIES = libpaludisfakerepository_@PALUDIS_PC_SLOT@.la
+noinst_LTLIBRARIES = libpaludisfakerepository.la
-libpaludisfakerepository_@PALUDIS_PC_SLOT@_la_SOURCES = \
+libpaludisfakerepository_la_SOURCES = \
dep_parser.cc dep_parser.hh \
fake_repository_base.cc fake_repository_base.hh \
fake_repository.cc fake_repository.hh \
@@ -82,12 +77,6 @@ libpaludisfakerepository_@PALUDIS_PC_SLOT@_la_SOURCES = \
fake_package_id.cc fake_package_id.hh \
registration.cc
-libpaludisfakerepository_@PALUDIS_PC_SLOT@_la_LIBADD = \
- $(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la
-
-libpaludisfakerepository_@PALUDIS_PC_SLOT@_la_LDFLAGS = -version-info @VERSION_LIB_CURRENT@:@VERSION_LIB_REVISION@:0
-
paludis_repositories_fake_includedir = $(includedir)/paludis-$(PALUDIS_PC_SLOT)/paludis/repositories/fake/
paludis_repositories_fake_include_HEADERS = \
dep_parser.hh \
diff --git a/paludis/repositories/fake/registration.cc b/paludis/repositories/fake/registration.cc
index 014d821..2cfc9da 100644
--- a/paludis/repositories/fake/registration.cc
+++ b/paludis/repositories/fake/registration.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2008 Ciaran McCreesh
+ * Copyright (c) 2008, 2009 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -23,6 +23,7 @@
#include <paludis/util/destringify.hh>
#include <paludis/util/set.hh>
#include <paludis/environment.hh>
+#include "config.h"
using namespace paludis;
@@ -37,18 +38,26 @@ namespace
}
}
-extern "C" void paludis_initialise_repository_so(RepositoryFactory * const factory) PALUDIS_VISIBLE;
-
-void paludis_initialise_repository_so(RepositoryFactory * const factory)
+namespace paludis
{
- std::tr1::shared_ptr<Set<std::string> > fake_formats(new Set<std::string>);
- fake_formats->insert("fake_installed");
-
- factory->add_repository_format(
- fake_formats,
- FakeInstalledRepository::repository_factory_name,
- &generic_importance,
- FakeInstalledRepository::repository_factory_create,
- FakeInstalledRepository::repository_factory_dependencies
- );
+ namespace repository_groups
+ {
+ REPOSITORY_GROUPS_DECLS;
+ }
+
+ template <>
+ void register_repositories<repository_groups::fake>(RepositoryFactory * const factory)
+ {
+ std::tr1::shared_ptr<Set<std::string> > fake_formats(new Set<std::string>);
+ fake_formats->insert("fake_installed");
+
+ factory->add_repository_format(
+ fake_formats,
+ FakeInstalledRepository::repository_factory_name,
+ &generic_importance,
+ FakeInstalledRepository::repository_factory_create,
+ FakeInstalledRepository::repository_factory_dependencies
+ );
+ }
}
+
diff --git a/paludis/repositories/gems/Makefile.am b/paludis/repositories/gems/Makefile.am
index ae2d769..6a1eae7 100644
--- a/paludis/repositories/gems/Makefile.am
+++ b/paludis/repositories/gems/Makefile.am
@@ -9,15 +9,11 @@ DEFS = \
-DDATADIR=\"$(datadir)\" \
-DLIBDIR=\"$(libdir)\"
-paludis_repositories_libdir = $(libdir)/paludis/repositories
paludis_gems_libexecdir = $(libexecdir)/paludis/gems
-paludis_repositories_lib_LTLIBRARIES = libpaludisgemsrepository_@PALUDIS_PC_SLOT@.la
+noinst_LTLIBRARIES = libpaludisgemsrepository.la
-paludis_repositories_gems_includedir = $(includedir)/paludis-$(PALUDIS_PC_SLOT)/paludis/repositories/gems/
-libpaludisgemsrepository_@PALUDIS_PC_SLOT@_la_LDFLAGS = -version-info @VERSION_LIB_CURRENT@:@VERSION_LIB_REVISION@:0
-
-paludis_repositories_gems_include_HEADERS = \
+noinst_HEADERS = \
gems_repository.hh \
installed_gems_repository.hh \
exceptions.hh \
@@ -27,7 +23,7 @@ paludis_repositories_gems_include_HEADERS = \
params-fwd.hh params.hh \
extra_distribution_data.hh
-libpaludisgemsrepository_@PALUDIS_PC_SLOT@_la_SOURCES = \
+libpaludisgemsrepository_la_SOURCES = \
gems_repository.cc \
installed_gems_repository.cc \
params.cc \
@@ -37,11 +33,9 @@ libpaludisgemsrepository_@PALUDIS_PC_SLOT@_la_SOURCES = \
gem_specifications.cc \
extra_distribution_data.cc \
registration.cc \
- $(paludis_repositories_gems_include_HEADERS)
+ $(noinst_HEADERS)
-libpaludisgemsrepository_@PALUDIS_PC_SLOT@_la_LIBADD = \
- $(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
+libpaludisgemsrepository_la_LIBADD = \
-lsyck
gems_repository_TEST_SOURCES = gems_repository_TEST.cc
@@ -51,7 +45,6 @@ gem_specification_TEST_SOURCES = gem_specification_TEST.cc
gem_specifications_TEST_SOURCES = gem_specifications_TEST.cc
gems_repository_TEST_LDADD = \
- libpaludisgemsrepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -60,7 +53,6 @@ gems_repository_TEST_LDADD = \
-lsyck
installed_gems_repository_TEST_LDADD = \
- libpaludisgemsrepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -69,7 +61,6 @@ installed_gems_repository_TEST_LDADD = \
-lsyck
yaml_TEST_LDADD = \
- libpaludisgemsrepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -78,7 +69,6 @@ yaml_TEST_LDADD = \
-lsyck
gem_specification_TEST_LDADD = \
- libpaludisgemsrepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -87,7 +77,6 @@ gem_specification_TEST_LDADD = \
-lsyck
gem_specifications_TEST_LDADD = \
- libpaludisgemsrepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
diff --git a/paludis/repositories/gems/registration.cc b/paludis/repositories/gems/registration.cc
index e52505c..6b8286c 100644
--- a/paludis/repositories/gems/registration.cc
+++ b/paludis/repositories/gems/registration.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007, 2008 Ciaran McCreesh
+ * Copyright (c) 2007, 2008, 2009 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -28,6 +28,7 @@
#include <paludis/util/destringify.hh>
#include <paludis/distribution.hh>
#include <paludis/environment.hh>
+#include "config.h"
using namespace paludis;
@@ -42,31 +43,38 @@ namespace
}
}
-extern "C" void paludis_initialise_repository_so(RepositoryFactory * const factory) PALUDIS_VISIBLE;
-
-void paludis_initialise_repository_so(RepositoryFactory * const factory)
+namespace paludis
{
- std::tr1::shared_ptr<Set<std::string> > gems_formats(new Set<std::string>);
- gems_formats->insert("gems");
+ namespace repository_groups
+ {
+ REPOSITORY_GROUPS_DECLS;
+ }
- factory->add_repository_format(
- gems_formats,
- GemsRepository::repository_factory_name,
- &generic_importance,
- GemsRepository::repository_factory_create,
- GemsRepository::repository_factory_dependencies
- );
+ template <>
+ void register_repositories<repository_groups::gems>(RepositoryFactory * const factory)
+ {
+ std::tr1::shared_ptr<Set<std::string> > gems_formats(new Set<std::string>);
+ gems_formats->insert("gems");
+
+ factory->add_repository_format(
+ gems_formats,
+ GemsRepository::repository_factory_name,
+ &generic_importance,
+ GemsRepository::repository_factory_create,
+ GemsRepository::repository_factory_dependencies
+ );
- std::tr1::shared_ptr<Set<std::string> > installed_gems_formats(new Set<std::string>);
- installed_gems_formats->insert("installed_gems");
- installed_gems_formats->insert("installed-gems");
+ std::tr1::shared_ptr<Set<std::string> > installed_gems_formats(new Set<std::string>);
+ installed_gems_formats->insert("installed_gems");
+ installed_gems_formats->insert("installed-gems");
- factory->add_repository_format(
- installed_gems_formats,
- InstalledGemsRepository::repository_factory_name,
- &generic_importance,
- InstalledGemsRepository::repository_factory_create,
- InstalledGemsRepository::repository_factory_dependencies
- );
+ factory->add_repository_format(
+ installed_gems_formats,
+ InstalledGemsRepository::repository_factory_name,
+ &generic_importance,
+ InstalledGemsRepository::repository_factory_create,
+ InstalledGemsRepository::repository_factory_dependencies
+ );
+ }
}
diff --git a/paludis/repositories/unavailable/Makefile.am b/paludis/repositories/unavailable/Makefile.am
index 54a1c5b..519b146 100644
--- a/paludis/repositories/unavailable/Makefile.am
+++ b/paludis/repositories/unavailable/Makefile.am
@@ -11,42 +11,31 @@ DEFS= \
-DDATADIR=\"$(datadir)\" \
-DLIBDIR=\"$(libdir)\"
-paludis_repositories_libdir = $(libdir)/paludis/repositories
-paludis_repositories_lib_LTLIBRARIES = libpaludisunavailablerepository_@PALUDIS_PC_SLOT@.la
+noinst_LTLIBRARIES = libpaludisunavailablerepository.la
-paludis_repositories_unavailable_includedir = $(includedir)/paludis-$(PALUDIS_PC_SLOT)/paludis/repositories/unavailable/
-libpaludisunavailablerepository_@PALUDIS_PC_SLOT@_la_LDFLAGS = -version-info @VERSION_LIB_CURRENT@:@VERSION_LIB_REVISION@:0
-
-paludis_repositories_unavailable_include_HEADERS = \
+noinst_HEADERS = \
unavailable_repository.hh unavailable_repository-fwd.hh \
unavailable_id.hh \
unavailable_mask.hh \
unavailable_repository_store.hh \
unavailable_repository_file.hh unavailable_repository_file-fwd.hh
-libpaludisunavailablerepository_@PALUDIS_PC_SLOT@_la_SOURCES = \
+libpaludisunavailablerepository_la_SOURCES = \
unavailable_repository.cc \
unavailable_id.cc \
unavailable_mask.cc \
unavailable_repository_store.cc \
unavailable_repository_file.cc \
registration.cc \
- $(paludis_repositories_unavailable_include_HEADERS)
-
-libpaludisunavailablerepository_@PALUDIS_PC_SLOT@_la_LIBADD = \
- $(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
- $(DYNAMIC_LD_LIBS)
+ $(noinst_HEADERS)
unavailable_repository_TEST_SOURCES = unavailable_repository_TEST.cc
unavailable_repository_TEST_LDADD = \
- libpaludisunavailablerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/test/libtest.a \
$(DYNAMIC_LD_LIBS)
diff --git a/paludis/repositories/unavailable/registration.cc b/paludis/repositories/unavailable/registration.cc
index 8249862..7634e3f 100644
--- a/paludis/repositories/unavailable/registration.cc
+++ b/paludis/repositories/unavailable/registration.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2008 Ciaran McCreesh
+ * Copyright (c) 2008, 2009 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -21,6 +21,7 @@
#include <paludis/repositories/unavailable/unavailable_repository.hh>
#include <paludis/util/set.hh>
#include <paludis/util/destringify.hh>
+#include "config.h"
using namespace paludis;
using namespace paludis::unavailable_repository;
@@ -36,18 +37,25 @@ namespace
}
}
-extern "C" void paludis_initialise_repository_so(RepositoryFactory * const factory) PALUDIS_VISIBLE;
-
-void paludis_initialise_repository_so(RepositoryFactory * const factory)
+namespace paludis
{
- std::tr1::shared_ptr<Set<std::string> > unavailable_formats(new Set<std::string>);
- unavailable_formats->insert("unavailable");
-
- factory->add_repository_format(unavailable_formats,
- &UnavailableRepository::repository_factory_name,
- &generic_importance,
- &UnavailableRepository::repository_factory_create,
- &UnavailableRepository::repository_factory_dependencies
- );
+ namespace repository_groups
+ {
+ REPOSITORY_GROUPS_DECLS;
+ }
+
+ template <>
+ void register_repositories<repository_groups::unavailable>(RepositoryFactory * const factory)
+ {
+ std::tr1::shared_ptr<Set<std::string> > unavailable_formats(new Set<std::string>);
+ unavailable_formats->insert("unavailable");
+
+ factory->add_repository_format(unavailable_formats,
+ &UnavailableRepository::repository_factory_name,
+ &generic_importance,
+ &UnavailableRepository::repository_factory_create,
+ &UnavailableRepository::repository_factory_dependencies
+ );
+ }
}
diff --git a/paludis/repositories/unpackaged/Makefile.am b/paludis/repositories/unpackaged/Makefile.am
index 242cfa5..63ffdf5 100644
--- a/paludis/repositories/unpackaged/Makefile.am
+++ b/paludis/repositories/unpackaged/Makefile.am
@@ -10,13 +10,9 @@ DEFS= \
-DDATADIR=\"$(datadir)\" \
-DLIBDIR=\"$(libdir)\"
-paludis_repositories_libdir = $(libdir)/paludis/repositories
-paludis_repositories_lib_LTLIBRARIES = libpaludisunpackagedrepository_@PALUDIS_PC_SLOT@.la
+noinst_LTLIBRARIES = libpaludisunpackagedrepository.la
-paludis_repositories_unpackaged_includedir = $(includedir)/paludis-$(PALUDIS_PC_SLOT)/paludis/repositories/unpackaged/
-libpaludisunpackagedrepository_@PALUDIS_PC_SLOT@_la_LDFLAGS = -version-info @VERSION_LIB_CURRENT@:@VERSION_LIB_REVISION@:0
-
-paludis_repositories_unpackaged_include_HEADERS = \
+noinst_HEADERS = \
dep_parser.hh \
dep_printer.hh \
exceptions.hh \
@@ -27,7 +23,7 @@ paludis_repositories_unpackaged_include_HEADERS = \
installed_repository.hh \
installed_id.hh
-libpaludisunpackagedrepository_@PALUDIS_PC_SLOT@_la_SOURCES = \
+libpaludisunpackagedrepository_la_SOURCES = \
dep_parser.cc \
dep_printer.cc \
exceptions.cc \
@@ -38,17 +34,11 @@ libpaludisunpackagedrepository_@PALUDIS_PC_SLOT@_la_SOURCES = \
installed_repository.cc \
installed_id.cc \
registration.cc \
- $(paludis_repositories_unpackaged_include_HEADERS)
-
-libpaludisunpackagedrepository_@PALUDIS_PC_SLOT@_la_LIBADD = \
- $(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
- $(DYNAMIC_LD_LIBS)
+ $(noinst_HEADERS)
unpackaged_repository_TEST_SOURCES = unpackaged_repository_TEST.cc
unpackaged_repository_TEST_LDADD = \
- libpaludisunpackagedrepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -61,7 +51,6 @@ unpackaged_repository_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGG
installed_repository_TEST_SOURCES = installed_repository_TEST.cc
installed_repository_TEST_LDADD = \
- libpaludisunpackagedrepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
@@ -74,7 +63,6 @@ installed_repository_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGI
dep_parser_TEST_SOURCES = dep_parser_TEST.cc
dep_parser_TEST_LDADD = \
- libpaludisunpackagedrepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
diff --git a/paludis/repositories/unpackaged/registration.cc b/paludis/repositories/unpackaged/registration.cc
index a2dd13f..1ac7126 100644
--- a/paludis/repositories/unpackaged/registration.cc
+++ b/paludis/repositories/unpackaged/registration.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007, 2008 Ciaran McCreesh
+ * Copyright (c) 2007, 2008, 2009 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -23,6 +23,7 @@
#include <paludis/repository_factory.hh>
#include <paludis/repositories/unpackaged/installed_repository.hh>
#include <paludis/repositories/unpackaged/unpackaged_repository.hh>
+#include "config.h"
using namespace paludis;
@@ -37,31 +38,38 @@ namespace
}
}
-extern "C" void paludis_initialise_repository_so(RepositoryFactory * const factory) PALUDIS_VISIBLE;
-
-void paludis_initialise_repository_so(RepositoryFactory * const factory)
+namespace paludis
{
- std::tr1::shared_ptr<Set<std::string> > unpackaged_formats(new Set<std::string>);
- unpackaged_formats->insert("unpackaged");
+ namespace repository_groups
+ {
+ REPOSITORY_GROUPS_DECLS;
+ }
- factory->add_repository_format(
- unpackaged_formats,
- &UnpackagedRepository::repository_factory_name,
- &generic_importance,
- &UnpackagedRepository::repository_factory_create,
- &UnpackagedRepository::repository_factory_dependencies
- );
+ template <>
+ void register_repositories<repository_groups::unpackaged>(RepositoryFactory * const factory)
+ {
+ std::tr1::shared_ptr<Set<std::string> > unpackaged_formats(new Set<std::string>);
+ unpackaged_formats->insert("unpackaged");
+
+ factory->add_repository_format(
+ unpackaged_formats,
+ &UnpackagedRepository::repository_factory_name,
+ &generic_importance,
+ &UnpackagedRepository::repository_factory_create,
+ &UnpackagedRepository::repository_factory_dependencies
+ );
- std::tr1::shared_ptr<Set<std::string> > installed_unpackaged_formats(new Set<std::string>);
- installed_unpackaged_formats->insert("installed_unpackaged");
- installed_unpackaged_formats->insert("installed-unpackaged");
+ std::tr1::shared_ptr<Set<std::string> > installed_unpackaged_formats(new Set<std::string>);
+ installed_unpackaged_formats->insert("installed_unpackaged");
+ installed_unpackaged_formats->insert("installed-unpackaged");
- factory->add_repository_format(
- installed_unpackaged_formats,
- &InstalledUnpackagedRepository::repository_factory_name,
- &generic_importance,
- &InstalledUnpackagedRepository::repository_factory_create,
- &InstalledUnpackagedRepository::repository_factory_dependencies
- );
+ factory->add_repository_format(
+ installed_unpackaged_formats,
+ &InstalledUnpackagedRepository::repository_factory_name,
+ &generic_importance,
+ &InstalledUnpackagedRepository::repository_factory_create,
+ &InstalledUnpackagedRepository::repository_factory_dependencies
+ );
+ }
}
diff --git a/paludis/repositories/unwritten/Makefile.am b/paludis/repositories/unwritten/Makefile.am
index 7e6561e..b7820e0 100644
--- a/paludis/repositories/unwritten/Makefile.am
+++ b/paludis/repositories/unwritten/Makefile.am
@@ -11,37 +11,27 @@ DEFS= \
-DDATADIR=\"$(datadir)\" \
-DLIBDIR=\"$(libdir)\"
-paludis_repositories_libdir = $(libdir)/paludis/repositories
-paludis_repositories_lib_LTLIBRARIES = libpaludisunwrittenrepository_@PALUDIS_PC_SLOT@.la
+noinst_LTLIBRARIES = libpaludisunwrittenrepository.la
-paludis_repositories_unwritten_includedir = $(includedir)/paludis-$(PALUDIS_PC_SLOT)/paludis/repositories/unwritten/
-libpaludisunwrittenrepository_@PALUDIS_PC_SLOT@_la_LDFLAGS = -version-info @VERSION_LIB_CURRENT@:@VERSION_LIB_REVISION@:0
-
-paludis_repositories_unwritten_include_HEADERS = \
+noinst_HEADERS = \
unwritten_repository.hh \
unwritten_id.hh \
unwritten_mask.hh \
unwritten_repository_store.hh \
unwritten_repository_file.hh
-libpaludisunwrittenrepository_@PALUDIS_PC_SLOT@_la_SOURCES = \
+libpaludisunwrittenrepository_la_SOURCES = \
unwritten_repository.cc \
unwritten_id.cc \
unwritten_mask.cc \
unwritten_repository_store.cc \
unwritten_repository_file.cc \
registration.cc \
- $(paludis_repositories_unwritten_include_HEADERS)
-
-libpaludisunwrittenrepository_@PALUDIS_PC_SLOT@_la_LIBADD = \
- $(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
- $(DYNAMIC_LD_LIBS)
+ $(noinst_HEADERS)
unwritten_repository_TEST_SOURCES = unwritten_repository_TEST.cc
unwritten_repository_TEST_LDADD = \
- libpaludisunwrittenrepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
diff --git a/paludis/repositories/unwritten/registration.cc b/paludis/repositories/unwritten/registration.cc
index fc5fa55..f3a8b59 100644
--- a/paludis/repositories/unwritten/registration.cc
+++ b/paludis/repositories/unwritten/registration.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2008 Ciaran McCreesh
+ * Copyright (c) 2008, 2009 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -21,6 +21,7 @@
#include <paludis/repositories/unwritten/unwritten_repository.hh>
#include <paludis/util/set.hh>
#include <paludis/util/destringify.hh>
+#include "config.h"
using namespace paludis;
using namespace paludis::unwritten_repository;
@@ -36,18 +37,25 @@ namespace
}
}
-extern "C" void paludis_initialise_repository_so(RepositoryFactory * const factory) PALUDIS_VISIBLE;
-
-void paludis_initialise_repository_so(RepositoryFactory * const factory)
+namespace paludis
{
- std::tr1::shared_ptr<Set<std::string> > unwritten_formats(new Set<std::string>);
- unwritten_formats->insert("unwritten");
-
- factory->add_repository_format(unwritten_formats,
- &UnwrittenRepository::repository_factory_name,
- &generic_importance,
- &UnwrittenRepository::repository_factory_create,
- &UnwrittenRepository::repository_factory_dependencies
- );
+ namespace repository_groups
+ {
+ REPOSITORY_GROUPS_DECLS;
+ }
+
+ template <>
+ void register_repositories<repository_groups::unwritten>(RepositoryFactory * const factory)
+ {
+ std::tr1::shared_ptr<Set<std::string> > unwritten_formats(new Set<std::string>);
+ unwritten_formats->insert("unwritten");
+
+ factory->add_repository_format(unwritten_formats,
+ &UnwrittenRepository::repository_factory_name,
+ &generic_importance,
+ &UnwrittenRepository::repository_factory_create,
+ &UnwrittenRepository::repository_factory_dependencies
+ );
+ }
}
diff --git a/paludis/repositories/virtuals/Makefile.am b/paludis/repositories/virtuals/Makefile.am
index de8851a..bbdbfd4 100644
--- a/paludis/repositories/virtuals/Makefile.am
+++ b/paludis/repositories/virtuals/Makefile.am
@@ -11,39 +11,19 @@ DEFS= \
paludis_repositories_libdir = $(libdir)/paludis/repositories
-if MONOLITHIC
+noinst_LTLIBRARIES = libpaludisvirtualsrepository.la
-noinst_LTLIBRARIES = libpaludisvirtualsrepository_@PALUDIS_PC_SLOT@.la
-
-else
-
-paludis_repositories_lib_LTLIBRARIES = libpaludisvirtualsrepository_@PALUDIS_PC_SLOT@.la
-
-endif
-
-paludis_repositories_virtuals_includedir = $(includedir)/paludis-$(PALUDIS_PC_SLOT)/paludis/repositories/virtuals/
-libpaludisvirtualsrepository_@PALUDIS_PC_SLOT@_la_LDFLAGS = -version-info @VERSION_LIB_CURRENT@:@VERSION_LIB_REVISION@:0
-
-paludis_repositories_virtuals_include_HEADERS = \
+noinst_HEADERS = \
virtuals_repository.hh \
installed_virtuals_repository.hh \
package_id.hh
-libpaludisvirtualsrepository_@PALUDIS_PC_SLOT@_la_SOURCES = \
+libpaludisvirtualsrepository_la_SOURCES = \
virtuals_repository.cc \
installed_virtuals_repository.cc \
package_id.cc \
registration.cc \
- $(paludis_repositories_portage_include_HEADERS)
-
-if ! MONOLITHIC
-
-libpaludisvirtualsrepository_@PALUDIS_PC_SLOT@_la_LIBADD = \
- $(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
- $(DYNAMIC_LD_LIBS)
-
-endif
+ $(noinst_HEADERS)
TESTS = virtuals_repository_TEST installed_virtuals_repository_TEST
@@ -69,8 +49,6 @@ TESTS_ENVIRONMENT = env \
bash $(top_srcdir)/test/run_test.sh
virtuals_repository_TEST_LDADD = \
- libpaludisvirtualsrepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
@@ -80,8 +58,6 @@ virtuals_repository_TEST_LDADD = \
virtuals_repository_TEST_CXXFLAGS = $(AM_CXXFLAGS) @PALUDIS_CXXFLAGS_NO_DEBUGGING@
installed_virtuals_repository_TEST_LDADD = \
- libpaludisvirtualsrepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/test_extras.o \
diff --git a/paludis/repositories/virtuals/registration.cc b/paludis/repositories/virtuals/registration.cc
index 1a67165..8f5effa 100644
--- a/paludis/repositories/virtuals/registration.cc
+++ b/paludis/repositories/virtuals/registration.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -22,6 +22,7 @@
#include <paludis/repositories/virtuals/virtuals_repository.hh>
#include <paludis/util/set.hh>
#include <paludis/util/destringify.hh>
+#include "config.h"
using namespace paludis;
@@ -36,31 +37,38 @@ namespace
}
}
-extern "C" void paludis_initialise_repository_so(RepositoryFactory * const factory) PALUDIS_VISIBLE;
-
-void paludis_initialise_repository_so(RepositoryFactory * const factory)
+namespace paludis
{
- std::tr1::shared_ptr<Set<std::string> > virtuals_formats(new Set<std::string>);
- virtuals_formats->insert("virtuals");
+ namespace repository_groups
+ {
+ REPOSITORY_GROUPS_DECLS;
+ }
- factory->add_repository_format(
- virtuals_formats,
- &VirtualsRepository::repository_factory_name,
- &virtual_importance,
- &VirtualsRepository::repository_factory_create,
- &VirtualsRepository::repository_factory_dependencies
- );
+ template <>
+ void register_repositories<repository_groups::virtuals>(RepositoryFactory * const factory)
+ {
+ std::tr1::shared_ptr<Set<std::string> > virtuals_formats(new Set<std::string>);
+ virtuals_formats->insert("virtuals");
+
+ factory->add_repository_format(
+ virtuals_formats,
+ &VirtualsRepository::repository_factory_name,
+ &virtual_importance,
+ &VirtualsRepository::repository_factory_create,
+ &VirtualsRepository::repository_factory_dependencies
+ );
- std::tr1::shared_ptr<Set<std::string> > installed_virtuals_formats(new Set<std::string>);
- installed_virtuals_formats->insert("installed_virtuals");
- installed_virtuals_formats->insert("installed-virtuals");
+ std::tr1::shared_ptr<Set<std::string> > installed_virtuals_formats(new Set<std::string>);
+ installed_virtuals_formats->insert("installed_virtuals");
+ installed_virtuals_formats->insert("installed-virtuals");
- factory->add_repository_format(
- installed_virtuals_formats,
- &InstalledVirtualsRepository::repository_factory_name,
- &virtual_importance,
- &InstalledVirtualsRepository::repository_factory_create,
- &InstalledVirtualsRepository::repository_factory_dependencies
- );
+ factory->add_repository_format(
+ installed_virtuals_formats,
+ &InstalledVirtualsRepository::repository_factory_name,
+ &virtual_importance,
+ &InstalledVirtualsRepository::repository_factory_create,
+ &InstalledVirtualsRepository::repository_factory_dependencies
+ );
+ }
}
diff --git a/paludis/repository_factory-fwd.hh b/paludis/repository_factory-fwd.hh
index 471679c..22abb18 100644
--- a/paludis/repository_factory-fwd.hh
+++ b/paludis/repository_factory-fwd.hh
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2008 Ciaran McCreesh
+ * Copyright (c) 2008, 2009 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
diff --git a/paludis/repository_factory.cc b/paludis/repository_factory.cc
index 497fe19..acc23c3 100644
--- a/paludis/repository_factory.cc
+++ b/paludis/repository_factory.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2008 Ciaran McCreesh
+ * Copyright (c) 2008, 2009 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -34,8 +34,7 @@
#include <paludis/about.hh>
#include <tr1/unordered_map>
#include <list>
-#include <dlfcn.h>
-#include <stdint.h>
+#include "config.h"
using namespace paludis;
@@ -82,59 +81,40 @@ namespace paludis
struct Implementation<RepositoryFactory>
{
Keys keys;
- std::list<void *> dl_opened;
};
+
+ namespace repository_groups
+ {
+ REPOSITORY_GROUPS_DECLS;
+ }
+
+ template <>
+ void register_repositories<NoType<0u> >(RepositoryFactory * const)
+ {
+ }
}
RepositoryFactory::RepositoryFactory() :
PrivateImplementationPattern<RepositoryFactory>(new Implementation<RepositoryFactory>)
{
- FSEntry so_dir(getenv_with_default("PALUDIS_REPOSITORY_SO_DIR", LIBDIR "/paludis/repositories"));
- if (! so_dir.is_directory())
- throw InternalError(PALUDIS_HERE, "PALUDIS_REPOSITORY_SO_DIR '" + stringify(so_dir) + "' not a directory");
- _load_dir(so_dir);
+ using namespace repository_groups;
+
+ register_repositories<REPOSITORY_GROUP_IF_accounts>(this);
+ register_repositories<REPOSITORY_GROUP_IF_cran>(this);
+ register_repositories<REPOSITORY_GROUP_IF_dummy>(this);
+ register_repositories<REPOSITORY_GROUP_IF_e>(this);
+ register_repositories<REPOSITORY_GROUP_IF_gems>(this);
+ register_repositories<REPOSITORY_GROUP_IF_fake>(this);
+ register_repositories<REPOSITORY_GROUP_IF_unavailable>(this);
+ register_repositories<REPOSITORY_GROUP_IF_unwritten>(this);
+ register_repositories<REPOSITORY_GROUP_IF_unpackaged>(this);
+ register_repositories<REPOSITORY_GROUP_IF_virtuals>(this);
}
RepositoryFactory::~RepositoryFactory()
{
}
-void
-RepositoryFactory::_load_dir(const FSEntry & so_dir)
-{
- for (DirIterator d(so_dir), d_end ; d != d_end ; ++d)
- {
- if (d->is_directory())
- _load_dir(*d);
-
- if (! is_file_with_extension(*d, "_" + stringify(PALUDIS_PC_SLOT) + ".so." + stringify(100 * PALUDIS_VERSION_MAJOR + PALUDIS_VERSION_MINOR),
- IsFileWithOptions()))
- continue;
-
- /* don't use RTLD_LOCAL, g++ is over happy about template instantiations, and it
- * can lead to multiple singleton instances. */
- void * dl(dlopen(stringify(*d).c_str(), RTLD_GLOBAL | RTLD_NOW));
-
- if (dl)
- {
- _imp->dl_opened.push_back(dl);
-
- void * reg(dlsym(dl, "paludis_initialise_repository_so"));
- if (reg)
- {
- reinterpret_cast<void (*)(RepositoryFactory * const)>(reinterpret_cast<uintptr_t>(reg))(this);
- }
- else
- throw InternalError(PALUDIS_HERE, "No paludis_initialise_repository_so function defined in '" + stringify(*d) + "'");
- }
- else
- throw InternalError(PALUDIS_HERE, "Couldn't dlopen '" + stringify(*d) + "': " + stringify(dlerror()));
- }
-
- if ((so_dir / ".libs").is_directory())
- _load_dir(so_dir / ".libs");
-}
-
const std::tr1::shared_ptr<Repository>
RepositoryFactory::create(
Environment * const env,
diff --git a/paludis/repository_factory.hh b/paludis/repository_factory.hh
index d010bf1..135aec9 100644
--- a/paludis/repository_factory.hh
+++ b/paludis/repository_factory.hh
@@ -26,6 +26,7 @@
#include <paludis/util/instantiation_policy.hh>
#include <paludis/util/wrapped_forward_iterator-fwd.hh>
#include <paludis/util/fs_entry-fwd.hh>
+#include <paludis/util/no_type.hh>
#include <paludis/environment-fwd.hh>
#include <paludis/repository-fwd.hh>
#include <paludis/name-fwd.hh>
@@ -44,8 +45,6 @@ namespace paludis
RepositoryFactory();
~RepositoryFactory();
- void _load_dir(const FSEntry &);
-
public:
typedef std::tr1::function<std::string (const std::string &)> KeyFunction;
@@ -154,6 +153,9 @@ namespace paludis
ConstIterator end_keys() const PALUDIS_ATTRIBUTE((warn_unused_result));
};
+ template <typename RepositoryClass_ = NoType<0u> >
+ void register_repositories(RepositoryFactory * const);
+
#ifdef PALUDIS_HAVE_EXTERN_TEMPLATE
extern template class PrivateImplementationPattern<RepositoryFactory>;
extern template class InstantiationPolicy<RepositoryFactory, instantiation_method::SingletonTag>;
diff --git a/paludis/resolver/Makefile.am b/paludis/resolver/Makefile.am
index 61625dc..52e72b0 100644
--- a/paludis/resolver/Makefile.am
+++ b/paludis/resolver/Makefile.am
@@ -104,7 +104,6 @@ resolver_TEST_blockers_LDADD = \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/test/libtest.a \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
libpaludisresolver.a \
@@ -119,7 +118,6 @@ resolver_TEST_virtuals_LDADD = \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/test/libtest.a \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
libpaludisresolver.a \
@@ -134,7 +132,6 @@ resolver_TEST_suggestions_LDADD = \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/test/libtest.a \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
libpaludisresolver.a \
@@ -149,7 +146,6 @@ resolver_TEST_serialisation_LDADD = \
$(top_builddir)/paludis/util/test_extras.o \
$(top_builddir)/test/libtest.a \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
libpaludisresolver.a \
diff --git a/python/Makefile.am b/python/Makefile.am
index 4e554e7..eeb96fe 100644
--- a/python/Makefile.am
+++ b/python/Makefile.am
@@ -185,8 +185,6 @@ endif
libpaludispython_@PALUDIS_PC_SLOT@_la_LIBADD = \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/e/libpaludiserepository_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/environments/paludis/libpaludispaludisenvironment_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/environments/no_config/libpaludisnoconfigenvironment_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la
diff --git a/ruby/Makefile.am b/ruby/Makefile.am
index 039a73a..5ad55f5 100644
--- a/ruby/Makefile.am
+++ b/ruby/Makefile.am
@@ -157,7 +157,6 @@ libpaludisruby_@PALUDIS_PC_SLOT@_la_LIBADD = \
$(top_builddir)/paludis/environments/paludis/libpaludispaludisenvironment_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/environments/no_config/libpaludisnoconfigenvironment_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/environments/test/libpaludistestenvironment_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(PTHREAD_LIBS)
check_DATA = .libs/Paludis.so
diff --git a/src/clients/adjutrix/Makefile.am b/src/clients/adjutrix/Makefile.am
index 0101891..309b727 100644
--- a/src/clients/adjutrix/Makefile.am
+++ b/src/clients/adjutrix/Makefile.am
@@ -43,7 +43,6 @@ adjutrix_SOURCES = \
adjutrix_LDADD = \
$(top_builddir)/paludis/environments/no_config/libpaludisnoconfigenvironment_@PALUDIS_PC_SLOT@.la \
- $(top_builddir)/paludis/repositories/fake/libpaludisfakerepository_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/libpaludis_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/args/libpaludisargs_@PALUDIS_PC_SLOT@.la \
$(top_builddir)/paludis/util/libpaludisutil_@PALUDIS_PC_SLOT@.la \