php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #74396 Many compilation errors
Submitted: 2017-04-09 11:47 UTC Modified: 2017-05-10 07:16 UTC
Votes:4
Avg. Score:3.8 ± 0.8
Reproduced:4 of 4 (100.0%)
Same Version:3 (75.0%)
Same OS:3 (75.0%)
From: anon dot amish at gmail dot com Assigned:
Status: Open Package: PAM (PECL)
PHP Version: 7.1.3 OS: Linux
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2017-04-09 11:47 UTC] anon dot amish at gmail dot com
Description:
------------
Trying to compile the code gives lots of compilation errors

Some errors:

/home/devel/AUR/php-pam/src/pam-1.0.3/pam.c: In function ‘zif_pam_auth’:
/home/devel/AUR/php-pam/src/pam-1.0.3/pam.c:251:36: error: macro "ZVAL_STRING" passed 3 arguments, but takes just 2
    ZVAL_STRING(status, error_msg, 0);
                                    ^
...
/home/devel/AUR/php-pam/src/pam-1.0.3/pam.c:256:6: error: too many arguments to function ‘zend_hash_find’
  if (zend_hash_find(&EG(symbol_table), "_SERVER", sizeof("_SERVER"), (void **)&server) == SUCCESS && Z_TYPE_PP(server) == IS_ARRAY) {




Expected result:
----------------
Source should compile successfully

Actual result:
--------------
Compilation fails

Patches

zend.patch (last revision 2017-04-09 11:47 UTC) by anon dot amish at gmail dot com)

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2017-04-10 13:06 UTC] anon dot amish at gmail dot com
Patch I uploaded seems to be working correctly.

However, running small command like this, causes coredump

php -r "pam_auth('someuser','somepassword');"

coredump does not seem to be related to my patch as it happens before code reaches any of my changes (in pam_start)


But same command works if I disable optimization with CFLAGS -O0 .

Do not know how disabling optimization solves the issue?

Hope project maintainer can figure it out as I could not.
 [2017-04-11 14:11 UTC] cmb@php.net
> Hope project maintainer can figure it out as I could not.

It seems the extension is unmaintained, though, see
<http://svn.php.net/viewvc/pecl/pam/trunk/>.
 [2017-04-11 14:32 UTC] anon dot amish at gmail dot com
Yes I noticed that the maintainer (@mikl) has 4 packages under him where in 3 of those he is sole maintainer. Last he was active in any of those 3 packages was in 2009 (so almost 8years)

https://pecl.php.net/user/mikl

pam is well known authentication method. So I was wondering why it is not being maintained.

Based on the statistics almost 10000 downloads happen per your for this package.
https://pecl.php.net/package-stats.php?pid=667&rid=&cid=1

What is the procedure if there is no maintainer?
 [2017-05-10 07:16 UTC] anon dot amish at gmail dot com
Somebody please apply the attached patch to:
http://svn.php.net/viewvc/pecl/pam/trunk/

Or let me know how to create pull request?

Thank you.
 
PHP Copyright © 2001-2017 The PHP Group
All rights reserved.
Last updated: Sun Nov 19 01:31:42 2017 UTC