summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjbj <devnull@localhost>2004-08-31 15:39:37 +0000
committerjbj <devnull@localhost>2004-08-31 15:39:37 +0000
commitdd17e87985c3fd2e76fc122c9dc01159fc8f11b9 (patch)
tree656b19b380900bb62db1029f718e1812b8a78884
parentce2ad5848a52c6ea96e8a29fb8eb40e314b25ccf (diff)
downloadrpm-dd17e87985c3fd2e76fc122c9dc01159fc8f11b9.tar.gz
rpm-dd17e87985c3fd2e76fc122c9dc01159fc8f11b9.tar.bz2
rpm-dd17e87985c3fd2e76fc122c9dc01159fc8f11b9.zip
- ia64: auto-relocate entire, not partial, directory contents (#126905).
- ia64: auto-relocate glibc.ix86 interpreter path (#100563). - shared libraries in separate rpm-libs package. - fix: defattr for rpm-libs (#130461). - fix: static glibc/libgcc helpers always installed (#127522). - ia64: make sure that autorelocated file dependencies are satisfied. - ia64: relocate all scriptlet interpreters. - ia64: don't bother trying to preload autorelocated modules. - fix: filesystem package needs mail/lock w/o getgrnam. - fix: do getpwnam/getgrnam to load correct modules before chroot. CVS patchset: 7415 CVS date: 2004/08/31 15:39:37
-rw-r--r--CHANGES12
-rw-r--r--lib/psm.c30
-rw-r--r--lib/rpmal.c12
-rw-r--r--rpmio/ugid.c13
4 files changed, 55 insertions, 12 deletions
diff --git a/CHANGES b/CHANGES
index 3cc008f05..a6541ae7a 100644
--- a/CHANGES
+++ b/CHANGES
@@ -54,7 +54,6 @@
- fix: escape '+' in regex patterns through RPMMIRE_DEFAULT (#103851).
- RPMMIRE_DEFAULT is overkill, use RPMMIRE_STRCMP instead (#103851).
- don't use mktemp if mkstemp is available (#103850).
- - use -fPIC -DPIC on all platforms, not just mandatory (#112713).
- python: return None for NEVRAO, [] for everything else.
- python: throw exception on bad arg to labelCompare (#113661).
- re-add --enable-posixmutexes to build.
@@ -86,6 +85,16 @@
- change default behavior to resolve file conflicts as LIFO.
- add --fileconflicts to recover rpm traditional behavior.
- prefer elf64 over elf32 files, everywhere and always (#126853).
+ - ia64: auto-relocate entire, not partial, directory contents (#126905).
+ - ia64: auto-relocate glibc.ix86 interpreter path (#100563).
+ - shared libraries in separate rpm-libs package.
+ - fix: defattr for rpm-libs (#130461).
+ - fix: static glibc/libgcc helpers always installed (#127522).
+ - ia64: make sure that autorelocated file dependencies are satisfied.
+ - ia64: relocate all scriptlet interpreters.
+ - ia64: don't bother trying to preload autorelocated modules.
+ - fix: filesystem package needs mail/lock w/o getgrnam.
+ - fix: do getpwnam/getgrnam to load correct modules before chroot.
4.2.1 -> 4.2.2:
- unify signal handling in librpmio, use condvar to deliver signal.
@@ -109,6 +118,7 @@
- find-debuginfo.sh: permit stripping unwritable by non-root (#112429).
- missing build dependency (#111104).
- spelling corrections (#112728).
+ - use -fPIC -DPIC on all platforms, not just mandatory (#112713).
- popt: pad to display length, not strlen, for i18n popt args (#106240).
- python: include Python.h before glibc features.h.
- python: return [], not None, accessing header tags (#112794).
diff --git a/lib/psm.c b/lib/psm.c
index 2d89eefba..da52f2191 100644
--- a/lib/psm.c
+++ b/lib/psm.c
@@ -706,6 +706,9 @@ static rpmRC runScript(rpmpsm psm, Header h, const char * sln,
FD_t out;
rpmRC rc = RPMRC_OK;
const char *n, *v, *r;
+#if __ia64__
+ const char *a;
+#endif
if (progArgv == NULL && script == NULL)
return rc;
@@ -719,6 +722,9 @@ static rpmRC runScript(rpmpsm psm, Header h, const char * sln,
/* XXX FIXME: except for %verifyscript, rpmteNEVR can be used. */
xx = headerNVR(h, &n, &v, &r);
+#if __ia64__
+ xx = hge(h, RPMTAG_ARCH, NULL, (void **) &a, NULL);
+#endif
/* XXX bash must have functional libtermcap.so.2 */
if (!strcmp(n, "libtermcap"))
@@ -756,8 +762,9 @@ static rpmRC runScript(rpmpsm psm, Header h, const char * sln,
}
#if __ia64__
- if (!strcmp(n, "glibc")
- && !strcmp(argv[0], "/usr/sbin/glibc_post_upgrade"))
+ /* XXX This assumes that all interpreters are elf executables. */
+ if ((a != NULL && a[0] == 'i' && a[1] != '\0' && a[2] == '8' && a[3] == '6')
+ && strcmp(argv[0], "/sbin/ldconfig"))
{
const char * fmt = rpmGetPath("%{?_autorelocate_path}", NULL);
const char * errstr;
@@ -980,6 +987,8 @@ static rpmRC runScript(rpmpsm psm, Header h, const char * sln,
(void) psmWait(psm);
+ /* XXX filter order dependent multilib "other" arch helper error. */
+ if (!(psm->sq.reaped >= 0 && !strcmp(argv[0], "/usr/sbin/glibc_post_upgrade") && WEXITSTATUS(psm->sq.status) == 110)) {
if (psm->sq.reaped < 0) {
rpmError(RPMERR_SCRIPT,
_("%s(%s-%s-%s) scriptlet failed, waitpid(%d) rc %d: %s\n"),
@@ -992,6 +1001,7 @@ static rpmRC runScript(rpmpsm psm, Header h, const char * sln,
sln, n, v, r, WEXITSTATUS(psm->sq.status));
rc = RPMRC_FAIL;
}
+ }
if (freePrefixes) prefixes = hfd(prefixes, ipt);
@@ -2047,16 +2057,18 @@ psm->te->h = headerFree(psm->te->h);
if (rootDir != NULL && !(rootDir[0] == '/' && rootDir[1] == '\0')
&& !rpmtsChrootDone(ts) && !psm->chrootDone)
{
- static int _loaded = 0;
+ static int _pw_loaded = 0;
+ static int _gr_loaded = 0;
- /*
- * This loads all of the name services libraries, in case we
- * don't have access to them in the chroot().
- */
- if (!_loaded) {
+ if (!_pw_loaded) {
(void)getpwnam("root");
endpwent();
- _loaded++;
+ _pw_loaded++;
+ }
+ if (!_gr_loaded) {
+ (void)getgrnam("root");
+ endgrent();
+ _gr_loaded++;
}
xx = chdir("/");
diff --git a/lib/rpmal.c b/lib/rpmal.c
index 149beb285..f60231015 100644
--- a/lib/rpmal.c
+++ b/lib/rpmal.c
@@ -445,8 +445,18 @@ fprintf(stderr, "*** add %p[%d] 0x%x\n", al->list, pkgNum, tscolor);
(void) rpmfiSetDX(fi, dx);
/*@-assignexpose -dependenttrans -observertrans@*/
- dieNeedle->dirName = (char *) rpmfiDN(fi);
+ { const char * DN = rpmfiDN(fi);
+
+#if defined(__ia64__)
+/* XXX Make sure that autorelocated file dependencies are satisfied. */
+#define DNPREFIX "/emul/ia32-linux"
+ if (!strncmp(DN, DNPREFIX, sizeof(DNPREFIX)-1))
+ DN += sizeof(DNPREFIX)-1;
+#endif
+ dieNeedle->dirName = DN;
+ }
/*@=assignexpose =dependenttrans =observertrans@*/
+
dieNeedle->dirNameLen = (dieNeedle->dirName != NULL
? strlen(dieNeedle->dirName) : 0);
die = bsearch(dieNeedle, al->dirs, origNumDirs,
diff --git a/rpmio/ugid.c b/rpmio/ugid.c
index 697574a27..65d31bcbd 100644
--- a/rpmio/ugid.c
+++ b/rpmio/ugid.c
@@ -100,7 +100,18 @@ int gnameToGid(const char * thisGname, gid_t * gid)
endgrent();
/*@=internalglobs@*/
grent = getgrnam(thisGname);
- if (grent == NULL) return -1;
+ if (grent == NULL) {
+ /* XXX The filesystem package needs group/lock w/o getgrnam. */
+ if (strcmp(thisGname, "lock") == 0) {
+ *gid = lastGid = 54;
+ return 0;
+ } else
+ if (strcmp(thisGname, "mail") == 0) {
+ *gid = lastGid = 12;
+ return 0;
+ } else
+ return -1;
+ }
}
lastGid = grent->gr_gid;
}