yes, swig generates snmp/net-snmp.scm with the following header... (define-module (snmp net-snmp))
(load-extension "libguile_snmp_net-snmp.so" "scm_init_snmp_net_snmp_module") (use-modules (oop goops) (Swig common)) (use-modules ((snmp net-snmp-primitive) :renamer (symbol-prefix-proc 'primitive:))) the net-snmp_wrap.c contains... SCM scm_init_snmp_net_snmp_module (void) { scm_c_define_module("snmp net-snmp-primitive", SWIG_init_helper, NULL); return SCM_UNSPECIFIED; } I can confirm that the correct versions of the various files are being loaded (have confirmed via strace previously whilst debugging other issues). As mentioned before, this is purely cosmetic in that the code does actually get run and work, it is the compilation that fails (thhough things carry on anyway) 2009/12/18 Ludovic Courtès <l...@gnu.org>: > Hi, > > Tristan Colgate <tcolg...@gmail.com> writes: > >> Ah, sorry.... >> >> ;;; note: autocompilation is enabled, set GUILE_AUTO_COMPILE=0 >> ;;; or pass the --no-autocompile argument to disable. >> ;;; compiling /usr/local/share/guile/site/snmp/net-snmp.scm >> ;;; WARNING: compilation of >> /usr/local/share/guile/site/snmp/net-snmp.scm failed: >> ;;; key misc-error, throw args (#f "~A ~S" ("no code for module" (snmp >> net-snmp-primitive)) #f) >> STRING: Unknown (edit /etc/snmp/snmpd.conf) >> STRING: pinot >> >> the snmp net-snmp-primitive module is provided by a load-extension in >> the swig wrapper module. >> it's loaded by the module that swig has generated (snmp net-snmp) > > So does the .so that’s loaded via ‘load-extension’ calls > ‘scm_c_define_module ()’, right? And ‘net-snmp.scm’ does: > > (define-module (snmp net-snmp) > #:export (...)) > > (load-extension ...) > > (use-modules (snmp net-snmp-primitive)) > > Right? > > Could you make sure with strace(1) or some such that the right .so gets > loaded? > > Thanks, > Ludo’. > > > > -- Tristan Colgate-McFarlane ---- "You can get all your daily vitamins from 52 pints of guiness, and a glass of milk"