summaryrefslogtreecommitdiffstats
path: root/RPM4/src
diff options
context:
space:
mode:
Diffstat (limited to 'RPM4/src')
-rw-r--r--RPM4/src/RPM4.xs7
1 files changed, 6 insertions, 1 deletions
diff --git a/RPM4/src/RPM4.xs b/RPM4/src/RPM4.xs
index 57f45ce..869cb91 100644
--- a/RPM4/src/RPM4.xs
+++ b/RPM4/src/RPM4.xs
@@ -428,7 +428,12 @@ void _newspec(rpmts ts, char * filename, SV * svpassphrase, SV * svrootdir, SV *
if (filename) {
#ifdef RPM4_9_0
- spec = rpmSpecParse(filename, RPMSPEC_ANYARCH|RPMSPEC_FORCE, NULL);
+ rpmSpecFlags flags = 0;
+ if (anyarch)
+ flags |= RPMSPEC_ANYARCH;
+ if (force)
+ flags |= RPMSPEC_FORCE;
+ spec = rpmSpecParse(filename, flags, NULL);
#else
if (!parseSpec(ts, filename, rootdir, NULL ,0, passphrase, cookies, anyarch, force))
spec = rpmtsSetSpec(ts, NULL);