From 701ef6ebd60105526e785b83ebcfb90b13ce8939 Mon Sep 17 00:00:00 2001 From: TatriX Date: Thu, 29 Jul 2021 22:34:05 +0200 Subject: [PATCH] Move sdl2 installation docs to separate files --- README.md | 47 ++++++++++------------------------------------- README_LINUX.md | 12 ++++++++++++ README_MACOS.md | 29 +++++++++++++++++++++++++++++ 3 files changed, 51 insertions(+), 37 deletions(-) create mode 100644 README_LINUX.md create mode 100644 README_MACOS.md diff --git a/README.md b/README.md index 3759671..de6f6b4 100644 --- a/README.md +++ b/README.md @@ -6,42 +6,7 @@ Adapted from http://lazyfoo.net/tutorials/SDL/ The tutorial requires that SDL2, SDL2 Image, and SDL2 TTF are installed before running the examples. -### Mac OS X - -Mac OS X requires each library to be downloaded and copied to -$HOME/Library/Frameworks or /Library/Frameworks. - - Library Name | Download Link - ------------ | ------------- - SDL2 | https://www.libsdl.org/download-2.0.php - SDL2 Image | https://www.libsdl.org/projects/SDL_image - SDL2 TTF | https://www.libsdl.org/projects/SDL_ttf - -Running the tutorials will cause Catalina to report that the framework cannot be -opened because the developer cannot be verified. The workaround for this problem -is the following: - -1. Navigate to System Preferences -> Security & Privacy -> General on the Mac - -2. Run repl.sh - -3. When the dialog appears about the developer not being verified, click the -"Cancel" button. - -4. Examine the Security & Privacy screen for a button called "Allow Anyway" for -the framework. Click the "Allow Anyway" button with the identified framework. - -5. The verification dialog will now appear a second time, but there will be an -option to "Open" the framework. Click "Open". - -6. Repeat steps 3 through 5 for the different frameworks. - -### Linux - -The SDL2 libraries can be installed on a Debian based system with the command -below. - - apt install libsdl2-2.0 libsdl2-image-2.0 libsdl2-ttf-2.0 + See instructions for [Linux](README_LINUX.md) and [macOS](README_MACOS.md) respectively. ## Installation @@ -52,9 +17,17 @@ git clone https://github.com/TatriX/cl-sdl2-tutorial/ ~/quicklisp/local-projects ``` ```lisp -> (ql:quickload :sdl2-tutorial) +(ql:quickload :sdl2-tutorial) +``` + +or [asdf](https://common-lisp.net/project/asdf/) +``` +git clone https://github.com/TatriX/cl-sdl2-tutorial/ ~/common-lisp ``` +```lisp +(asdf:load-system "sdl2-tutorial") +``` ## Running the Examples diff --git a/README_LINUX.md b/README_LINUX.md new file mode 100644 index 0000000..b252c57 --- /dev/null +++ b/README_LINUX.md @@ -0,0 +1,12 @@ +## Installing the SDL2 Libraries Linux + +## Debian + +The SDL2 libraries can be installed on a Debian based system with the command +below. + + apt install libsdl2-2.0 libsdl2-image-2.0 libsdl2-ttf-2.0 + +## Arch + + sudo pacman -S sdl2 sdl2_image sdl2_ttf diff --git a/README_MACOS.md b/README_MACOS.md new file mode 100644 index 0000000..a7a6dd1 --- /dev/null +++ b/README_MACOS.md @@ -0,0 +1,29 @@ +### Mac OS X + +Mac OS X requires each library to be downloaded and copied to +$HOME/Library/Frameworks or /Library/Frameworks. + + Library Name | Download Link + ------------ | ------------- + SDL2 | https://www.libsdl.org/download-2.0.php + SDL2 Image | https://www.libsdl.org/projects/SDL_image + SDL2 TTF | https://www.libsdl.org/projects/SDL_ttf + +Running the tutorials will cause Catalina to report that the framework cannot be +opened because the developer cannot be verified. The workaround for this problem +is the following: + +1. Navigate to System Preferences -> Security & Privacy -> General on the Mac + +2. Run repl.sh + +3. When the dialog appears about the developer not being verified, click the +"Cancel" button. + +4. Examine the Security & Privacy screen for a button called "Allow Anyway" for +the framework. Click the "Allow Anyway" button with the identified framework. + +5. The verification dialog will now appear a second time, but there will be an +option to "Open" the framework. Click "Open". + +6. Repeat steps 3 through 5 for the different frameworks.