lib: move conf parsing to lib/conf.c and refactor to not rely on getcwd/chdir

This fixes https://github.com/voidlinux/xbps/issues/158
This commit is contained in:
Duncaen committed 2019-05-22 13:22:10 +02:00
1 parent fa5911bb00
commit 85bf13f138
7 files changed
+587 -446

No files matched your search

+6
View File
@@ -594,6 +594,12 @@ struct xbps_handle {
* Full path to the xbps configuration directory.
*/
char confdir[XBPS_MAXPATH+sizeof(XBPS_SYSCONF_PATH)];
/**
* @var confdir
*
* Full path to the xbps configuration directory.
*/
char sysconfdir[XBPS_MAXPATH+sizeof(XBPS_SYSDEFCONF_PATH)];
/**
* @var rootdir
*
+1
View File
@@ -155,5 +155,6 @@ xbps_array_t HIDDEN xbps_get_pkg_fulldeptree(struct xbps_handle *,
const char *, bool);
struct xbps_repo HIDDEN *xbps_regget_repo(struct xbps_handle *,
const char *);
int HIDDEN xbps_conf_init(struct xbps_handle *);
#endif /* !_XBPS_API_IMPL_H_ */