[gambit-list] My New Segfault (Re: Tracking Down a Segfault)
Joel J. Adamson <adamsonj@email.unc.edu>
adamsonj at email.unc.edu
Fri Sep 5 13:10:17 EDT 2008
>>>>> "Marc" == Marc Feeley <feeley at iro.umontreal.ca> writes:
Marc> Hard to say without access to your code...
The code is available for svn checkout with
# svn co http://chondestes.bio.unc.edu/svn/genxic/trunk/ genxic
To build the loadable library, you will need the GNU Scientific Library.
Marc> What other c-lambdas and c- defines do you have?
Plenty of c-lambda, spread out over all the files that start with
"gsl-", but here are all the c-defines and c-define-types:
;; -*- mode:scheme -*-
;;$Id$
;;
;; gsl-genx.scm
;; This file is part of genXic
;; Copyright (C) 2008 Joel J. Adamson
;; genXic is free software; you can redistribute it and/or modify it
;; under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 3, or (at your option)
;; any later version.
;; This program is distributed in the hope that it will be useful, but
;; WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
;; General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with this program (see the file COPYING); if not, write to
;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth
;; Floor, Boston, MA 02110-1301, USA.
;; include header file for GSL API
(c-declare "#include \"../c/gsl_genx.h\"")
;; Scheme function for getting data out of f64vectors
(c-define (proc1 f64vec i)
(scheme-object int)
double
"f64vector_ref" ""
(f64vector-ref f64vec i))
(c-define (proc2 f64vec)
(scheme-object)
int
"f64vector_length" ""
(f64vector-length f64vec))
;; declare types
;; gsl-matrix pointer
(c-define-type gsl-matrix*
(pointer "gsl_matrix"
gsl-matrix*
;; release function
"GENXIC_RELEASE_gsl_obj"))
;; gsl-vector pointer
(c-define-type gsl-vector*
(pointer "gsl_vector"
gsl-vector*
"GENXIC_RELEASE_gsl_obj"))
(c-define-type gsl_rng*
(pointer "gsl_rng"
gsl_rng*
"GENXIC_RELEASE_gsl_obj"))
;; another important release function:
;;
;; "VADER_RELEASE_HIM"
(define-macro (gsl-pred tag obj)
`(and (foreign? ,obj)
(equal? (foreign-tags ,obj)
'(,tag))))
;; boolean for gsl-vector pointer
(define (gsl-vector*? gsl-object)
(gsl-pred gsl-vector* gsl-object))
;; boolean for gsl-matrix pointer
(define (gsl-matrix*? gsl-object)
(gsl-pred gsl-matrix* gsl-object))
(define (gsl-rng*? gsl-object)
(gsl-pred gsl-rng* gsl-object))
(include "gsl-structures.scm")
(include "gsl-lalgebra.scm")
(include "gsl-wrapper.scm")
(include "gsl-stochastic.scm")
;; end of gsl-genx.scm
Thanks for any suggestions ;)
Joel
--
Joel J. Adamson
University of North Carolina at Chapel Hill
CB #3280, Coker Hall
Chapel Hill, NC 27599-3280
Before you reply to this email, please read
http://www.unc.edu/~adamsonj/email-howto.html
More information about the Gambit-list
mailing list