Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Garph

Pages: [1]
1
General / Re: Static Linking Examples
« on: February 21, 2020, 08:12:43 pm »
Here is what works:

Project CMakeLists.txt
(click to show/hide)

hello-sfml CMakeLists.txt
(click to show/hide)

Building from command line:
(click to show/hide)

2
General / Re: Static Linking Examples
« on: February 21, 2020, 06:29:51 pm »
Oof, just found https://github.com/SFML/SFML/blob/master/cmake/SFMLConfig.cmake.in

I'll update with results should this work

3
General / Static Linking Examples
« on: February 21, 2020, 06:27:32 pm »
Hey All,

I am building SFML from source, on Windows using CMake, Ninja and Clang. Here are my toolchain's versions (from cmd):

$ cmake -version
cmake version 3.17.0-rc1


$ clang --version
clang version 9.0.0 (tags/RELEASE_900/final)
Target: i686-pc-windows-msvc
Thread model: posix
InstalledDir: C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\Llvm\bin


$ ninja --version
1.8.2


My project's root has a SFML directory, a build directory (for cmake output) and a CMakeLists.txt

cmake_minimum_required (VERSION 3.17)
project (game C CXX)

set (CMAKE_C_COMPILER "clang")
set (CMAKE_CXX_COMPILER "clang++")

add_subdirectory (SFML)


I configure the project as follows:

$ cmake .. -G Ninja -DBUILD_SHARED_LIBS=FALSE -DSFML_BUILD_EXAMPLES=TRUE
-- Configuring done
-- Generating done
-- Build files have been written to: C:/Users/mattp/source/game/build


And build:

ninja -j all

However, when launching build/SFML/examples/pong/pong-d.exe I fail to link with OpenAl32.dll. It seems I'm missing something here. Coming from the embedded devices world, I'm very new to dynamic linking and would appreciate some guidance.

Pages: [1]
anything