mirror of
https://github.com/YunoHost-Apps/photoview_ynh.git
synced 2024-09-03 20:05:55 +02:00
cleanup traces of libheif
This commit is contained in:
parent
274407ef22
commit
7d553cdf25
4 changed files with 1 additions and 42 deletions
|
@ -54,14 +54,6 @@ ram.runtime = "200M"
|
||||||
|
|
||||||
autoupdate.strategy = "latest_github_release"
|
autoupdate.strategy = "latest_github_release"
|
||||||
|
|
||||||
[resources.sources.libheif]
|
|
||||||
url = "https://github.com/strukturag/libheif/releases/download/v1.12.0/libheif-1.12.0.tar.gz"
|
|
||||||
sha256 = "e1ac2abb354fdc8ccdca71363ebad7503ad731c84022cf460837f0839e171718"
|
|
||||||
|
|
||||||
autoupdate.strategy = "latest_github_release"
|
|
||||||
autoupdate.upstream = "https://github.com/strukturag/libheif"
|
|
||||||
autoupdate.asset = ".*\\.tar\\.gz"
|
|
||||||
|
|
||||||
[resources.system_user]
|
[resources.system_user]
|
||||||
|
|
||||||
[resources.install_dir]
|
[resources.install_dir]
|
||||||
|
|
|
@ -19,28 +19,6 @@ function set_go_vars {
|
||||||
|
|
||||||
go_shims_path=$goenv_install_dir/shims
|
go_shims_path=$goenv_install_dir/shims
|
||||||
go_path_full="$go_shims_path":"$(sudo -u $app bash -c 'echo $PATH')"
|
go_path_full="$go_shims_path":"$(sudo -u $app bash -c 'echo $PATH')"
|
||||||
# heif_lib_path="$install_dir/local/lib":"$(sudo -u $app bash -c 'echo $LIBRARY_PATH')"
|
|
||||||
# heif_ld_lib_path="$install_dir/local/lib":"$(sudo -u $app bash -c 'echo $LD_LIBRARY_PATH')"
|
|
||||||
# heif_cgo_cflags="-I$install_dir/local/include"
|
|
||||||
}
|
|
||||||
|
|
||||||
function build_libheif {
|
|
||||||
export GOPATH="$install_dir/build/go"
|
|
||||||
export GOCACHE="$install_dir/build/.cache"
|
|
||||||
|
|
||||||
cmake -S "$install_dir/libheif" -B "$install_dir/libheif/build" -DCMAKE_BUILD_TYPE=RELEASE -GNinja
|
|
||||||
cmake --build "$install_dir/libheif/build"
|
|
||||||
|
|
||||||
pushd "$install_dir/libheif" || ynh_die
|
|
||||||
# mkdir -p "$install_dir/local"
|
|
||||||
# chown -R $app:$app "$install_dir/local"
|
|
||||||
ynh_exec_as "$app" ./autogen.sh 2>&1
|
|
||||||
ynh_exec_as "$app" ./configure --prefix="$install_dir/local" --disable-gdk-pixbuf 2>&1
|
|
||||||
ynh_exec_as "$app" make clean 2>&1
|
|
||||||
ynh_exec_as "$app" make 2>&1
|
|
||||||
ynh_exec_as "$app" make install 2>&1
|
|
||||||
ynh_exec_as "$app" make clean 2>&1
|
|
||||||
popd || ynh_die
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function build_api {
|
function build_api {
|
||||||
|
@ -48,11 +26,8 @@ function build_api {
|
||||||
|
|
||||||
gobuild_env=(
|
gobuild_env=(
|
||||||
"PATH=$go_path_full"
|
"PATH=$go_path_full"
|
||||||
# "LIBRARY_PATH=$heif_lib_path"
|
|
||||||
# "LD_LIBRARY_PATH=$heif_ld_lib_path"
|
|
||||||
# "CGO_CFLAGS=$heif_cgo_cflags"
|
|
||||||
"GOENV_VERSION=$go_version"
|
"GOENV_VERSION=$go_version"
|
||||||
CGO_ENABLED=1
|
"CGO_ENABLED=1"
|
||||||
)
|
)
|
||||||
|
|
||||||
pushd "$install_dir/sources/api" || ynh_die
|
pushd "$install_dir/sources/api" || ynh_die
|
||||||
|
|
|
@ -27,7 +27,6 @@ ynh_install_nodejs --nodejs_version="$node_version"
|
||||||
ynh_script_progression --message="Setting up source files..." --weight=10
|
ynh_script_progression --message="Setting up source files..." --weight=10
|
||||||
|
|
||||||
ynh_setup_source --dest_dir="$install_dir/sources"
|
ynh_setup_source --dest_dir="$install_dir/sources"
|
||||||
ynh_setup_source --source_id=libheif --dest_dir="$install_dir/libheif"
|
|
||||||
|
|
||||||
mkdir -p "$install_dir/output/"{data,ui}
|
mkdir -p "$install_dir/output/"{data,ui}
|
||||||
|
|
||||||
|
@ -37,9 +36,6 @@ chown -R "$app:$app" "$data_dir"
|
||||||
#=================================================
|
#=================================================
|
||||||
# BUILD APP
|
# BUILD APP
|
||||||
#=================================================
|
#=================================================
|
||||||
# ynh_script_progression --message="Compiling libheif..." --weight=10
|
|
||||||
# build_libheif
|
|
||||||
|
|
||||||
ynh_script_progression --message="Compiling Go API..." --weight=10
|
ynh_script_progression --message="Compiling Go API..." --weight=10
|
||||||
build_api
|
build_api
|
||||||
|
|
||||||
|
|
|
@ -46,7 +46,6 @@ ynh_install_nodejs --nodejs_version="$node_version"
|
||||||
ynh_script_progression --message="Upgrading source files..." --weight=5
|
ynh_script_progression --message="Upgrading source files..." --weight=5
|
||||||
|
|
||||||
ynh_setup_source --dest_dir="$install_dir/sources" --full_replace=1
|
ynh_setup_source --dest_dir="$install_dir/sources" --full_replace=1
|
||||||
ynh_setup_source --source_id=libheif --dest_dir="$install_dir/libheif" --full_replace=1
|
|
||||||
mkdir -p "$install_dir/output/"{data,ui}
|
mkdir -p "$install_dir/output/"{data,ui}
|
||||||
|
|
||||||
chown -R "$app:$app" "$install_dir"
|
chown -R "$app:$app" "$install_dir"
|
||||||
|
@ -55,9 +54,6 @@ chown -R "$app:$app" "$data_dir"
|
||||||
#=================================================
|
#=================================================
|
||||||
# BUILD APP
|
# BUILD APP
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Compiling libheif..." --weight=70
|
|
||||||
build_libheif
|
|
||||||
|
|
||||||
ynh_script_progression --message="Compiling Go API..." --weight=165
|
ynh_script_progression --message="Compiling Go API..." --weight=165
|
||||||
build_api
|
build_api
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue