LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 07-07-2010, 01:25 PM   #1
richinsc
Member
 
Registered: Mar 2007
Location: Utah
Distribution: Gentoo Linux (3.0.6-gentoo)
Posts: 222

Rep: Reputation: 31
php5 ./configure error: (FILENAME=- FNR=27) fatal error: internal error


I am trying to compile php5 on a system, I have already completed a test compile for my environment on a virtual machine, currently trying to compile on the production machine and hitting a few snags. The compile gets past libtool and then fails with output below. At first I thought I didn't have gawk installed but I do, a search for FNR=27 yielded no result. Thanks!

Code:
Generating files
creating ./config.status
creating php5.spec
creating main/build-defs.h
creating scripts/phpize
creating scripts/man1/phpize.1
creating scripts/php-config
creating scripts/man1/php-config.1
creating sapi/cli/php.1
creating main/php_config.h
main/php_config.h is unchanged
creating main/internal_functions.c
gawk: ./build/order_by_dep.awk:63: (FILENAME=- FNR=27) fatal error: internal error
creating main/internal_functions_cli.c
gawk: ./build/order_by_dep.awk:63: (FILENAME=- FNR=27) fatal error: internal error
 
Old 07-07-2010, 02:13 PM   #2
richinsc
Member
 
Registered: Mar 2007
Location: Utah
Distribution: Gentoo Linux (3.0.6-gentoo)
Posts: 222

Original Poster
Rep: Reputation: 31
More information from what it seems the file in question is checking what modules are being compiled and then counts them, after finding out what they are it looks to check for dependencies so now it begs the question am I missing a dep or is something else wrong in environment. From what I can tell it's failing the count function but that as all I have determined thus far.

Code:
~/php-5.3.2 # more build/order_by_dep.awk
BEGIN {
        orig_rs = RS;
        orig_fs = FS;
        RS=" ";
        mod_count = 0;
        SUBSEP=":";
}

function get_deps(module_name,       depline, cmd)
{
        # this could probably be made *much* better
        RS=orig_rs;
        FS="[(,) \t]+"
        cmd = "grep PHP_ADD_EXTENSION_DEP ext/" module_name "/config*.m4"
        while (cmd | getline) {
#               printf("GOT: %s,%s,%s,%s,%s\n", $1, $2, $3, $4, $5);
                if (!length($5)) {
                        $5 = 0;
                }
                mod_deps[module_name, $4] = $5;
        }
        close(cmd)
        RS=" ";
        FS=orig_fs;
}

function get_module_index(name,  i)
{
        for (i in mods) {
                if (mods[i] == name) {
                        return i;
                }
        }
        return -1;
}

function do_deps(mod_idx,        module_name, mod_name_len, dep, ext, val, depidx)
{
        module_name = mods[mod_idx];
        mod_name_len = length(module_name);

        for (ext in mod_deps) {
                if (substr(ext, 0, mod_name_len+1) != module_name SUBSEP) {
                        continue;
                }
                val = mod_deps[ext];
                ext = substr(ext, mod_name_len+2, length(ext)-mod_name_len);

                depidx = get_module_index(ext);
                if (depidx >= 0) {
                        do_deps(depidx);
                }
        }
        printf("        phpext_%s_ptr,@NEWLINE@", module_name);
        delete mods[mod_idx];
}

function count(arr,       n, i)
{
        n = 0;
        for (i in arr)
                n++;
        return n;
}

/^[a-zA-Z0-9_-]+/ {
        # mini hack for pedantic awk
        gsub("[^a-zA-Z0-9_-]", "", $1)
        # add each item to array
        mods[mod_count++] = $1

        # see if it has any module deps
        get_deps($1);
}
END {
        # order it correctly
        out_count = 0;

        while (count(mods)) {
                for (i = 0; i <= mod_count - 1; i++) {
                        if (i in mods) {
                                do_deps(i);
                        }
                }
        }
}
 
Old 07-08-2010, 09:20 AM   #3
richinsc
Member
 
Registered: Mar 2007
Location: Utah
Distribution: Gentoo Linux (3.0.6-gentoo)
Posts: 222

Original Poster
Rep: Reputation: 31
After chatting with the good folks on irc.freenode.net channel ##php I was able to determine that this error is caused by an improper gawk version. My system had version 3.0.5 installed on it, after upgrading to newer version of gawk all errors went away and I had a clean install.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
server-error-internal-error with CUPS "Configure Printer" fskmh Slackware 6 06-05-2013 01:51 PM
RHEL4 PHP5 CGI Internal Server Error with SugarCRM 5.5 geofflee Linux - Software 0 01-20-2010 12:37 AM
PHP5 Fatal Error Message geoffmat Programming 2 02-05-2007 09:47 AM
Fatal Error - Call to undefined function : pg_pconnect() in filename.php on line xx mwpeng Linux - Newbie 1 02-26-2005 08:57 AM
gcc: Internal compiler error: program cc1 got fatal signal 11 smj Linux - Software 2 02-20-2003 10:35 AM


All times are GMT -5. The time now is 06:11 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration