Archived Forum Post

Index of archived forum posts


Chilkat PHP 7 Fatal error

Mar 24 '17 at 17:05


if i run test.php from chilkat-9.5.0-php-5.6-x86_64-linux that throws an fatal Error:

Fatal error: Uncaught Error: Call to undefined function dl() in /apache2/htdocs/chilkat_9_5_0.php:22 Stack trace: #0 /apache2/htdocs/test.php(3): include() #1 {main} thrown in /apache2/htdocs/chilkat_9_5_0.php on line 22

Does anyone have an idea or solution to fix it ?

Accepted Answer

I think I have everything setup now to install Chilkat for PHP 5.5, 5.6, 7.0, or 7.1 on Ubuntu/Debian using apt-get install.

First you need to trust Chilkat's GPG key and add the Chilkat repository. I couldn't put it on because that domain is hosted on Amazon S3, and URLs can only use lowercase. (Ughh!) Given that wasn't doing anything (yet), I decided to host the repository there.

wget -O - | sudo apt-key add -

sudo add-apt-repository "deb chilkat main" sudo apt-get update

If you find you don't have add-apt-repository, then you can install it like this:
sudo apt-get install software-properties-common python-software-properties
After the chilkat repository has been added and you've done the "apt-get update", you can install the Chilkat PHP extension for PHP 5.5, 5.6, 7.0, or 7.1 like this:
# to install for PHP 7.1
sudo apt-get install php7.1-chilkat

# to install for PHP 7.0 sudo apt-get install php7.0-chilkat

# to install for PHP 5.6 sudo apt-get install php5.6-chilkat

# to install for PHP 5.5 sudo apt-get install php5.5-chilkat

I'll make the other versions (PHP 5.2, 5.3, 5.4) available in the same way, and potentially builds for other architectures. Let me know if there are any issues. One known issue (for PHP 5.5/5.6) is whether the PHP extension directory is under /usr/lib/php or /usr/lib/php5. My newest system uses /usr/lib/php. In any case, I'm going to try to fix it so that it works with either..

If you cannot get add-apt-repository to work, then you can instead manually edit the /etc/apt/sources.list file to add the following line:

deb chilkat main
(Then do "sudo apt-get update")


Unfortunately, PHP 7 not supported now. We are waiting for it too and hope will be released soon. Is here any official statement about the release from Chilkat? (We did not find it.)


Hopefully PHP 7 will be included in the Chilkat v9.5.0.66 release, which is due out very soon..


Thank you for your reply! Is there any pre-release available to test Chilkat on a small VPS with PHP 7?


any updates on php7?

will the new version still depend on swig? or do you have the native c++ version ready?


Working on it now...


Awesome! Would love to support rewriting/ wrapping the imap client to match latest PSR-2 class naming

Let me know if you need help there.

Can't wait for the imap client.

Is it swig based?


Chilkat has plans to get rid of SWIG, or to at least create alternative API's that are more natural for the programming language. This would include Java, Perl, Python, Ruby, and PHP. Python is already completed, and will become more public after the next version release. For example, see:

I'm still working on the PHP7. I have a clean build, but I'm working towards improving the install so that you can simple do an "sudo apt-get install ..." rather than the painful procedure of downloading, extracting and copying files.. :)


sounds great! sure thing.. having a single chilkat.dpkg make things easier :D

cheers max


oooh lovely. I look forward to that new installation method + PHP7 support! Thanks for your efforts.