- updated sv.po (goeran@uddeborg.pp.se) (#8349).
- configurable PATH for install %pre/%post et al scriptlets.
- use only %_install_langs, not LINGUAS/LANG when deciding to install.
+ - configurable compression type/level for package payloads.
3.0.2 -> 3.0.3
- add --eval to find result of macro expansion.
rc = RPMERR_NOSPACE;
} else { /* Write the archive and get the size */
if (csa->cpioList != NULL) {
- rc = cpio_doio(fd, csa, "w9.gzdio");
+ rc = cpio_doio(fd, csa, "%{_payload_compression}");
} else if (Fileno(csa->cpioFdIn) >= 0) {
rc = cpio_copy(fd, csa);
} else {
return 0;
}
-static int cpio_doio(FD_t fdo, CSA_t * csa, const char * fmode)
+static int cpio_doio(FD_t fdo, CSA_t * csa, const char * fmodeMacro)
{
FD_t cfd;
int rc;
const char *failedFile = NULL;
+ const char *fmode = rpmExpand(fmodeMacro, NULL);
+ if (!(fmode && fmode[0] == 'w'))
+ fmode = xstrdup("w9.gzdio");
(void) Fflush(fdo);
cfd = Fdopen(fdDup(Fileno(fdo)), fmode);
rc = cpioBuildArchive(cfd, csa->cpioList, csa->cpioCount, NULL, NULL,
Fclose(cfd);
if (failedFile)
xfree(failedFile);
+ xfree(fmode);
return rc;
}
-# $Id: macros.in,v 1.41 2000/01/11 15:22:35 jbj Exp $
+# $Id: macros.in,v 1.42 2000/01/11 16:13:16 jbj Exp $
#==============================================================================
# Macro naming conventions (preliminary):
#
#
#%packager
+# Compression type and level for package payloads.
+# "w9.gzdio" gzip level 9 (default).
+# "w9.bzdio" bzip2 level 9 (experimental, at your own risk).
+#
+#%_payload_compression w9.gzdio
+
# The signature to use and the location of configuration files for
# signing packages with PGP.
#