[Rpm-maint] [rpm-software-management/rpm] Add support for macro-only dependency generators (#1053)

Panu Matilainen notifications at github.com
Thu Feb 6 10:26:06 UTC 2020


pmatilai commented on this pull request.



> @@ -1784,6 +1784,29 @@ rpmDefineMacro(rpmMacroContext mc, const char * macro, int level)
     return rc;
 }
 
+int rpmMacroIsDefined(rpmMacroContext mc, const char *n)
+{
+    int defined = 0;
+    if ((mc = rpmmctxAcquire(mc)) != NULL) {
+	if (findEntry(mc, n, 0, NULL))
+	    defined = 1;
+	rpmmctxRelease(mc);
+    }
+    return defined;
+}
+
+int rpmMacroIsCallable(rpmMacroContext mc, const char *n)
+{

That depends on whether one considers "parametric" to be a descriptive name. I find the term pretty horrible, especially as it's called "parameterized" in the docs and comments. I just cannot bring myself to add call a function rpmMacroIsParameterized()...

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/1053#discussion_r375752797
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20200206/91cb142b/attachment.html>


More information about the Rpm-maint mailing list