1. 13 Feb, 2019 4 commits
  2. 12 Feb, 2019 1 commit
  3. 10 Feb, 2019 1 commit
  4. 09 Feb, 2019 5 commits
    • John Croisant's avatar
      Updated README and CHANGELOG. · eacb9f4c
      John Croisant authored
    • John Croisant's avatar
      Bumped egg version number to 0.3.0. · 157cffd0
      John Croisant authored
      Because 0.2.1 was never released, there is no sdl2-0.2.1 feature
    • John Croisant's avatar
      Automatically discover SDL2 compiler/linker flags. · 4d4adb5f
      John Croisant authored
      Added custom build script for CHICKEN 5, roughly equivalent to the
      logic in the CHICKEN 4 setup file. This should make installation
      of the egg "just work" for most users, without having to manually
      specify compiler/linker flags.
      For special cases, the user can set the SDL2_CFLAGS and SDL2_LDFLAGS
      environment variables to manually specify compiler/linker flags.
    • John Croisant's avatar
      Removed unnecessary imports. · b955aa5b
      John Croisant authored
    • John Croisant's avatar
      Improved how feature identifiers are registered. · edae72aa
      John Croisant authored
      The new module sdl2-features now registers feature identifiers
      related to the sdl2 egg and libSDL version. This significantly
      simplifies the build process, and works on both CHICKEN 4 and 5.
      The downside is that users must perform an extra step if they want to
      check the feature identifiers with cond-expand or the #+foo syntax:
      - CHICKEN 4: (use-for-syntax sdl2)
      - CHICKEN 5: (import-for-syntax sdl2)
  5. 08 Feb, 2019 2 commits
    • John Croisant's avatar
      Updated tests and demos to work with CHICKEN 5. · 894ed5e6
      John Croisant authored
      But demos/opengl.scm does not currently work because it depends on
      several eggs which have not been ported to CHICKEN 5 yet.
    • John Croisant's avatar
      Updated egg to (mostly) work with CHICKEN 5. · a7cd39b1
      John Croisant authored
      There are two remaining issues:
      1. Compile flags are no longer automatically detected. The user must
         manually specify the flags using the CSC_OPTIONS env var.
         E.g. export CSC_OPTIONS="-C -I/usr/include/SDL2 -L -lSDL2"
      2. The libSDL-X.Y.Z+ "features" do not actually reflect the installed
         version of SDL. They always assume the installed SDL >= 2.0.4.
  6. 14 Sep, 2017 1 commit
    • John Croisant's avatar
      Fixed error when creating surfaces on 32-bit systems [#44]. · c45c9b3c
      John Croisant authored
      On 32-bit systems, CHICKEN represents exact integers using 31 bits,
      so values that required 32 bits would cause an error:
        (inexact->exact) inexact number cannot be represented as an exact number
      This directly affected `create-rgb-surface*` and
      `create-rgb-surface-from*`, and indirectly affected `make-surface`
      and `make-surface*` when creating 32-bit surfaces.
      This has been worked around by smuggling the values inside a
      `u32vector` data structure.
      Thanks to Kristian Lein-Mathisen for reporting this issue and
      suggesting the solution.
  7. 05 Jun, 2016 1 commit
    • John Croisant's avatar
      Improvements to installer (setup script). · 7301d14d
      John Croisant authored
      - Mac: automatically use frameworks if sdl2-config not available.
        Users no longer need to pass "-D sdl2-use-mac-framework".
        Installing should "just work" for most Mac users.
      - Renamed SDL2_LIBS env var to SDL2_LDFLAGS for clarity.
  8. 30 May, 2016 2 commits
  9. 29 May, 2016 2 commits
    • John Croisant's avatar
      Fixed potential security issue in SDL_SetError binding. · 03586fa1
      John Croisant authored
      This addresses the following warning during compile:
        sdl2-internals.c:3757:14: warning: format string is not a string literal
              (potentially insecure) [-Wformat-security]
      Besides, there is no benefit to treating the user string as a format
      string, because the binding does not allow passing any other args.
      The new SDL_SetError binding now uses up to 1024 chars of the
      user-provided string as verbatim content.
    • John Croisant's avatar
      Added support for compiling with frameworks on Mac. · 885d0803
      John Croisant authored
      Pass the "-D sdl2-use-mac-framework" flag to chicken-install.
      See README for more details.
  10. 28 May, 2016 1 commit
    • John Croisant's avatar
      Improved auto-detection of SDL2 compiler flags. · f834c684
      John Croisant authored
      - Instead of a single SDL2_FLAGS env var, there are now two:
        SDL2_CFLAGS and SDL2_LIBS. This allows users to specify the
        compiler and linker flags separately. These flags are further
        processed to prefix "-C" or "-L" before passing them to csc.
        This builds on the work of Christian Kellermann in 9f1dd7bc.
      - If the flags cannot be determined from the env vars or sdl2-config,
        the install script will abort with a helpful error message.
        Before, it would try (and fail) to compile the egg, resulting in
        a compiler error message, which users might not know how to fix.
      - Updated installation instructions in the README.
  11. 27 May, 2016 2 commits
    • John Croisant's avatar
    • John Croisant's avatar
      Fixed some structs' hash values changing after GC. · 91b30e2f
      John Croisant authored
      Since 0.2, managed color, keysym, point, and rect instances have
      internally held a locative to a blob. But when the GC runs, the
      locative changes, which causes the hash value of the instance to
      change. This causes problems when using these instances, or any
      user-defined record holding these instances, as hash table keys.
      This has been fixed by having those records hold a blob directly,
      then creating a locative during unwrapping. This is somewhat less
      efficient, because a new locative is created and discarded each time
      the struct is used. But that seems to be the necessary price for
      stable hash values.
      Related: CHICKEN issue 1293
  12. 20 May, 2016 1 commit
    • John Croisant's avatar
      Updated docs/using-sdl2-internals.md. · 3d23607f
      John Croisant authored
      - Added renderer and renderer-info (un)wrappers to the list.
      - Mentioned that records might hold locatives.
      - Linked to docs about how to check SDL version.
  13. 04 Mar, 2016 1 commit
    • Christian Kellermann's avatar
      Prefix linker and compiler flags for csc to pass through · 9f1dd7bc
      Christian Kellermann authored
      With this the output of sdl2-config gets prefixed properly, as some
      linker flags (e.g. "-R") are not recognised as such by csc.
      Note that if the user provides her own flags via environment
      variables, the prefixing needs to be done manually there. The setup
      script cannot guess which flag is a compiler and which is a linker
  14. 13 Feb, 2016 10 commits
  15. 12 Feb, 2016 4 commits
  16. 10 Feb, 2016 1 commit
    • John Croisant's avatar
      Changed sdl2:grabbed-window test. · 36516969
      John Croisant authored
      Before, it created a very small window in the corner of the screen.
      But, this resulted in the mouse cursor being moved to that location
      when the test ran, which was annoying. Now it creates a larger window
      in the center of the screen, so it is less likely to move the cursor.
  17. 08 Feb, 2016 1 commit