lispgames / cl-sdl2

Common Lisp bindings for SDL2 using C2FFI.
MIT License
304 stars 82 forks source link

Spec generation fails on OpenBSD #172

Open rpx99 opened 3 weeks ago

rpx99 commented 3 weeks ago

I am trying to regenerate the spec files.

After updating the path (see 171)

diff --git a/src/autowrap.lisp b/src/autowrap.lisp
index 370cc0e..e27c180 100644
--- a/src/autowrap.lisp
+++ b/src/autowrap.lisp
@@ -22,7 +22,7 @@
  :sysincludes `,(cl:append
                   #+openbsd (cl:list "/usr/X11R6/include")
                   #+(and unix (not darwin))
-                  (cl:list "/usr/lib/clang/13.0.1/include/")
+                  (cl:list "/usr/lib/clang/16/include/")
                   #+darwin (cl:list "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/"))
  :exclude-definitions ("SDL_main"
                        "SDL_LogMessageV"

and executing this command

sbcl --load "sdl2.asd" --eval "(ql:quickload '(:sdl2))" --eval "(uiop:quit)"

I get this error:

tron$ sbcl --load "sdl2.asd" --eval "(ql:quickload '(:sdl2))" --eval "(uiop:quit)"  
This is SBCL 2.4.8.openbsd.sbcl-2.4.8, an implementation of ANSI Common Lisp.
More information about SBCL is available at <http://www.sbcl.org/>.

SBCL is free software, provided as is, with absolutely no warranty.
It is mostly in the public domain; some portions are provided under
BSD-style licenses.  See the CREDITS and COPYING files in the
distribution for more information.
To load "sdl2":
  Load 1 ASDF system:
    sdl2
; Loading "sdl2"
..................................................
[package sdl2].; 
; caught ERROR:
;   READ error during COMPILE-FILE:
;   
;     Symbol "+SDL-PIXELFORMAT-UNKNOWN+" not found in the SDL2-FFI package.
;   
;       Line: 4, Column: 69, File-Position: 106
;   
;       Stream: #<SB-INT:FORM-TRACKING-STREAM for "file /home/rpx/common-lisp/cl-sdl2/src/constants.lisp" {1102F9D803}>

debugger invoked on a UIOP/LISP-BUILD:COMPILE-FILE-ERROR in thread
#<THREAD tid=230678 "main thread" RUNNING {1100BE00A3}>:
  COMPILE-FILE-ERROR while compiling #<CL-SOURCE-FILE "sdl2" "constants">

Installed ports:


tron$ pkg_info | grep sdl
sdl2-2.30.6         cross-platform multimedia library
sdl2-image-2.8.2p1  SDL2 image library
sdl2-ttf-2.22.0     SDL2 TrueType fonts library
tron$ pkg_info | grep c2   
c2ffi-16.0.0.0      extract FFI definitions from C, C++, and Objective

I have cloned latest cffi and cl-autowrap in my common-lisp folder (used by quicklisp).

Why is that? Thanks.