How can I install php mailparse extension on Slackware 14.2?
SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
How can I install php mailparse extension on Slackware 14.2?
I'm trying to install mailparse as ity it's required by a web based app that isn't supported running under php 7 (actually, there is a beta I'm testing that is currently being tested under php 7 but I'm testing that under php 5.6).
Currently, php 5.6.19 is installed and I've tried the following:
Code:
pecl install mailparse # (fails - php 7 is required)
pecl install mailparse-2.1.6 # (fails - dep = mbstring)
pear install mailparse-2.1.6.tgz # (fails on make rfc822.c)
pear -f install pecl/mailparse-2.1.6 # (make fails - err 127)
mbstring is installed and active. I know that if I'm successful installing mailparse that I need to load it before mbstring in php.ini.
Here's exactly what I get when I try to do a simple install of it:
Code:
# pecl install mailparse
pecl/mailparse requires PHP (version >= 7.0.0), installed version is 5.6.19
pecl/mailparse requires PHP extension "mbstring"
No valid packages found
install failed
pecl doesn't seem to recognize that mbstring is installed and active but php -m and php --ri do.
Why is this?
Code:
# php --ri mbstring
mbstring
Multibyte Support => enabled
Multibyte string engine => libmbfl
HTTP input encoding translation => disabled libmbfl version => 1.3.2
mbstring extension makes use of "streamable kanji code filter and converter", which is distributed under the GNU Lesser General Public License version 2.1.
Multibyte (japanese) regex support => enabled
Multibyte regex (oniguruma) backtrack check => On
Multibyte regex (oniguruma) version => 5.9.5
Directive => Local Value => Master Value
mbstring.language => neutral => neutral
mbstring.detect_order => no value => no value
mbstring.http_input => no value => no value
mbstring.http_output => no value => no value
mbstring.internal_encoding => no value => no value
mbstring.substitute_character => no value => no value mbstring.func_overload => 0 => 0
mbstring.encoding_translation => Off => Off
mbstring.http_output_conv_mimetypes => ^(text/|application/xhtml\+xml) =[0] 0:su- 1:[tmux]* 2:t
Since php 7 seems to be required for the latest three versions of mailparse, i would have considered that perhaps I need to install an even earlier version to meet compatibility with the installed mbstring, but pecl doesn't even recognize that mbstring is installed at all.
mailparse is required for this app with respect to mail piping for their support/sales/billing department ticketing functions.
Anyway, what suggestions does anyone have for how I can install mailparse? The particular app I'm working with needs this for mail piping for sales and support and other departments in their software.
Last edited by tallship; 01-13-2017 at 03:18 PM.
Reason: tried to fix formatting, if this doesn't work will delete and start from scratch.
It might just be easier to upgrade your php to v7, assuming you don't have anything that relies on older versions. There's a thread on LQ discussing building php7 on Slackware.
It might just be easier to upgrade your php to v7, assuming you don't have anything that relies on older versions. /
Thank you for that, and yes, last week I read over that and another thread (where you and darth vader broke out the claws).
I have a couple of concerns before going that route though.
1.) If I do this, I don't want to break anything for when Patrick's changelog shows that he's updated -current to php 7.
2.) I would want to support anything that *may* not be stable under php7 by having both the stock, Slackware compiled version of php 5.6.x AND php 7 selectable - I have a few dozen VirtualHosts on the particular machine, and certainly don't want to head down a rabbit hole of breakages that might not even rear their ugly heads until some obscure usage of an app presents.
I do want to make sure that I can follow -current as usual, eventually discarding any custom installations of php I make in favor of what will eventually make it into the official Slackware -current changelog.
I don't know if there is anything that wouldn't be supported in php-7 that is in php-5, but if you end up wanting to use php-7 I have a SlackBuild for it here: https://github.com/Skaendo/slackbuilds. This SlackBuild is adapted from Pat's "official" SlackBuild for php-5 and you should know that you will need the alpine sources when you compile.
I use php-7 and no one has complained to me yet. (my small audience is mostly family and close friends)
Thanks I may just try that and bite the bullet. I'll have to address the issue with mailparse, but maybe if I use your Slackbuild I won't have the failure resulting from trying to install an older version w/pecl...
And, w/packages I can just revert easily and then whenever Slackware adopts php 7 I can switch to that.
I really didn't want to go about installing mailparse by hand and then have to deal with kruft laying around later in a year or two.
Any additional pointers in addition to the source for pine?
Any additional pointers in addition to the source for pine?
I just have the php files in /home/*user*/php and the alpine sources in /home/*user*/alpine, it seems to build fine like that. Also, I upgrade all three packages that are created; alpine, imapd and php. (imapd is created with alpine)
I've been building/running like that on my little home server with no issues.
You'll probably want to blacklist those three in slackpkg until the time that Slackware ships with php-7.
You can install mailparse-2.1.6 that apparently works with php-5.6
Code:
pecl install mailparse-2.1.6
Regards
Hi @bathory, I listed that above in the original post with the bizarre error I received, but realize it was buried in the details.
Here's the actual output of when I had originally tried that:
Code:
# pecl install mailparse-2.1.6
pecl/mailparse requires PHP extension "mbstring"
No valid packages found
install failed
One would think it would be as simple and straight-forward as that, and I even tried pear w/ a force flag to invoke the installation (also listed above in the original post) and installing from the locally downloaded mailparse-2.1.6.
I have no idea why it thinks that mbstring isn't installed. PHP knows it is, but pecl doesn't, and when I tried to compile/install from the locally downloaded extension that failed at some point in make as well.
Allthough this would be the ideal way for me, I'm thinking on this for a bit, leaning towards using @skaendo's Slackbuild and then just blacklisting as he suggested.
One thought, however, were you able to do the simple install w/pecl on one of your systems?
One thought, however, were you able to do the simple install w/pecl on one of your systems?
Yes I've installed mailparse-2.1.6 with pecl before posting the previous answer. The only difference is that I'm running php-5.6.29 compiled from source using the "--enable-mbstring" option, if that matters.
FYI, I've also tested the phpize method (compile mailparse-2.1.6 from source) and it also worked.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.