ffi-simple/main.scm

(define-module (main)
  #:use-module (system foreign)
  #:export (plus))

(define lib (dynamic-link "main"))

(define plus
  (pointer->procedure
   int
   (dynamic-func "Plus" lib)
   (list int int)))