Closed cbaggers closed 6 years ago
First issue I found was that SDL2 itself was broken by high sierra so you have to update the dylibs. However even after that the example breaks.
CL-SDL2 itself is fine, I can create a context etc using cl-sdl2 from CEPL which doesnt use any other threads in the process.
This must be just an issue with the example
Just as a datapoint, this works perfectly:
(defun run1 ()
(print "hi")
(print "about to init")
(sdl2:init)
(unwind-protect
(progn ()
(print "init'd ok")
(print "making an event we can poll into")
(let ((event (sdl2:new-event)))
(print "event created")
(print "Next will poll a single event")
(print (= 0 (sdl2:next-event event :poll nil)))
(print "event poll'd")
(print "now going to poll in a loop")
(loop :until (= 0 (sdl2:next-event event :poll nil)))
(print "loop poll worked")))
(print "about to quit")
(sdl2:quit)
(print "successfully quit")))
@cbaggers Would you consider a PR? I don't know of anyone else using macOS at this time.
@mfiano sure, I'll have to work out what it is first :) Im a bit stuck on another macOS cl-sdl2 threading issue right now. I'll probably file a ticket for it but I understand you wont be able to look at it
Ok thanks. I really don't have the slightest about macOS and don't have the hardware available to test.
Ok closing this as the thread issue was me not reading the README. using make-this-thread-main set the correct main thread and so now the examples crash with the same segfault as Im seeing elsewhere. I'll open a new issue for that
Steps to reproduce
(ql:quickload :sdl2/examples)
(sdl2-examples:basic-test)
Log