prt-get: revert getPkgDest; use fgrep to determine PKGMK_PACKAGE_DIR

git-svn-id: https://crux.nu/svn/tools/prt-get/trunk@1864 0b5ae1c7-2405-0410-a7fc-ba219f786e1e
This commit is contained in:
Johannes Winkelmann 2006-09-10 19:11:23 +00:00
parent faddee70ff
commit 318a4a0768
3 changed files with 9 additions and 4 deletions

View File

@ -1,6 +1,8 @@
* 0.5.14 00.00.200x Johannes Winkelmann
- Remove handling of external dependency list
- make InstallTransaction::getPkgDest use pkgmk.conf from install-root
- revert getPkgDest to ignore install-root
- determine PKGMK_PACKAGE_DIR using fgrep without sourcing pkgmk.conf
* 0.5.13 08.09.2006 Johannes Winkelmann
- Show undecided versions in diff and sysup when using "prefer higher"

2
TODO
View File

@ -1,7 +1,5 @@
- handle 27e < 28 in version comperator
- add --rebuild-set to dependent
- use `eval $(fgrep -h 'PKGMK_PACKAGE_DIR=' $(which pkgmk) /etc/pkgmk.conf) && echo
$PKGMK_PACKAGE_DIR` to determine PACKAGE_DIR
- allow dependency injection for sysup, with previews
- prefer toolchain (patch in trac)
- logging: check for non-root owned symlinks

View File

@ -582,11 +582,16 @@ InstallTransaction::calcDependencies( )
return SUCCESS;
}
/*
* getPkgDest assumes that you're in the build directory already
*/
string InstallTransaction::getPkgDest(const string& installRoot)
{
string pkgdest = "";
string cmd = ". %s/etc/pkgmk.conf && echo $PKGMK_PACKAGE_DIR";
StringHelper::replaceAll(cmd, "%s", installRoot);
string cmd = "eval $(fgrep -h 'PKGMK_PACKAGE_DIR=' "
"/usr/bin/pkgmk /etc/pkgmk.conf) "
"&& echo $PKGMK_PACKAGE_DIR";
FILE* p = popen(cmd.c_str(), "r");
if ( p ) {
char line[256];