mirror of
https://github.com/CompeyDev/lei.git
synced 2024-12-12 12:50:42 +00:00
fix: linking issues, explicitly link against libstdc++
This commit is contained in:
parent
3e906f1c0e
commit
a0bf86ec76
4 changed files with 30 additions and 5 deletions
|
@ -2,7 +2,7 @@ package internal
|
|||
|
||||
/*
|
||||
#cgo CFLAGS: -Iluau/VM/include -I/usr/lib/gcc/x86_64-pc-linux-gnu/14.1.1/include
|
||||
#cgo LDFLAGS: -L${SRCDIR}/luau/cmake -lLuau.VM
|
||||
#cgo LDFLAGS: -L${SRCDIR}/luau/cmake -lLuau.VM -lm -lstdc++
|
||||
#include <lua.h>
|
||||
#include <lualib.h>
|
||||
#include <stdlib.h>
|
||||
|
|
|
@ -2,7 +2,7 @@ package internal
|
|||
|
||||
/*
|
||||
#cgo CFLAGS: -Iluau/VM/include -I/usr/lib/gcc/x86_64-pc-linux-gnu/14.1.1/include
|
||||
#cgo LDFLAGS: -L${SRCDIR}/luau/cmake -lLuau.VM
|
||||
#cgo LDFLAGS: -L${SRCDIR}/luau/cmake -lLuau.VM -lm -lstdc++
|
||||
#include <lua.h>
|
||||
#include <lualib.h>
|
||||
#include <stdlib.h>
|
||||
|
@ -269,8 +269,5 @@ func PushInteger(L *C.lua_State, n lua_Integer) {
|
|||
}
|
||||
|
||||
// TODO: Vector 3 & 4
|
||||
func PushVector(L *C.lua_State, x float32, y float32, z float32) {
|
||||
C.lua_pushvector(L, C.float(x), C.float(y), C.float(z))
|
||||
}
|
||||
|
||||
// TODO: Rest of it
|
||||
|
|
14
internal/vector3.go
Normal file
14
internal/vector3.go
Normal file
|
@ -0,0 +1,14 @@
|
|||
//go:build !LUAU_VECTOR4
|
||||
|
||||
package internal
|
||||
|
||||
/*
|
||||
#cgo CFLAGS: -Iluau/VM/include -I/usr/lib/gcc/x86_64-pc-linux-gnu/14.1.1/include
|
||||
#cgo LDFLAGS: -L${SRCDIR}/luau/cmake -lLuau.VM -lm -lstdc++
|
||||
#include <lua.h>
|
||||
*/
|
||||
import "C"
|
||||
|
||||
func PushVector(L *C.lua_State, x float32, y float32, z float32) {
|
||||
C.lua_pushvector(L, C.float(x), C.float(y), C.float(z))
|
||||
}
|
14
internal/vector4.go
Normal file
14
internal/vector4.go
Normal file
|
@ -0,0 +1,14 @@
|
|||
//go:build LUAU_VECTOR4
|
||||
|
||||
package internal
|
||||
|
||||
/*
|
||||
#cgo CFLAGS: -Iluau/VM/include -I/usr/lib/gcc/x86_64-pc-linux-gnu/14.1.1/include
|
||||
#cgo LDFLAGS: -L${SRCDIR}/luau/cmake -lLuau.VM -lm -lstdc++
|
||||
#include <lua.h>
|
||||
*/
|
||||
import "C"
|
||||
|
||||
func PushVector(L *C.lua_State, x float32, y float32, z float32, w float32) {
|
||||
C.lua_pushvector(L, C.float(x), C.float(y), C.float(z), C.float(w))
|
||||
}
|
Loading…
Reference in a new issue