On 7/17/12 3:11 PM, Jonathan "Duke" Leto wrote:
Howdy,
It looks like Parrot_get_cpu_type is only defined in
src/platform/generic/misc.c and src/platform/win32/misc.c but not
src/platform/netbsd/misc.c .
Not sure if that is the issue, but it seems likely.
Especially since we haven't had a Smolder report on NetBSD since March
27! :-( http://smolder.parrot.org/app/projects/smoke_reports/1
Some of our other Smolder categories are similarly decrepit:
(linux) ia64: none since Feb 18
(linux) llvm-gcc 4.5: none since Oct 15 2011
sparc32: none since Feb 26
sparc64: none since Feb 27
etc.
Andy: What happens if you try the monkey-patch attached (directly
copied from src/platform/generic/misc.c; utterly untested as I have no
access to NetBSD)?
Thank you very much.
Jim Keenan
diff --git a/src/platform/netbsd/misc.c b/src/platform/netbsd/misc.c
index db249ba..c6bd806 100644
--- a/src/platform/netbsd/misc.c
+++ b/src/platform/netbsd/misc.c
@@ -53,6 +53,33 @@ Parrot_platform_init_code(void)
/*
+=item C<STRING *Parrot_get_cpu_type(Parrot_Interp)>
+
+Fetch CPU type for non-win32 systems
+For win32, look in platform/win32/misc.c
+
+=back
+
+=cut
+
+*/
+
+STRING *
+Parrot_get_cpu_type(Parrot_Interp interp) {
+ struct utsname uname_info;
+ char *proc_arch = "";
+
+#ifdef PARROT_HAS_HEADER_SYSUTSNAME
+ uname(&uname_info);
+ proc_arch = uname_info.machine;
+#endif
+ return Parrot_str_new_init(interp, proc_arch, strlen(proc_arch),
+ Parrot_ascii_encoding_ptr, 0);
+
+}
+
+/*
+
=back
=cut
_______________________________________________
http://lists.parrot.org/mailman/listinfo/parrot-dev