X-Git-Url: https://pd.if.org/git/?a=blobdiff_plain;f=zpm.h;h=2858ff45d034e57416d465c34e60ad0fe7e8a2e4;hb=ce38dde467cb64991032812eaaac31deb3c39da5;hp=6cca0575c27c52d2a86e1df831806bfd326ad0f5;hpb=e0b66116ef0b1894e70312f98b2d835dec8c8c19;p=zpackage diff --git a/zpm.h b/zpm.h index 6cca057..2858ff4 100644 --- a/zpm.h +++ b/zpm.h @@ -41,6 +41,14 @@ struct zpm { struct zpm_package *current_package; }; +struct zpm_stat { + struct stat st; + int configuration; + char hash[65]; /* length + room for a nul byte */ + char diskhash[65]; /* hash of actual file on disk */ + char *target; /* malloced link target */ +}; + struct zpm_dependency { char minpkg[ZPM_PACKAGE_ID_MAX+1]; char maxpkg[ZPM_PACKAGE_ID_MAX+1]; @@ -153,8 +161,9 @@ int zpm_package(struct zpm *zp, int n); /* get file information */ int zpm_stat(struct zpm *z, struct zpm_file *f, int n); -/* will also set the package context to the new package */ -int zpm_newpkg(struct zpm *z, char *base, char *version, int release); +//int zpm_newpkg(struct zpm *z, char *base, char *version, int release); +int zpm_create_package(struct zpm *zpm, char *name, char *ver, int rel); +int zpm_create_pkgid(struct zpm *zpm, char *pkgstr); /* transactions */ int zpm_begin(struct zpm *z);