[vim/vim] Build failure on RHEL8 due to Pango 1.44+ dependency (Issue #20952)
Chris Hamilton (Vim Github Repository) <[email protected]> Wed, 05 Aug 2026 08:24:44 -0700
| Newsgroups | gmane.editors.vim.devel |
|---|---|
| Message-ID | <vim/vim/issues/[email protected]> |
tauchris created an issue (vim/vim#20952)
### Steps to reproduce
### Steps to Reproduce
In shell on RedHat Enterprise Linux 8 (RHEL8):
```bash
> git clone https://github.com/vim/vim.git vim
> cd vim
> git checkout f141c19dca843312
> ./configure
> make
```
Build fails:
```
hardcopy_pango.c:383:7: error: call to undeclared function 'pango_font_metrics_get_height';
ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
383 | (pango_font_metrics_get_height(metrics) - (ascent + descent))
| ^
/usr/bin/ld: objects/hardcopy_pango.o: in function mch_print_init':
hardcopy_pango.c:383: undefined reference to pango_font_metrics_get_height'
```
### Summary
Vim fails to build on RHEL8 systems (and any distribution with Pango < 1.44) when the GTK GUI with hardcopy-pango support is enabled, due to the use of `pango_font_metrics_get_height()` which was introduced in Pango 1.44.0 (March 2019).
### Details
**Affected commit:** f141c19dca84331202ea06f3035c04ffc63066d0
**Pull request:** #20648
**Affected files:** `src/hardcopy_pango.c` (specifically line 383)
**Root cause:**
- RHEL8 ships with Pango 1.42.3 (released 2018)
- `pango_font_metrics_get_height()` was added in Pango 1.44.0 (March 2019)
- The hardcopy-pango feature is enabled by default when building with GTK GUI support
### Impact
This makes Vim **unbuildable on RHEL8 without either:**
1. Disabling the GTK GUI entirely (`--disable-gui`)
2. Manually patching the build to disable hardcopy-pango
3. Downloading, building, verifying, and installing a newer Pango version (significant additional dependency management burden)
**Why this matters:**
- RHEL8 remains in **widespread use** in enterprise data centers and cloud services globally
- Red Hat provides full support for RHEL8 through **May 31, 2029** (over 3 years remaining)
- Millions of production systems run RHEL8, including critical infrastructure
### Expected behaviour
### Expected Behavior
On stable/supported mainstream Linux distros without custom patches to upgrade library versions, running `./configure ; make` should just work. All default-enabled features should be supported and functional on all mainstream platforms where this project is commonly built.
### Related issues
Several pull requests have addressed issues related to the original #20648 implementation, suggesting the feature may have been merged prematurely:
- Multiple follow-up fixes for deadlocks, rendering issues, and platform-specific problems
### Question about CI
Does the vim project have CI resources that test builds against multiple Linux distributions (particularly LTS/enterprise distributions like RHEL8, Ubuntu 20.04 LTS, Debian 11)? If such testing had been in place, perhaps this incompatibility would have been caught before the PR was merged...?
### Proposed solution
**Refactor `hardcopy_pango.c` to be compatible with Pango 1.42.x** (or older stable versions), unless there is a compelling technical reason that absolutely requires Pango 1.44+ features.
Alternatively, add a configure-time check for Pango >= 1.44 and provide a fallback implementation for older versions.
### Workaround
For users encountering this issue, configure vim with:
```bash
./configure --disable-gui
```
There may be other functional workarounds, such as configuring with `--disable-hardcopy-pango`; however there are open pull requests related to this configure flag, so it's not clear whether this works correctly. (I have not tested it.)
In any case, **adding configure flags should not be necessary** for a widely-deployed platform that will continue to be supported for several more years.
---
Thank you for your consideration. I believe maintaining compatibility with enterprise Linux distributions is important for vim's continued adoption in production environments.
### Version of Vim
9.2.0898
### Environment
Operating System: RHEL8
[vim_build_log.txt](https://github.com/user-attachments/files/30750161/vim_build_log.txt)
### Logs and stack traces
```shell
See attached build/log file in Environment section
```
--
Reply to this email directly or view it on GitHub:
https://github.com/vim/vim/issues/20952
You are receiving this because you are subscribed to this thread.
Message ID: <vim/vim/issues/[email protected]>
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To view this discussion visit https://groups.google.com/d/msgid/vim_dev/vim/vim/issues/20952%40github.com.