Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to Discount 2.2.7d #36

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Conversation

soult
Copy link

@soult soult commented Oct 5, 2024

Update to the latest maintenance release of discount v2 and apply a small patch to compile properly with GCC 14 and similar.

soult and others added 3 commits October 5, 2024 15:33
The discount library fails to compile with GCC 14. The author of the library
has already fixed the issue for discount v3.0.0+[1], but upgrading would
require adjusting to some significant API changes.

This commit applies a patch provided by Atri Bhattacharya for OpenSUSE[1] and
also used by Gentoo.[2]

1: Orc/discount#283
2: https://bugs.gentoo.org/894560
@Songmu
Copy link
Collaborator

Songmu commented Oct 29, 2024

The following error occurred with the latest version on macOS Sequoia, and I can install it with this pull request branch. I hope it will be merged soon.

cc -fPIC -Wno-implicit-int -I. -g -c main.c
main.c:311:29: error: incompatible function pointer types passing 'char *(char *, int, char *)' to parameter of type 'mkd_callback_t' (aka 'char *(*)(const char *, const int, void *)') [-Wincompatible-function-pointer-types]
  311 |             mkd_e_code_format(doc, external_codefmt);
      |                                    ^~~~~~~~~~~~~~~~
./mkdio.h:71:45: note: passing argument to parameter here
   71 | void mkd_e_code_format(void*, mkd_callback_t);
      |                                             ^
1 error generated.
make[1]: *** [main.o] Error 1
make: *** [discount-2.2.7/libmarkdown.a] Error 2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants