mirror of
https://github.com/mickael-kerjean/filestash.git
synced 2025-11-01 10:56:31 +08:00
improve (support): prepare support for raspberry pi
This commit is contained in:
@ -3,6 +3,13 @@ set -e
|
||||
|
||||
SCRIPTPATH="$( cd "$(dirname "$0")" ; pwd -P )"
|
||||
cd "$(dirname "$0")"/deps
|
||||
echo `pwd`
|
||||
curl -s https://downloads.filestash.app/upload/libresize_`uname -s`-`uname -m`.a > libresize.a
|
||||
curl -s https://downloads.filestash.app/upload/libtranscode_`uname -s`-`uname -m`.a > libtranscode.a
|
||||
|
||||
# AMD64 dependencies
|
||||
curl -s https://downloads.filestash.app/upload/libresize_`uname -s`-`uname -m`.a > libresize_linux_amd64.a &
|
||||
curl -s https://downloads.filestash.app/upload/libtranscode_`uname -s`-`uname -m`.a > libtranscode_linux_amd64.a &
|
||||
|
||||
# ARM dependencies
|
||||
curl -s https://downloads.filestash.app/upload/libresize_`uname -s`-`uname -m`.a > libresize_linux_arm.a &
|
||||
curl -s https://downloads.filestash.app/upload/libtranscode_`uname -s`-`uname -m`.a > libtranscode_linux_arm.a &
|
||||
|
||||
wait
|
||||
|
||||
@ -1,9 +1,9 @@
|
||||
package plg_image_light
|
||||
// #cgo pkg-config:glib-2.0
|
||||
|
||||
// #cgo CFLAGS: -I./deps/src
|
||||
// #cgo LDFLAGS: -lm -lgmodule-2.0 -lgobject-2.0 -lglib-2.0 -ldl -L./deps -l:libresize.a
|
||||
// #include "libresize.h"
|
||||
// #cgo pkg-config:glib-2.0
|
||||
// #include "glib-2.0/glib.h"
|
||||
// #include "libresize.h"
|
||||
import "C"
|
||||
|
||||
import (
|
||||
|
||||
4
server/plugin/plg_image_light/lib_resize_linux_amd64.go
Normal file
4
server/plugin/plg_image_light/lib_resize_linux_amd64.go
Normal file
@ -0,0 +1,4 @@
|
||||
package plg_image_light
|
||||
|
||||
// #cgo LDFLAGS: -lm -lgmodule-2.0 -lgobject-2.0 -lglib-2.0 -ldl -L./deps -l:libresize_linux_amd64.a
|
||||
import "C"
|
||||
4
server/plugin/plg_image_light/lib_resize_linux_arm.go
Normal file
4
server/plugin/plg_image_light/lib_resize_linux_arm.go
Normal file
@ -0,0 +1,4 @@
|
||||
package plg_image_light
|
||||
|
||||
// #cgo LDFLAGS: -lm -lgmodule-2.0 -lgobject-2.0 -lglib-2.0 -ldl -L./deps -l:libresize_linux_arm.a
|
||||
import "C"
|
||||
@ -1,6 +1,5 @@
|
||||
package plg_image_light
|
||||
// #cgo CFLAGS: -I./deps/src
|
||||
// #cgo LDFLAGS: -lm -lpthread -L./deps -l:libtranscode.a
|
||||
// #include "libtranscode.h"
|
||||
import "C"
|
||||
|
||||
|
||||
@ -0,0 +1,4 @@
|
||||
package plg_image_light
|
||||
|
||||
// #cgo LDFLAGS: -lm -lpthread -L./deps -l:libtranscode_linux_amd64.a
|
||||
import "C"
|
||||
4
server/plugin/plg_image_light/lib_transcode_linux_arm.go
Normal file
4
server/plugin/plg_image_light/lib_transcode_linux_arm.go
Normal file
@ -0,0 +1,4 @@
|
||||
package plg_image_light
|
||||
|
||||
// #cgo LDFLAGS: -lm -lpthread -L./deps -l:libtranscode_linux_arm.a
|
||||
import "C"
|
||||
Reference in New Issue
Block a user