|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #56609 crack-0.[3|4] will not build; config.h not found
Submitted: 2005-10-24 00:32 UTC Modified: 2008-07-17 06:27 UTC
From: ahaning at gmail dot com Assigned: skettler (profile)
Status: Closed Package: crack (PECL)
PHP Version: 5.0.5 OS: Linux 2.4
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Bug Type:
From: ahaning at gmail dot com
New email:
PHP Version: OS:


 [2005-10-24 00:32 UTC] ahaning at gmail dot com
When trying to install the pecl/pear crack interface versions 0.3 or 0.4, the build dies. crack-0.1 and crack-0.2 install just fine.


root@linux-box-c500:/usr/src# pecl -V
PEAR Version: 1.4.2
PHP Version: 5.0.5
Zend Engine Version: 2.0.5
Running on: Linux linux-box-c500 2.4.26 #6 Mon Jun 14 19:07:27 PDT 2004 i686

I am also using cracklib-2.8.5 and php-5.0.5. My PHP configure line as reported by phpinfo() is:  './configure' '--with-apxs2' '--with-crack'

Reproduce code:
~# pear upgrade crack


~# pecl upgrade crack

Expected result:
I expected for crack-0.4 (the latest version) to be downloaded, compiled, and installed.

Actual result:
The build dies with the following message:

In file included from /tmp/tmp3W52EF/crack-0.4/libcrack/src/cracklib.h:27,
                 from /tmp/tmp3W52EF/crack-0.4/crack.c:34:
/tmp/tmp3W52EF/crack-0.4/libcrack/src/config.h:1:26: ../../config.h: No such file or directory
make: *** [crack.lo] Error 1
ERROR: `make' failed


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2005-10-27 14:57 UTC] ahaning at gmail dot com
I have uploaded a new, working (for me) version of the .tgz file at:

 [2005-10-31 17:03 UTC]
Fixed in current CVS, but additional cross-platform tests needed before releasing new version.
 [2007-01-08 14:18 UTC] mhazen at uga dot edu
This patch still hasn't gone live (a year and two months later, the current release is still uncompilable)... is there a significant problem with it? I've downloaded the patched version provided by ahaning, but was wondering if it'd just been forgotten int he wings.

Thanks, and cheers-
Mark Hazen
 [2007-02-22 12:53 UTC] mst at skrzynka dot pl
The same problem happens on my Ubuntu server 6.10, kernel 2.6.17-11, apache 2.0.55, php 5.1.6, gcc 4.1.2
 [2007-02-22 23:49 UTC] ahaning at gmail dot com
O_o I had completely forgotten about this. The project for which I was using crack previously has since died since I've changed jobs at work. (That sounds terrible!)

I have forgotten what I did to get this working, but if my link still works and the files build, I'd suggest using/incorporating them into a real version made by someone who knows what they're doing. (i.e. not me)
 [2008-07-17 06:27 UTC] tony at daylessday dot org
Seems to be fixed long ago.
 [2008-09-05 07:20 UTC] cbaxter at tnsi dot com
Just wanted to say although this issue has been closed by tony2001 the crack-0.4 in cvs still doesnt work and that the update by ahaning @
seems still the latest working version with PECL

php 5.2.6
 [2008-12-02 23:56 UTC] ben at sixg dot com
Hopefully enough attention can get this reopened.  As mentioned by cbaxter at tnsi dot com, this is still broken in cvs.  Tony2001's closure of this bug seems unwarranted.  Can someone please get 0.4.1 committed?
 [2008-12-03 00:25 UTC] ben at sixg dot com
Sorry to clutter things with two comments, but for anyone wondering how to work around this (since the pecl crack package has been broken for at least 3 years now), the following works:

pear install

In case that file eventually vanishes, here's the only thing ahaning at gmail dot com changed to fix the build:

diff -Naur crack-0.4/crack-0.4/libcrack/src/config.h crack-0.4.1/crack-0.4/libcrack/src/config.h
--- crack-0.4/crack-0.4/libcrack/src/config.h	2005-09-21 04:00:06.000000000 -0500
+++ crack-0.4.1/crack-0.4/libcrack/src/config.h	2005-10-26 08:06:49.000000000 -0500
@@ -1,4 +1,4 @@
-#include "../../config.h"
+#include "../config.h"
 #if ZTS
 # define THREADSAFE 1
 [2009-03-22 14:35 UTC] svartalf at hotmail dot com
HowTo create "crack" the PHP interface for craclib from source code and getting it to work in PHP5 cli/Apache2!
For this you have to have GCC and MAKE installed!

apt-get install php-pear php5 libapache2-mod-php5 php5-dev php5-ldap php5-cli
apt-get install cracklib2-dev cracklib-runtime

Run "a2enmod php5" if you haven't done this before, enables the PHP5 module in Apache

download "crack-0.4" or later from this is the PHP interface for cracklib
Unzip the crack-0.4 file, 
Open the "libcrack/src/config.h" in an editor and change  #include "../../config.h" to "#include "../config.h" 
Copy the package*.xml to the "crack-0.4" directory
In the crack-0.4 directory execure "pecl install package.xml"
run "find / -name" if you can't find it run "pecl build package.xml" then "pecl install package.xml"
copy the to "/usr/lib/php5/ext" (may need to create this directory)
add "" to /etc/php5/apache2/php.ini and /etc/php5/cli/php.ini under the "Dynamic Extensions"
May need to run "ldconfig", can't heart =)
/etc/init.d/apache2 restart

It should work!
 [2014-08-11 02:31 UTC] rfrawley at scribenet dot com
PHP Copyright © 2001-2022 The PHP Group
All rights reserved.
Last updated: Wed Dec 07 21:04:14 2022 UTC