#include <string.h>
+#ifdef __cplusplus
+extern "C" {
+#endif
+
typedef struct _Map {
unsigned char *map;
int size;
return MAPTST(m, n);
}
+#ifdef __cplusplus
+}
+#endif
+
#endif /* LIBSOLV_BITMAP_H */
#include "pool.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
void *solv_chksum_create(Id type);
void *solv_chksum_create_from_bin(Id type, const unsigned char *buf);
void solv_chksum_add(void *handle, const void *data, int len);
Id solv_chksum_str2type(const char *str);
int solv_chksum_len(Id type);
+#ifdef __cplusplus
+}
+#endif
+
#endif /* LIBSOLV_CHKSUM_H */
#include "pooltypes.h"
#include "pool.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
struct _Repo;
typedef struct _KeyValue {
#define DI_SEEK_PARENT 2
#define DI_SEEK_REWIND 3
+#ifdef __cplusplus
+}
+#endif
+
#endif /* LIBSOLV_DATAITERATOR_H */
#include "pooltypes.h"
#include "util.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
typedef struct _Dirpool {
Id *dirs;
int ndirs;
return dp->dirs[did];
}
+#ifdef __cplusplus
+}
+#endif
+
#endif /* LIBSOLV_DIRPOOL_H */
#include "pooltypes.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/* value of a hash */
typedef unsigned int Hashval;
/* mask for hash, used as modulo operator to ensure 'wrapping' of hash
return num * 2 - 1;
}
+#ifdef __cplusplus
+}
+#endif
+
#endif /* LIBSOLV_HASH_H */
#include "solver.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
#define POLICY_MODE_CHOOSE 0
#define POLICY_MODE_RECOMMEND 1
#define POLICY_MODE_SUGGEST 2
extern void policy_create_obsolete_index(Solver *solv);
+#ifdef __cplusplus
+}
+#endif
#ifndef LIBSOLV_POOL_H
#define LIBSOLV_POOL_H
-#ifdef __cplusplus
-extern "C" {
-#endif
-
#include <stdio.h>
#include "solvversion.h"
/* well known ids */
#include "knownid.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/* well known solvable */
#define SYSTEMSOLVABLE 1
#include "pool.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
extern void pool_setarch(Pool *, const char *);
extern void pool_setarchpolicy(Pool *, const char *);
extern unsigned char pool_arch2color_slow(Pool *pool, Id arch);
return 0;
}
+#ifdef __cplusplus
+}
+#endif
+
#endif /* LIBSOLV_POOLARCH_H */
#include "pooltypes.h"
#include "hash.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/*-----------------------------------------------
* Ids with relation
*/
extern void pool_shrink_rels(Pool *pool);
extern void pool_freeidhashes(Pool *pool);
+#ifdef __cplusplus
+}
+#endif
+
#endif /* LIBSOLV_POOLID_H */
#include "pool.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
Id pool_vendor2mask(Pool *pool, Id vendor);
void pool_setvendorclasses(Pool *pool, const char **vendorclasses);
void pool_addvendorclass(Pool *pool, const char **vendorclass);
+#ifdef __cplusplus
+}
+#endif
+
#endif /* LIBSOLV_POOLVENDOR_H */
#include "pooltypes.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
typedef struct _Queue {
Id *elements; /* pointer to elements */
int count; /* current number of elements in queue */
extern void queue_deleten(Queue *q, int pos, int n);
extern void queue_prealloc(Queue *q, int n);
+#ifdef __cplusplus
+}
+#endif
+
#endif /* LIBSOLV_QUEUE_H */
#include "dataiterator.h"
#include "hash.h"
-
+#ifdef __cplusplus
+extern "C" {
+#endif
typedef struct _Repo {
const char *name; /* name pointer */
for (rdid = 1; rdid < repo->nrepodata && (data = repo_id2repodata(repo, rdid)); rdid++)
#endif
+#ifdef __cplusplus
+}
+#endif
+
#endif /* LIBSOLV_REPO_H */
#ifndef LIBSOLV_REPO_SOLVE_H
#define LIBSOLV_REPO_SOLVE_H
-#ifdef __cplusplus
-extern "C" {
-#endif
-
#include <stdio.h>
#include "pool.h"
#include "repo.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
extern int repo_add_solv(Repo *repo, FILE *fp, int flags);
#define SOLV_ADD_NO_STUBS (1 << 8)
#include "repo.h"
#include "queue.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
extern int repo_write(Repo *repo, FILE *fp);
extern int repo_write_filtered(Repo *repo, FILE *fp, int (*keyfilter)(Repo *repo, Repokey *key, void *kfdata), void *kfdata, Queue *keyq);
extern int repo_write_stdkeyfilter(Repo *repo, Repokey *key, void *kfdata);
+#ifdef __cplusplus
+}
+#endif
+
#endif
#include "repopage.h"
#endif
+#ifdef __cplusplus
+extern "C" {
+#endif
+
#define SIZEOF_MD5 16
#define SIZEOF_SHA1 20
#define SIZEOF_SHA256 32
/* stats */
unsigned int repodata_memused(Repodata *data);
+#ifdef __cplusplus
+}
+#endif
+
#endif /* LIBSOLV_REPODATA_H */
unsigned int rr_counter;
} Repopagestore;
+#ifdef __cplusplus
+extern "C" {
+#endif
+
void repopagestore_init(Repopagestore *store);
void repopagestore_free(Repopagestore *store);
void repopagestore_disable_paging(Repopagestore *store);
+#ifdef __cplusplus
+}
+#endif
+
#endif /* LIBSOLV_REPOPAGE_H */
#include "pool.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
#define SELECTION_NAME (1 << 0)
#define SELECTION_PROVIDES (1 << 1)
#define SELECTION_FILELIST (1 << 2)
extern void selection_add(Pool *pool, Queue *sel1, Queue *sel2);
extern void selection_solvables(Pool *pool, Queue *selection, Queue *pkgs);
+#ifdef __cplusplus
+}
+#endif
+
#endif
#include "pooltypes.h"
#include "queue.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
struct _Repo;
typedef struct _Solvable {
int solvable_identical(Solvable *s1, Solvable *s2);
Id solvable_selfprovidedep(Solvable *s);
+#ifdef __cplusplus
+}
+#endif
+
#endif /* LIBSOLV_SOLVABLE_H */
#ifndef LIBSOLV_SOLVER_H
#define LIBSOLV_SOLVER_H
-#ifdef __cplusplus
-extern "C" {
-#endif
-
#include "pooltypes.h"
#include "pool.h"
#include "repo.h"
#include "rules.h"
#include "problems.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
struct _Solver {
Pool *pool; /* back pointer to pool */
#include "pool.h"
#include "solver.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
extern Id *solver_create_decisions_obsoletesmap(Solver *solv);
extern void solver_printruleelement(Solver *solv, int type, Rule *r, Id v);
extern void solver_printrule(Solver *solv, int type, Rule *r);
extern const char *solver_solutionelement2str(Solver *solv, Id p, Id rp);
extern const char *policy_illegal2str(Solver *solv, int illegal, Solvable *s, Solvable *rs);
+#ifdef __cplusplus
+}
+#endif
#endif /* LIBSOLV_SOLVERDEBUG_H */
#include "pooltypes.h"
#include "hash.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
#define STRID_NULL 0
#define STRID_EMPTY 1
return ss->stringspace + ss->strings[id];
}
+#ifdef __cplusplus
+}
+#endif
+
#endif
#ifndef LIBSOLV_TRANSACTION_H
#define LIBSOLV_TRANSACTION_H
-#ifdef __cplusplus
-extern "C" {
-#endif
-
#include "pooltypes.h"
#include "queue.h"
#include "bitmap.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
struct _Pool;
struct _DUChanges;
struct _TransactionOrderdata;
#include <stddef.h>
#include <string.h>
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/**
* malloc
* exits with error message on error
memset(buf, 0, ((len + block) & ~block) * size);
return buf;
}
+
+#ifdef __cplusplus
+}
+#endif
+
#endif /* LIBSOLV_UTIL_H */