I have installed postgres-16-beta and I was assigned to a project to make possible to use AGE with PostgreSQL 16. I have configured postgres with:
./configure --prefix=$(pwd) --enable-cassert --enable-debug CFLAGS="-ggdb -Og -g3 -fno-omit-frame-pointer"
After that the make install
command is executed and it goes fine with it.
Then I type the following command to install AGE:
make PG_CONFIG=~/Documents/PostgreSQL/postgresql-16beta1/bin/pg_config install
But it throws this error:
/usr/bin/flex -b -o'src/backend/parser/ag_scanner.c' src/backend/parser/ag_scanner.l
flex: could not create src/backend/parser/ag_scanner.c
make: *** [/home/user_name/Documents/PostgreSQL/postgresql-16beta1/lib/pgxs/src/makefiles/../../src/Makefile.global:770: src/backend/parser/ag_scanner.c] Error 1
Downloaded age from this repo.
I’m using Fedora Linux 38.
3
Answers
Try executing the command as the root user, like this:
If this doesn’t work, you can build the ag_scanner.c manually using this command in the
src/backend/parser
directory:The command above should be run using superuser
sudo
. Most posts for installing AGE suggest that.after this command try make command and check for bin folder in main dir.
then inside bin check for pg_config file init. then try pwd command to display the path to bin folder
then move to age dir and then use