Thread: libplpgsql error on Alpha: solved

libplpgsql error on Alpha: solved

From
Eugenio Pierno
Date:
Hi good people,

I give you my little contribute to this *great* database.

Let's go on wuth the good work...

============================================================================
                        POSTGRESQL BUG REPORT TEMPLATE
============================================================================


Your name        : Eugenio Pierno
Your email address    : pierno@unina.it


System Configuration
---------------------
  Architecture (example: Intel Pentium)      : Alpha EV560

  Operating System (example: Linux 2.0.26 ELF)     : Digital Unix 4.0d

  PostgreSQL version (example: PostgreSQL-6.5.3):   PostgreSQL-6.5.3

  Compiler used (example:  gcc 2.8.0)        :  alpha cc


Please enter a FULL description of your problem:
------------------------------------------------
libplpgsql failing to compile with the following error message:

cc: Error: pl_comp.c, line 73: The type of the tentatively-defined variable
"plpgsql_yytext" is incomplete at the end of the compilation unit.
char     plpgsql_yytext[];
_________^
gmake: *** [pl_comp.o] Error 1

The backend compiles successfully
NOTE: I installed GNU flex 2.5.4 because supplied flex doesn't support the
-l flag

Please describe a way to repeat the problem.   Please try to provide a
concise reproducible example, if at all possible:
----------------------------------------------------------------------
configure --with-template=alpha_cc --with-CC=cc --without-CXX

gmake all


If you know how this problem might be fixed, list the solution below:
---------------------------------------------------------------------
FIX:
replace
    char plpgsql_yytext[];
with
    extern char plpgsql_yytext[];
in postgresql-6.5.3/src/pl/plpgsql/src/pl_comp.c line 73





                                      -- Eugenio


--
Eugenio Pierno
System & Network Support Group
Computer Centre
Second University of Naples
Voice: +39 081 5667014
Fax: +39 081 5667013