this repo has no description
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge pull request #1941 from peterhil/main

Building on FreeBSD

authored by

Vadim Grigoruk and committed by
GitHub
986d81ad 2c024c51

+34
+19
CMakeLists.txt
··· 107 107 108 108 if(UNIX AND NOT APPLE AND NOT EMSCRIPTEN AND NOT ANDROID AND NOT N3DS) 109 109 set(LINUX TRUE) 110 + 111 + if(CMAKE_HOST_SYSTEM_NAME STREQUAL "FreeBSD") 112 + set(FREEBSD TRUE) 113 + endif() 110 114 endif() 111 115 112 116 set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib) ··· 436 440 437 441 add_library(tic80core${SCRIPT} STATIC ${TIC80CORE_SRC}) 438 442 443 + if (FREEBSD) 444 + target_include_directories(tic80core${SCRIPT} PRIVATE ${SYSROOT_PATH}/usr/local/include) 445 + target_link_directories(tic80core${SCRIPT} PRIVATE ${SYSROOT_PATH}/usr/local/lib) 446 + endif() 447 + 439 448 target_include_directories(tic80core${SCRIPT} 440 449 PRIVATE 441 450 ${THIRDPARTY_DIR}/moonscript ··· 520 529 if(BUILD_SDL AND BUILD_PLAYER AND NOT RPI) 521 530 522 531 add_executable(player-sdl WIN32 ${CMAKE_SOURCE_DIR}/src/system/sdl/player.c) 532 + 533 + if (FREEBSD) 534 + target_include_directories(player-sdl PRIVATE ${SYSROOT_PATH}/usr/local/include) 535 + target_link_directories(player-sdl PRIVATE ${SYSROOT_PATH}/usr/local/lib) 536 + endif() 523 537 524 538 target_include_directories(player-sdl PRIVATE 525 539 ${THIRDPARTY_DIR}/sdl2/include ··· 1035 1049 1036 1050 if(BUILD_TOUCH_INPUT) 1037 1051 target_compile_definitions(tic80 PRIVATE TOUCH_INPUT_SUPPORT) 1052 + endif() 1053 + 1054 + if (FREEBSD) 1055 + target_include_directories(tic80 PRIVATE ${SYSROOT_PATH}/usr/local/include) 1056 + target_link_directories(tic80 PRIVATE ${SYSROOT_PATH}/usr/local/lib) 1038 1057 endif() 1039 1058 1040 1059 if(RPI)
+15
README.md
··· 182 182 Make sure to update the absolute path to the tic80 binary in the script, or 183 183 update the launch arguments. 184 184 185 + ## FreeBSD 186 + run the following commands in the Terminal 187 + ``` 188 + sudo pkg install gcc git cmake ruby libglvnd libglu freeglut mesa-devel mesa-dri alsa-lib 189 + git clone --recursive https://github.com/nesbox/TIC-80 && cd TIC-80/build 190 + cmake .. 191 + make -j4 192 + ``` 193 + 194 + Mesa looks for swrast_dri.so from the wrong path, so also symlink it: 195 + 196 + ``` 197 + sudo ln -s /usr/local/lib/dri/swrast_dri.so /usr/local/lib/dri-devel/ 198 + ``` 199 + 185 200 # Install instructions 186 201 187 202 ## Linux