mirror of
https://github.com/iio612/immich-native.git
synced 2026-04-17 03:51:06 +00:00
Add HEIF support and instructions
Signed-off-by: Juhyung Park <qkrwngud825@gmail.com>
This commit is contained in:
22
README.md
22
README.md
@@ -16,7 +16,9 @@ This repository provides instructions and helper scripts to install [Immich](htt
|
||||
|
||||
* Only the basic CPU configuration is used. Hardware-acceleration such as CUDA is unsupported. In my personal experience, importing about 10K photos on a x86 processor doesn't take an unreasonable amount of time (less than 30 minutes).
|
||||
|
||||
* JPEG XL support may differ official Immich due to base-image's dependency differences.
|
||||
* JPEG XL/RAW support may differ official Immich due to base-image's dependency differences.
|
||||
|
||||
* For HEIF support, see [below](#HEIF-Support).
|
||||
|
||||
## 1. Install dependencies
|
||||
|
||||
@@ -206,3 +208,21 @@ postgres=# \q
|
||||
# Optionally remove dependencies
|
||||
# Review /var/log/apt/history.log and remove packages you've installed
|
||||
```
|
||||
|
||||
## HEIF Support
|
||||
|
||||
* Apple devices use HEIF images instead of JPG.
|
||||
|
||||
* Immich supports HEIF but installing it natively requires building [Sharp](https://github.com/lovell/sharp) from source.
|
||||
|
||||
* Building Sharp from source in turn requires the latest `libvips-dev` to be installed.
|
||||
|
||||
* For Ubuntu, see my [arter97/libvips PPA](https://launchpad.net/~arter97/+archive/ubuntu/libvips) to install the latest `libvips`:
|
||||
|
||||
``` bash
|
||||
sudo add-apt-repository ppa:arter97/libvips
|
||||
sudo apt install libvips-dev
|
||||
sudo apt remove libvips*t64
|
||||
```
|
||||
|
||||
* If you installed the latest `libvips-dev`, the install script will detect this automatically and proceed to install Sharp from source.
|
||||
|
||||
16
install.sh
16
install.sh
@@ -174,7 +174,21 @@ rm cities500.zip
|
||||
|
||||
# Install sharp
|
||||
cd $APP
|
||||
pnpm install sharp
|
||||
# https://github.com/lovell/sharp/blob/main/src/common.h#L20
|
||||
VIPS_LOCAL_VERSION="$(pkg-config --modversion vips || true)"
|
||||
VIPS_TARGET_VERSION="8.17.3"
|
||||
if [[ "$(printf '%s\n' $VIPS_TARGET_VERSION $VIPS_LOCAL_VERSION | sort -V | head -n1)" == "$VIPS_LOCAL_VERSION" ]]; then
|
||||
echo "Local libvips-dev is installed, manually building sharp"
|
||||
pnpm remove sharp
|
||||
SHARP_FORCE_GLOBAL_LIBVIPS=1 npm_config_build_from_source=true pnpm add sharp --ignore-scripts=false --allow-build=sharp
|
||||
else
|
||||
if [ ! -z "$VIPS_LOCAL_VERSION" ]; then
|
||||
echo "Local libvips-dev is installed, but it's too out-of-date"
|
||||
echo "Detected $VIPS_LOCAL_VERSION, but $VIPS_TARGET_VERSION or higher is required"
|
||||
sleep 5
|
||||
fi
|
||||
pnpm install sharp
|
||||
fi
|
||||
|
||||
# Setup upload directory
|
||||
mkdir -p $IMMICH_PATH/upload
|
||||
|
||||
Reference in New Issue
Block a user