Imagick / imagick

🌈 The Imagick PHP extension 🌈
http://pecl.php.net/imagick
Other
547 stars 138 forks source link

New release with PHP 8 support? #358

Closed dzuelke closed 2 years ago

dzuelke commented 3 years ago

Hi @Danack and others,

PHP 8.0.0 is getting really close and it looks like this extension supports it already.

All that's missing is a Git tag, and a release to PECL :)

Would be super if that could be done anytime soon so that e.g. PaaSes have a stable release version to provide to customers.

Thanks!

bally86 commented 3 years ago

I found a TS version in the compile folder. Maybe it works for you.

https://drive.google.com/file/d/1yW3kZAOmScUWfDyRy3E3ifgEOBB-1X9y/view?usp=sharing

unclepips commented 3 years ago

That is fantastic, thank you so much - that has loaded now on my server :-)

Thanks again, Phil.

bally86 commented 3 years ago

Your welcome :)

LeMee commented 3 years ago

Thank you so much Pm

kyborek commented 3 years ago

@ToeiRei On a Windows dev machine it is way more than just a simple make. To be honest, I don't have any clue how to complile a PHP extension on Windows. So for my production environment, I could compile Imagick myself, but not for my dev environment. But I wouldn't be allowed to do that due to rules at my hosting that forbid the usage of non official releases of any dependency. (My solution was to remove the whole Imagick-dependency from that project, as I was lucky enough that it was used only for a simple thumbnailing service that works well with GD and a simple call to gs for PDFs. Took me just three hours to port that.)

For the held back release of Imagick it feels a bit like people depending on Imagick are held hostage to gain support for the project. I don't think thats the right way for such an important library, but I see the motivation and can accept that.

So to get back to a constructive discussion here: What exactly do you (the project maintainers) want the community to do? What has to happen to motivate you releasing a new version? Is this a financial thing? What amount of donations is needed to satisfy your needs? Do you want a sponsorship? So let's organize that. Or is this more about appreciation? What are the companies using Imagick in their projects supposed to do? Do you want someone to fork the project as you are not in the mood anymore to maintain it?

Please let us know so that we all can move forward.

Well, what you can do is to check out the https://github.com/sponsors/Danack page and keep sending any amount of money to get the motivation going and help the dev focus on rewarding work. If you work for a company you can ask the company to send monthly amount, if you are simply a dev with personal interest you can send any amount yourself. 20 people like your comment meaning they want to move this issue forward, all that is needed is for all those people to show their motivation by supporting the dev. So let's try to reach the goal and see if it helps Danack focus on the work as i can clearly see now that the opensource work is really under-appreciated even though heavily realied upon by external systems (Such as hosting companies requiring official PECL packages, Plesk systems or even WordPress sites)

aktolu commented 3 years ago

I found a TS version in the compile folder. Maybe it works for you.

https://drive.google.com/file/d/1yW3kZAOmScUWfDyRy3E3ifgEOBB-1X9y/view?usp=sharing

This is not work on me (Windows 10, Xampp, PHP 8.0.1) I think I need downgrade to 7.4

LucaDev commented 3 years ago

@Danack any news on this? To be honest this is getting... frustrating. If you have abandoned the project, please let us know and we will find another maintainer. I'm not asking you to get working on it right now. But the community would certainly appreciate at least hearing from you where the current problems are and what we can do about them. (Besides sponsoring/paying you...)

mkoppanen commented 3 years ago

@LucaDev,

I think this issue ties into larger issues with open source, where people put in free time and when the free time is not available it causes friction.

If you have a maintainer in mind who will take over I would be happy to have a chat and I’m sure @Danack would be as well.

bally86 commented 3 years ago

I found a TS version in the compile folder. Maybe it works for you. https://drive.google.com/file/d/1yW3kZAOmScUWfDyRy3E3ifgEOBB-1X9y/view?usp=sharing

This is not work on me (Windows 10, Xampp, PHP 8.0.1) I think I need downgrade to 7.4

I compiled it with php 8.0.2. Try that.

aktolu commented 3 years ago

I found a TS version in the compile folder. Maybe it works for you. https://drive.google.com/file/d/1yW3kZAOmScUWfDyRy3E3ifgEOBB-1X9y/view?usp=sharing

This is not work on me (Windows 10, Xampp, PHP 8.0.1) I think I need downgrade to 7.4

I compiled it with php 8.0.2. Try that.

Thanks for reply, but I did downgrade to 7.4.

DeyV commented 3 years ago

If You can't wait for official release for windows, this repo can help: https://github.com/mentax/Imagick_for_php8

adam1010 commented 3 years ago

We got an ETA here? If it's going to be a month, that's fine, just would be nice to know the timeframe so we can plan accordingly.

cgsmith commented 3 years ago

I donated and setup a GitHub sponsorship for you @Danack and encourage everyone else to donate where possible. https://github.com/sponsors/Danack

If you need help on this or anything else please ping me.

zackkrida commented 3 years ago

I don't even use the library anymore, but I'm throwing @Danack $1/month for the pain of dealing with many of the commenters here. I wish at the very least, the 40 👍 on the original issue would consider doing the same.

mmarton commented 3 years ago

No ETA, no commits, not even comments on this issue (by the devs) since months.... This lib is dead. And not because of the lack of donations, but the lack of motivation.

I do not enjoy supporting this library and I do not use this library. Which makes working on it be a thing that I wonder why I do.

It's sad, it was better than gd2, but I would rather refactor my code than to be stuck with old versions of php.

meglio commented 3 years ago

Out of my tests, imagic has best XML2PNG support compared to other open source libraries.

ampaze commented 3 years ago

No ETA, no commits, not even comments on this issue (by the devs) since months.... This lib is dead. And not because of the lack of donations, but the lack of motivation.

Exactly this. No motivation, which is just the way it goes sometimes.

It's sad, it was better than gd2, but I would rather refactor my code than to be stuck with old versions of php.

We did the same. (Using Imagine made this pretty straight forward.)

csandanov commented 3 years ago

I want to support @Danack. We're using imagick in our public docker image wodby/php, we're a tiny organization but now sponsoring Danack on github. I know maintaining open-source projects is tough and ofteh not rewarding at all, I hope we'll see imagick release in the future.

Cryental commented 3 years ago

I want to support @Danack. We're using imagick in our public docker image wodby/php, we're a tiny company but now sponsoring Danack on github. I know maintaining open-source projects is tough and ofteh not rewarding at all, I hope we'll see imagick release in the future.

Yeah same here, I will try to sponsor Danack soon :)

lzsiga commented 3 years ago

On my AIX5,6,7 systems, the current version of imagick from git clone compiles without problems.

SoftCreatR commented 3 years ago

That's correct, but not desired. Many people rely on official releases.

And I mean: Even if there will ever be an official release for PHP8, the same discussion will pop up again, as soon as PHP 8.1 has been released. Imho, this project is dead and it's about time to look for alternatives.

mklepaczewski commented 3 years ago

Hey @Danack, how much would it take to push it forward? It would be nice for the community to know some ballpark figure. I fully support your approach, if it's a chore to maintain the library and 37 participating developers here aren't capable of doing that, the maintainer should be compensated. I'm willing to chip in $50ish to move forward. I'm not interested in supporting the project on monthly basis, but I'm absolutely willing to sponsor features and issues I care about.

Honestly, it's mind-blowing that dozens of people are willing to discuss the issue for months, wasting (probably) thousands in the process, dozens of thousands if project delays are calculated in, instead of contributing few dozen dollars each.

mmarton commented 3 years ago

Honestly, it's mind-blowing that dozens of people are willing to discuss the issue for months, wasting (probably) thousands in the process, dozens of thousands if project delays are calculated in, instead of contributing few dozen dollars each.

Because making donating mandatory or else no new releases will happen is basicaly making it a paid component. Which I don't have any problem with. If it's commercial AND actively developed I will pay for it. I support a few dev-s, because they are responsive, cooperative and actually give a shit about my issues, and not because they told me so.

kdambekalns commented 3 years ago

Honestly, it's mind-blowing that dozens of people are willing to discuss the issue for months, wasting (probably) thousands in the process, dozens of thousands if project delays are calculated in, instead of contributing few dozen dollars each.

I know for a fact (from personal experience and a bunch of OSS projects) that money does not speed up issues if there is no other motivation involved, too. Money is an enabler, but not a motivator (for most people, at least).

That being said, I don't consider putting money into this one a reasonabe approach, as long as the mainainer states he's not motivated and wonders himelf, why he actually does maintain the project. 🤷‍♂️

For those saying one should switch to e.g. GD: That is not an option for everyone, as the resource consumption can differ substantially…

ampaze commented 3 years ago

Honestly, it's mind-blowing that dozens of people are willing to discuss the issue for months, wasting (probably) thousands in the process, dozens of thousands if project delays are calculated in, instead of contributing few dozen dollars each.

Without any timeline or what total amount would be sufficient, this is basically like throwing money in a wishing well. We have inquired about a one time payment and never heard back. I doubt this is about money.

mklepaczewski commented 3 years ago

Because making donating mandatory or else no new releases will happen is basicaly making it a paid component. Which I don't have any problem with. If it's commercial AND actively developed I will pay for it. I support a few dev-s, because they are responsive, cooperative and actually give a shit about my issues, and not because they told me so.

Good for you. Personally, I'm not going to invest my time and money hoping that maybe someone will sponsor me after years of lack of adequate sponsorship.

mklepaczewski commented 3 years ago

Without any timeline or what total amount would be sufficient, this is basically like throwing money in a wishing well. We have inquired about a one time payment and never heard back. I doubt this is about money.

In that case, I'm sorry, I must have missed that.

sstutz commented 3 years ago

Honestly, it's mind-blowing that dozens of people are willing to discuss the issue for months, wasting (probably) thousands in the process, dozens of thousands if project delays are calculated in, instead of contributing few dozen dollars each.

He has asked for help and when help was offered he declined: https://github.com/Imagick/imagick/issues/162#issuecomment-739593631 because documenting it is too boring

He has asked for monetary support (quite a lot actually) and according to GH he already has more than a couple dozen sponsors, so its not about the lack of contributions but the lack of motivation.

There are plenty of devs that make a good chunk of money from GH Sponsoring (and rightfully so) but he has made it very clear that he has no interest in maintaining the lib so why would people sponsor him knowing that the same thing is probably going to happen when the next PHP release is around the corner?

At this point it feels like he is only maintaining the lib in order to get paid, and despite the fact that you're right by saying everyone should be compensated for their work - A FOSS/PHP lib should not be used to pressure people into donations.

Personally I already removed the lib from all my work related projects and I think he should just step down as a maintainer if he has no intention in maintaining it. It'd save him from all the complaints on github/social media and the users would know that the lib is unmaintained, maybe that way someone else (from the php team for instance) will pick it up then.

fvdm commented 3 years ago

It looks like the package update is not going to happen within a timeframe the community would be happy with. If this is so important for them, why don't they create a fork and fix the problem themselves? This is FOSS after all and the license permits it. The resulting package could be PR'd back into the original or released under a new name or both. It could be a new package that keeps the codebase in sync with upstream. Maybe those willing to pay for it could hire someone to make that happen. 🤔

SoftCreatR commented 3 years ago

I would have done it already, if I could. But I don't know C at all.

glensc commented 3 years ago

@fvdm there's no need for a fork, the master builds according to multiple reports.

as for PR back, there are pull requests contributed back, but they are not accepted (merged).

currently, there's not even a list of what the original developer thought is missing to make the release.

kdambekalns commented 3 years ago

currently, there's not even a list of what the original developer thought is missing to make the release

Well, there is at least this comment https://github.com/Imagick/imagick/issues/358#issuecomment-733755585 and #362 was created afterwards. But, yeah…

glensc commented 3 years ago

@kdambekalns: #362 is titled test 14 suddenly failing, which is not much visible...

if somebody wants to bring order here, they should create a separate issue outlining problems or changes needed for the release. maybe a list of patches from pull requests and/or instructions to build.

for example in the issue body is a summary, and other interested parties can add more comments for issue owner to collect to issue body.

ps: Don't look at me, I won't be me. I'm just throwing out words.

waja commented 3 years ago

He @glensc,

nice to read your.

ps: Don't look at me, I won't be me. I'm just throwing out words.

How about you? (just joking :)

Cheers, Jan.

kdambekalns commented 3 years ago

if somebody wants to bring order here, they should create a separate issue

IMHO the best solution would be to create a project or milestone, but that needs to be done by someone with the needed permissions. Could be @Danack, for example… Then add issues to that, creating new ones as needed.

calvera commented 3 years ago

is he/she alive? i do not see any reaction

po 26. 4. 2021 v 14:10 odesílatel Karsten Dambekalns < @.***> napsal:

if somebody wants to bring order here, they should create a separate issue

IMHO the best solution would be to create a project or milestone, but that needs to be done by someone with the needed permissions. Could be @Danack https://github.com/Danack, for example… Then add issues to that, creating new ones as needed.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/Imagick/imagick/issues/358#issuecomment-826784657, or unsubscribe https://github.com/notifications/unsubscribe-auth/AADJPWQSIU62MUZBXIYHFEDTKVJ43ANCNFSM4TRIXKLQ .

dzuelke commented 3 years ago

Just as a reminder, the primary blocker for a release, if I understood @Danack correctly, is necessary cleanup of all method signatures so they are consistent and future-proof, given how PHP 8 supports named arguments.

That's a bit more than just cutting a stable release, but not an impossible task even for someone unfamiliar with the codebase - I unfortunately haven't found the time yet to tackle it.

Would be nice if @Danack could take a moment and drop a list of any other outstanding todos so that maybe people could submit PRs.

DarwinOnLine commented 3 years ago

You can make work Imagick with a PHP8-FPM docker image with this :

ARG IMAGICK_LAST_COMMIT='448c1cd0d58ba2838b9b6dff71c9b7e70a401b90'

RUN mkdir -p /usr/src/php/ext/imagick && \
    curl -fsSL https://github.com/Imagick/imagick/archive/${IMAGICK_LAST_COMMIT}.tar.gz | tar xvz -C /usr/src/php/ext/imagick --strip 1 && \
    docker-php-ext-install imagick

Hope that helps

tmb-github commented 3 years ago

Using resources linked in this thread, I've gotten Imagick working with PHP 8.0.3 on my XAMPP localhost on Windows. Does anyone else need to accomplish this? If so, I could upload all of the necessary files and instructions to a dedicated repo on GitHub. Just let me know.

fabriciojs commented 3 years ago

My team maintains some Docker images, including PHP 8 with Imagick. They are Alpine images based on the PHP Official images, plus a bunch of helpful stuff you usually need, making them more development-friendly.

This is how we are installing it on Alpine: https://github.com/kool-dev/docker-php/blob/master/8.0/Dockerfile#L56-L67

Feel free to use kooldev/php images, there is a bunch of tags available.

Check out on Hub Docker - https://hub.docker.com/r/kooldev/php

Disclosure/publicity - these images are part of the open-source effort we are putting in the kool-dev/kool dev tool. Any feedback is appreciated.

Cryental commented 3 years ago
Based on Plesk Obsidian:

cd /tmp
git clone https://github.com/Imagick/imagick
cd imagick
nano php_imagick.h -> replace @PACKAGE_VERSION@ to 3.4.5
/opt/plesk/php/8.0/bin/phpize 
./configure --with-php-config=/opt/plesk/php/8.0/bin/php-config
make 
make install
echo "extension=imagick.so" > /opt/plesk/php/8.0/etc/php.d/imagick.ini
plesk bin php_handler --reread
plesk repair web

These commands can be used for any environments with small tweaks.

Screenshot_3

Cryental commented 3 years ago

Using resources linked in this thread, I've gotten Imagick working with PHP 8.0.3 on my XAMPP localhost on Windows. Does anyone else need to accomplish this? If so, I could upload all of the necessary files and instructions to a dedicated repo on GitHub. Just let me know.

I'd like to see your stuffs :)

sonyarianto commented 3 years ago

You can make work Imagick with a PHP8-FPM docker image with this :

ARG IMAGICK_LAST_COMMIT='448c1cd0d58ba2838b9b6dff71c9b7e70a401b90'

RUN mkdir -p /usr/src/php/ext/imagick && \
    curl -fsSL https://github.com/Imagick/imagick/archive/${IMAGICK_LAST_COMMIT}.tar.gz | tar xvz -C /usr/src/php/ext/imagick --strip 1 && \
    docker-php-ext-install imagick

Hope that helps

I can confirm this is work for me on my Docker php:8-fpm, thank you very much. Will tested on real app such as WordPress etc.

bratvanov commented 3 years ago

@Cryental

These commands can be used for any environments with small tweaks.

Thanks! In addition to that, the Apache and PHP service configuration may need to be reloaded as well as the final steps.

On CentOS/CloudLinux:

service httpd reload
service plesk-php80-fpm reload

On Debian/Ubuntu:

service apache2 reload
service plesk-php80-fpm reload

I can confirm that it works on PHP 8.0.5 on the latest Plesk Obsidian.

andybajka commented 3 years ago

I have CENTOS 7.9 with WHM and cPanel v94.0.8. Currently I have Imagick PECL installed on PHP 7.4, should I uninstall Imagick PECL first before trying to install Imagick using SSH?

andybajka commented 3 years ago

According to the cPanel forum, there's a bug in PHP which prevents cPanel users from building manually from the master. Is this correct? Has anyone installed Imagick on CENTOS with WHM/cPanel on PHP 8.

https://forums.cpanel.net/threads/ups-307-imagick-php8-install-error.685057/

Cryental commented 3 years ago

@andybajka

According to the cPanel forum, there's a bug in PHP which prevents cPanel users from building manually from the master. Is this correct? Has anyone installed Imagick on CENTOS with WHM/cPanel on PHP 8.

https://forums.cpanel.net/threads/ups-307-imagick-php8-install-error.685057/

You can simply build a extension on other PC and copy extension file to cPanel.

Cryental commented 3 years ago

I have CENTOS 7.9 with WHM and cPanel v94.0.8. Currently I have Imagick PECL installed on PHP 7.4, should I uninstall Imagick PECL first before trying to install Imagick using SSH?

If you're installing imagick to other php version, no you don't need to reinstall it.

andybajka commented 3 years ago

You can simply build a extension on other PC and copy extension file to cPanel.

@Cryental

My WMH/cPanel is installed on a dedicated server.

andybajka commented 3 years ago

If you're installing imagick to other php version, no you don't need to reinstall it.

@Cryental

My WHM/cPanel has several versions of PHP installed. How can I specify which version of PHP to install Imagick on?