return rc;
}
-/**
- */
-static int ldconfig_done = 0;
-
-static const char * ldconfig_path = "/sbin/ldconfig";
-
static void doScriptExec(rpmts ts, ARGV_const_t argv, rpmtd prefixes,
FD_t scriptFd, FD_t out)
{
psm->sq.reaper = 1;
- /*
- * If a successor node, and ldconfig was just run, don't bother.
- */
- if (ldconfig_path && *argvp != NULL && psm->unorderedSuccessor) {
- if (ldconfig_done && rstreq(*argvp[0], ldconfig_path)) {
- rpmlog(RPMLOG_DEBUG, "%s: %s skipping redundant \"%s\".\n",
- psm->stepName, sname, *argvp[0]);
- free(sname);
- return RPMRC_OK;
- }
- }
-
rpmlog(RPMLOG_DEBUG, "%s: %s %ssynchronous scriptlet start\n",
psm->stepName, sname, (psm->unorderedSuccessor ? "a" : ""));
if (argvCount(*argvp) == 0) {
argvAdd(argvp, "/bin/sh");
- ldconfig_done = 0;
- } else {
- ldconfig_done = (ldconfig_path && rstreq(*argvp[0], ldconfig_path)
- ? 1 : 0);
}
xx = Fwrite(set_x, sizeof(set_x[0]), sizeof(set_x)-1, fd);
}
- if (ldconfig_path && strstr(script, ldconfig_path) != NULL)
- ldconfig_done = 1;
-
xx = Fwrite(script, sizeof(script[0]), strlen(script), fd);
xx = Fclose(fd);