Hi everyone,

I just tried to build parrot (something I hadn't done in about a month
and a half) and it failed to build due to gmp_version being undeclared
in src/pmc/bigint.pmc (not suprising since I don't have GMP installed).
Attached is a patch that fixes the problem for me. Using the
preprocessor was the only way I knew how to fix it.

- David

-- 
"Men have become the tools of their tools."
    -- Henry David Thoreau

Index: src/pmc/bigint.pmc
===================================================================
--- src/pmc/bigint.pmc  (revision 14630)
+++ src/pmc/bigint.pmc  (working copy)
@@ -492,14 +492,18 @@
 
 =item C<METHOD STRING* version()>
 
-Return GMP version string "x.y.z".
+Return GMP version string "x.y.z", or "0.0.0" if GMP is unavailable.
 
 =cut
 
 */
 
     METHOD STRING* version() {
+#ifdef PARROT_HAS_GMP
         return string_from_cstring(INTERP, gmp_version, 0);
+#else
+        return string_from_cstring(INTERP, "0.0.0", 0);
+#endif
     }
 
 /*

Reply via email to