### ImageMagick version

7.1.1-26 and 7.1.1-27

### Operating system

Linux

### Operating system, version and so on

Arch

### Description

I have a locally-installed copy of ImageMagick that runs this command successfully:

```
$ magick convert -format jpg -resize 720 -quality 35 IMG_0002.HEIC IMG_0002.JPG
```

However, when I download the [latest static build from the Download page](), and verify it is static and does have HEIC support, I get an error with the same command using the static binary:

```
$ ./magick convert -format jpg -resize 720 -quality 35 IMG_0002.HEIC IMG_0002.JPG
convert: Unsupported feature: Unsupported codec (4.3000) `IMG_0002.HEIC' @ error/heic.c/IsHEIFSuccess/138.
convert: no images defined `IMG_0002.JPG' @ error/convert.c/ConvertImageCommand/3362.
```

Some more info about the two builds (notice the difference is the use of `./` for the static build):

```
$ magick -list format | grep HEIC
     AVIF  HEIC      rw+   AV1 Image File Format (1.17.6)
     HEIC  HEIC      rw+   High Efficiency Image Format (1.17.6)
     HEIF  HEIC      rw+   High Efficiency Image Format (1.17.6)

$ ./magick -list format | grep HEIC
     HEIC  r--   High Efficiency Image Format (1.17.6)

$ magick -version
Version: ImageMagick 7.1.1-26 Q16-HDRI x86_64 21914 https://imagemagick.org
Copyright: (C) 1999 ImageMagick Studio LLC
License: https://imagemagick.org/script/license.php
Features: Cipher DPC HDRI Modules OpenCL OpenMP(4.5) 
Delegates (built-in): bzlib cairo djvu fftw fontconfig freetype heic jbig jng jp2 jpeg jxl lcms lqr ltdl lzma openexr pangocairo png raqm raw rsvg tiff webp wmf x xml zip zlib zstd
Compiler: gcc (13.2)

$ ./magick -version
Version: ImageMagick 7.1.1-27 Q16-HDRI x86_64 9c64c662f:20240120 https://imagemagick.org
Copyright: (C) 1999 ImageMagick Studio LLC
License: https://imagemagick.org/script/license.php
Features: Cipher DPC HDRI OpenMP(4.5) 
Delegates (built-in): bzlib djvu fontconfig freetype heic jbig jng jp2 jpeg lcms lqr lzma openexr png raqm tiff webp x xml zlib
Compiler: gcc (9.4)
```

How come my HEIC image can't be decoded by the static build, and what can I do to make it work? Thanks!

### Steps to Reproduce

(Given above)

### Images

_No response_
HEIC images not recognized by static magick command, despite having the heic delegate built-in
This is a GitHub Issue
repo:ImageMagick
owner:ImageMagick
Title : HEIC images not recognized by static magick command, despite having the heic delegate built-in
Issue date:

--- start body ---
### ImageMagick version

7.1.1-26 and 7.1.1-27

### Operating system

Linux

### Operating system, version and so on

Arch

### Description

I have a locally-installed copy of ImageMagick that runs this command successfully:

```
$ magick convert -format jpg -resize 720 -quality 35 IMG_0002.HEIC IMG_0002.JPG
```

However, when I download the [latest static build from the Download page](), and verify it is static and does have HEIC support, I get an error with the same command using the static binary:

```
$ ./magick convert -format jpg -resize 720 -quality 35 IMG_0002.HEIC IMG_0002.JPG
convert: Unsupported feature: Unsupported codec (4.3000) `IMG_0002.HEIC' @ error/heic.c/IsHEIFSuccess/138.
convert: no images defined `IMG_0002.JPG' @ error/convert.c/ConvertImageCommand/3362.
```

Some more info about the two builds (notice the difference is the use of `./` for the static build):

```
$ magick -list format | grep HEIC
     AVIF  HEIC      rw+   AV1 Image File Format (1.17.6)
     HEIC  HEIC      rw+   High Efficiency Image Format (1.17.6)
     HEIF  HEIC      rw+   High Efficiency Image Format (1.17.6)

$ ./magick -list format | grep HEIC
     HEIC  r--   High Efficiency Image Format (1.17.6)

$ magick -version
Version: ImageMagick 7.1.1-26 Q16-HDRI x86_64 21914 https://imagemagick.org
Copyright: (C) 1999 ImageMagick Studio LLC
License: https://imagemagick.org/script/license.php
Features: Cipher DPC HDRI Modules OpenCL OpenMP(4.5) 
Delegates (built-in): bzlib cairo djvu fftw fontconfig freetype heic jbig jng jp2 jpeg jxl lcms lqr ltdl lzma openexr pangocairo png raqm raw rsvg tiff webp wmf x xml zip zlib zstd
Compiler: gcc (13.2)

$ ./magick -version
Version: ImageMagick 7.1.1-27 Q16-HDRI x86_64 9c64c662f:20240120 https://imagemagick.org
Copyright: (C) 1999 ImageMagick Studio LLC
License: https://imagemagick.org/script/license.php
Features: Cipher DPC HDRI OpenMP(4.5) 
Delegates (built-in): bzlib djvu fontconfig freetype heic jbig jng jp2 jpeg lcms lqr lzma openexr png raqm tiff webp x xml zlib
Compiler: gcc (9.4)
```

How come my HEIC image can't be decoded by the static build, and what can I do to make it work? Thanks!

### Steps to Reproduce

(Given above)

### Images

_No response_
--- end body ---
