Skip to content

Commit

Permalink
haha oops (fix luasocket compilation)
Browse files Browse the repository at this point in the history
  • Loading branch information
rollerozxa committed Sep 4, 2023
1 parent 9a33311 commit dd6111b
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 15 deletions.
17 changes: 10 additions & 7 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,13 @@ on:
paths:
- 'src/**'
- 'build-*/**'
- 'CMakeLists.txt'
- '.github/workflows/**.yml'
pull_request:
paths:
- 'src/**'
- 'build-*/**'
- 'CMakeLists.txt'
- '.github/workflows/**.yml'

jobs:
Expand Down Expand Up @@ -44,6 +46,7 @@ jobs:
mingw-w64-x86_64-toolchain
autotools
mingw-w64-x86_64-curl
mingw-w64-x86_64-glew
mingw-w64-x86_64-gtk3
mingw-w64-x86_64-libpng
mingw-w64-x86_64-libjpeg-turbo
Expand All @@ -56,21 +59,21 @@ jobs:
- name: Build
run: |
cd build-windows/
./autogen.sh
./configure
./go --silent --release
mkdir build
cd build
cmake .. -G Ninja
ninja -j4
- name: Bundle together
run: |
cd build-windows/
bash make_release.sh
cd build
bash ../packaging/windows_release.sh
- name: Upload output as artifact
uses: actions/upload-artifact@v3
with:
name: principia-setup.exe
path: build-windows/principia-setup.exe
path: build/principia-setup.exe

android:
runs-on: ubuntu-20.04
Expand Down
13 changes: 5 additions & 8 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -84,11 +84,7 @@ if(NOT SCREENSHOT_BUILD)
${GLEW_INCLUDE_DIRS}
${GTK3_INCLUDE_DIRS})

if(WIN32) # TODO: Fix Luasocket building on Windows
set(USE_LUASOCKET false)
else()
option(USE_LUASOCKET "Build with Luasocket support" TRUE)
endif()
option(USE_LUASOCKET "Build with Luasocket support" TRUE)
else()
set(USE_LUASOCKET false)
endif()
Expand All @@ -98,10 +94,10 @@ if(USE_LUASOCKET)
set(LUASOCKET_FLAGS "-DBUILD_LUASOCKET")

if(WIN32)
set(LUAROCKS_PLAT_SRC src/luasocket/wsocket.c)
set(LUASOCKET_PLAT_SRC src/luasocket/wsocket.c)
else()
set(LUASOCKET_FLAGS "${LUASOCKET_FLAGS} -DLUASOCKET_INET_PTON")
set(LUAROCKS_PLAT_SRC
set(LUASOCKET_PLAT_SRC
src/luasocket/usocket.c
src/luasocket/unix.c)
endif()
Expand All @@ -117,7 +113,8 @@ if(USE_LUASOCKET)
src/luasocket/select.c
src/luasocket/tcp.c
src/luasocket/timeout.c
src/luasocket/udp.c)
src/luasocket/udp.c
${LUASOCKET_PLAT_SRC})
endif()

include_directories(src/tms/backends/${TMS_BACKEND}/)
Expand Down

0 comments on commit dd6111b

Please sign in to comment.