diff options
author | Michael Schroeder <mls@suse.de> | 2013-12-06 15:36:11 +0100 |
---|---|---|
committer | Michael Schroeder <mls@suse.de> | 2013-12-06 15:36:11 +0100 |
commit | eaed4ac011505b68129b900cdfe3a06cbca42c8e (patch) | |
tree | 19e565b411d3d676d57d608de55cfbb247a81d34 /examples | |
parent | 047a5a57b2010558426d95064a5b2b0b93c9f8da (diff) | |
download | libsolv-eaed4ac011505b68129b900cdfe3a06cbca42c8e.tar.gz libsolv-eaed4ac011505b68129b900cdfe3a06cbca42c8e.tar.bz2 libsolv-eaed4ac011505b68129b900cdfe3a06cbca42c8e.zip |
solv example: add autopackages on SUSE systems
Diffstat (limited to 'examples')
-rw-r--r-- | examples/solv.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/examples/solv.c b/examples/solv.c index 09258cb..d9b03a1 100644 --- a/examples/solv.c +++ b/examples/solv.c @@ -84,6 +84,9 @@ #include "repo_susetags.h" #include "repo_content.h" #endif +#ifdef SUSE +#include "repo_autopattern.h" +#endif #include "solv_xfopen.h" #ifdef FEDORA @@ -2385,6 +2388,17 @@ addfileprovides(Pool *pool) #endif +#ifdef SUSE +static void +add_autopackages(Pool *pool) +{ + int i; + Repo *repo; + FOR_REPOS(i, repo) + repo_add_autopattern(repo, 0); +} +#endif + #if defined(SUSE) || defined(FEDORA) static void add_patchjobs(Pool *pool, Queue *job) @@ -2928,6 +2942,9 @@ main(int argc, char **argv) if (pool->disttype == DISTTYPE_RPM) addfileprovides(pool); #endif +#ifdef SUSE + add_autopackages(pool); +#endif pool_createwhatprovides(pool); if (keyname) |