Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
X
xpdevplus
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Deucе
xpdevplus
Commits
4599a06a
Commit
4599a06a
authored
3 years ago
by
Stephen Hurd
Browse files
Options
Downloads
Patches
Plain Diff
Use pkg-config for SDL2 explicitly
The implicit search was unreliable
parent
42c8f82e
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
ciolib/CMakeLists.txt
+5
-2
5 additions, 2 deletions
ciolib/CMakeLists.txt
xpdev/CMakeLists.txt
+3
-3
3 additions, 3 deletions
xpdev/CMakeLists.txt
with
8 additions
and
5 deletions
ciolib/CMakeLists.txt
+
5
−
2
View file @
4599a06a
...
...
@@ -9,8 +9,11 @@ find_package(X11)
# ncurses.h
set
(
CURSES_NEED_WIDE TRUE
)
find_package
(
Threads REQUIRED
)
if
(
NOT WIN32
)
find_package
(
Curses
)
find_package
(
SDL2
)
find_package
(
PkgConfig
)
pkg_check_modules
(
SDL2 sdl2
)
endif
()
set
(
SOURCE
allfonts.c
...
...
This diff is collapsed.
Click to expand it.
xpdev/CMakeLists.txt
+
3
−
3
View file @
4599a06a
...
...
@@ -8,8 +8,8 @@ find_package(Threads)
find_package
(
X11
)
if
(
NOT WIN32
)
find_package
(
PkgConfig
)
pkg_check_modules
(
SDL2 sdl2
)
endif
()
FIND_PACKAGE
(
SDL2
)
set
(
SOURCE
conwrap.c
...
...
@@ -80,7 +80,7 @@ if(NOT WIN32)
list
(
APPEND SOURCE xpsem.c
)
endif
()
if
(
SDL2_
FOUND
)
if
(
SDL2_
INCLUDE_DIRS
)
list
(
APPEND SOURCE sdlfuncs.c
)
if
(
${
CMAKE_SYSTEM_NAME
}
MATCHES
"Darwin"
)
list
(
APPEND SOURCE SDLMain.m
)
...
...
@@ -156,7 +156,7 @@ if(HAS_SRANDOMDEV_FUNC)
target_compile_definitions
(
xpdev PRIVATE HAS_SRANDOMDEV_FUNC
)
endif
()
if
(
SDL2_
FOUND
)
if
(
SDL2_
INCLUDE_DIRS
)
target_include_directories
(
xpdev PUBLIC
${
SDL2_INCLUDE_DIRS
}
)
set
(
WITH_SDL_AUDIO TRUE PARENT_SCOPE
)
endif
()
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment