Compile on Centos7 and Postgres12

687 views
Skip to first unread message

L Q

unread,
Oct 30, 2019, 1:14:39 PM10/30/19
to Better Oracle functions support
Hi,
I need to install orafce (i downloaded latest 3.9) on my centos7 running Posgres12.

I have problem with make command (same problem with 3.8)

Makefile:25: ../../src/Makefile.global: File o directory non esistente
Makefile:26: /contrib/contrib-global.mk: File o directory non esistente
make: *** Nessuna regola per generare l'obiettivo «/contrib/contrib-global.mk».  Stop.


 

I tried to edit the file by writing the correct path to that file but it crashes later.

#include $(top_builddir)/src/Makefile.global     <- I not found in my system
include /usr/lib64/pgsql/pgxs/src/Makefile.global   <- only here in all my system
#include $(top_srcdir)/contrib/contrib-global.mk <- This does not exist

Can someone help me?

Pavel Stehule

unread,
Oct 30, 2019, 1:45:56 PM10/30/19
to orafce-...@googlegroups.com


st 30. 10. 2019 v 18:14 odesílatel L Q <barba...@gmail.com> napsal:
It's looks so you has not correctly installed PostgreSQL dev packages.

When you run pg_config

you should to get

BINDIR = /usr/local/pgsql/bin
DOCDIR = /usr/local/pgsql/share/doc
HTMLDIR = /usr/local/pgsql/share/doc
INCLUDEDIR = /usr/local/pgsql/include
PKGINCLUDEDIR = /usr/local/pgsql/include
INCLUDEDIR-SERVER = /usr/local/pgsql/include/server
LIBDIR = /usr/local/pgsql/lib
PKGLIBDIR = /usr/local/pgsql/lib
LOCALEDIR = /usr/local/pgsql/share/locale
MANDIR = /usr/local/pgsql/share/man
SHAREDIR = /usr/local/pgsql/share
SYSCONFDIR = /usr/local/pgsql/etc
PGXS = /usr/local/pgsql/lib/pgxs/src/makefiles/pgxs.mk
CONFIGURE = '--enable-tap-tests' '--enable-debug' 'CFLAGS=-ggdb -Og -g3 -fno-omit-frame-pointer' '--with-libxml' '--enable-cassert'
CC = gcc
CPPFLAGS = -D_GNU_SOURCE -I/usr/include/libxml2
CFLAGS = -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Werror=vla -Wendif-labels -Wmissing-format-attribute -Wformat-security -fno-strict-aliasing -fwrapv -fexcess-precision=standard -Wno-format-truncation -Wno-stringop-truncation -g -ggdb -Og -g3 -fno-omit-frame-pointer
CFLAGS_SL = -fPIC
LDFLAGS = -Wl,--as-needed -Wl,-rpath,'/usr/local/pgsql/lib',--enable-new-dtags
LDFLAGS_EX =
LDFLAGS_SL =
LIBS = -lpgcommon -lpgport -lpthread -lxml2 -lz -lreadline -lrt -ldl -lm
VERSION = PostgreSQL 13devel

and there is PGXS variable

On RH its package postgresql-server-devel

Regards

Pavel

--
You received this message because you are subscribed to the Google Groups "Better Oracle functions support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to orafce-genera...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/orafce-general/1d1bdfcc-0aca-4e4d-b75f-598a1fff4906%40googlegroups.com.

L Q

unread,
Nov 4, 2019, 4:39:32 AM11/4/19
to Better Oracle functions support
Hi,
on centos7 VM I have

BINDIR = /usr/bin
DOCDIR = /usr/share/doc/pgsql
HTMLDIR = /usr/share/doc/pgsql
INCLUDEDIR = /usr/include
PKGINCLUDEDIR = /usr/include/pgsql
INCLUDEDIR-SERVER = /usr/include/pgsql/server
LIBDIR = /usr/lib64
PKGLIBDIR = /usr/lib64/pgsql
LOCALEDIR = /usr/share/locale
MANDIR = /usr/share/man
SHAREDIR = /usr/share/pgsql
SYSCONFDIR = /etc
PGXS = /usr/lib64/pgsql/pgxs/src/makefiles/pgxs.mk
CONFIGURE = '--build=x86_64-redhat-linux-gnu' '--host=x86_64-redhat-linux-gnu' '--program-prefix=' '--disable-dependency-tracking' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' '--includedir=/usr/include' '--libdir=/usr/lib64' '--libexecdir=/usr/libexec' '--localstatedir=/var' '--sharedstatedir=/var/lib' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--disable-rpath' '--with-perl' '--with-tcl' '--with-tclconfig=/usr/lib64' '--with-python' '--with-ldap' '--with-openssl' '--with-pam' '--with-krb5' '--with-gssapi' '--with-ossp-uuid' '--with-libxml' '--with-libxslt' '--enable-nls' '--enable-dtrace' '--with-selinux' '--with-system-tzdata=/usr/share/zoneinfo' '--datadir=/usr/share/pgsql' 'build_alias=x86_64-redhat-linux-gnu' 'host_alias=x86_64-redhat-linux-gnu' 'CFLAGS=-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -DLINUX_OOM_SCORE_ADJ=0' 'LDFLAGS=-Wl,-z,relro '

CC = gcc
CPPFLAGS = -D_GNU_SOURCE -I/usr/include/libxml2
CFLAGS = -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -DLINUX_OOM_SCORE_ADJ=0 -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Wendif-labels -Wmissing-format-attribute -Wformat-security -fno-strict-aliasing -fwrapv -fexcess-precision=standard
CFLAGS_SL = -fPIC
LDFLAGS = -Wl,-z,relro -Wl,--as-needed
LDFLAGS_EX =
LDFLAGS_SL =
LIBS = -lpgport -lselinux -lxslt -lxml2 -lpam -lssl -lcrypto -lkrb5 -lcom_err -lgssapi_krb5 -lz -lreadline -lcrypt -ldl -lm
VERSION = PostgreSQL 9.2.24

The strange is that running is PSQL 12 and not 9

On the Ubuntu 18 VM I have

BINDIR = /usr/lib/postgresql/12/bin
DOCDIR = /usr/share/doc/postgresql-doc-12
HTMLDIR = /usr/share/doc/postgresql-doc-12
INCLUDEDIR = /usr/include/postgresql
PKGINCLUDEDIR = /usr/include/postgresql
INCLUDEDIR-SERVER = /usr/include/postgresql/12/server
LIBDIR = /usr/lib/x86_64-linux-gnu
PKGLIBDIR = /usr/lib/postgresql/12/lib
LOCALEDIR = /usr/share/locale
MANDIR = /usr/share/postgresql/12/man
SHAREDIR = /usr/share/postgresql/12
SYSCONFDIR = /etc/postgresql-common
PGXS = /usr/lib/postgresql/12/lib/pgxs/src/makefiles/pgxs.mk
CONFIGURE = '--build=x86_64-linux-gnu' '--prefix=/usr' '--includedir=/usr/include' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--sysconfdir=/etc' '--localstatedir=/var' '--disable-silent-rules' '--libdir=/usr/lib/x86_64-linux-gnu' '--libexecdir=/usr/lib/x86_64-linux-gnu' '--disable-maintainer-mode' '--disable-dependency-tracking' '--with-icu' '--with-tcl' '--with-perl' '--with-python' '--with-pam' '--with-openssl' '--with-libxml' '--with-libxslt' 'PYTHON=/usr/bin/python3' '--mandir=/usr/share/postgresql/12/man' '--docdir=/usr/share/doc/postgresql-doc-12' '--sysconfdir=/etc/postgresql-common' '--datarootdir=/usr/share/' '--datadir=/usr/share/postgresql/12' '--bindir=/usr/lib/postgresql/12/bin' '--libdir=/usr/lib/x86_64-linux-gnu/' '--libexecdir=/usr/lib/postgresql/' '--includedir=/usr/include/postgresql/' '--with-extra-version= (Ubuntu 12.0-2.pgdg18.04+1)' '--enable-nls' '--enable-integer-datetimes' '--enable-thread-safety' '--enable-tap-tests' '--enable-debug' '--enable-dtrace' '--disable-rpath' '--with-uuid=e2fs' '--with-gnu-ld' '--with-pgport=5432' '--with-system-tzdata=/usr/share/zoneinfo' '--with-llvm' 'LLVM_CONFIG=/usr/bin/llvm-config-6.0' 'CLANG=/usr/bin/clang-6.0' '--with-systemd' '--with-selinux' 'MKDIR_P=/bin/mkdir -p' 'TAR=/bin/tar' 'CFLAGS=-g -O2 -fstack-protector-strong -Wformat -Werror=format-security -fno-omit-frame-pointer' 'LDFLAGS=-Wl,-Bsymbolic-functions -Wl,-z,relro -Wl,-z,now' '--with-gssapi' '--with-ldap' '--with-includes=/usr/include/mit-krb5' '--with-libs=/usr/lib/mit-krb5' '--with-libs=/usr/lib/x86_64-linux-gnu/mit-krb5' 'build_alias=x86_64-linux-gnu' 'CPPFLAGS=-Wdate-time -D_FORTIFY_SOURCE=2' 'CXXFLAGS=-g -O2 -fstack-protector-strong -Wformat -Werror=format-security'
CC = gcc
CPPFLAGS = -Wdate-time -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -I/usr/include/libxml2 -I/usr/include/mit-krb5
CFLAGS = -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Werror=vla -Wendif-labels -Wmissing-format-attribute -Wformat-security -fno-strict-aliasing -fwrapv -fexcess-precision=standard -Wno-format-truncation -g -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -fno-omit-frame-pointer
CFLAGS_SL = -fPIC
LDFLAGS = -Wl,-Bsymbolic-functions -Wl,-z,relro -Wl,-z,now -L/usr/lib/llvm-6.0/lib -L/usr/lib/x86_64-linux-gnu/mit-krb5 -Wl,--as-needed
LDFLAGS_EX =
LDFLAGS_SL =
LIBS = -lpgcommon -lpgport -lpthread -lselinux -lxslt -lxml2 -lpam -lssl -lcrypto -lgssapi_krb5 -lz -ledit -lrt -lcrypt -ldl -lm
VERSION = PostgreSQL 12.0 (Ubuntu 12.0-2.pgdg18.04+1)


In both systems I was unable to install.
To unsubscribe from this group and stop receiving emails from it, send an email to orafce-...@googlegroups.com.

Pavel Stehule

unread,
Nov 4, 2019, 6:31:06 AM11/4/19
to orafce-...@googlegroups.com


po 4. 11. 2019 v 10:39 odesílatel L Q <barba...@gmail.com> napsal:
Hi,

Maybe you have devel package for postgres 9 and not for postgres 12. Unfortunatelly Postgres 9.2 is not version supported by Orafce. You need minimally PostgreSQL 9.4.

Pavel

To unsubscribe from this group and stop receiving emails from it, send an email to orafce-genera...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/orafce-general/50780db4-60cf-4f46-a518-8cf96810e359%40googlegroups.com.

Pavel Stehule

unread,
Nov 4, 2019, 6:50:07 AM11/4/19
to orafce-...@googlegroups.com


po 4. 11. 2019 v 12:30 odesílatel Pavel Stehule <pavel....@gmail.com> napsal:
I forgot - the extensions can work together only with same releases Postgres for what Postgres was compiled. So if your devel release is 9.2, then there is not any chance to work with pg 12.

The extension's loader do this check every time.

L Q

unread,
Nov 6, 2019, 3:52:58 AM11/6/19
to Better Oracle functions support
Hi,
ok, I suppose that this can be th eproblem on centos VM, but in Ubuntu VM devel i think is the same of psql version.
I will check again or reinstall vm from scratch.

L Q

unread,
Nov 8, 2019, 5:04:12 AM11/8/19
to Better Oracle functions support
HI,
I just installed a new VM with centos7

Now I m ready to install Postgres, what i MUST install after this?
sudo yum -y install epel-release yum-utils
sudo yum-config-manager --enable pgdg12
sudo yum install postgresql12-server postgresql12

WHat i need for compile orafce?
THnaks
To unsubscribe from this group and stop receiving emails from it, send an email to orafce-...@googlegroups.com.

Pavel Stehule

unread,
Nov 8, 2019, 5:47:55 AM11/8/19
to orafce-...@googlegroups.com


pá 8. 11. 2019 v 11:04 odesílatel L Q <barba...@gmail.com> napsal:
HI,
I just installed a new VM with centos7

Now I m ready to install Postgres, what i MUST install after this?
sudo yum -y install epel-release yum-utils
sudo yum-config-manager --enable pgdg12
sudo yum install postgresql12-server postgresql12

WHat i need for compile orafce?

I think postgresql12-devel or postgresql-server-devel - depends on repository

Pavel


To unsubscribe from this group and stop receiving emails from it, send an email to orafce-genera...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/orafce-general/9575626b-9837-44e2-93ea-05211ee2aefd%40googlegroups.com.

L Q

unread,
Nov 21, 2019, 6:07:33 AM11/21/19
to Better Oracle functions support
Hi.
I installed again new VM centos 7 64bit
I installed posgres12 
yum install postgresql12-server postgresql12 postgresql12-devel
I added 
/usr/pgsql-12/bin/ 
on root path
so now I have:
[root@postgre02 ~]# pg_config
BINDIR = /usr/pgsql-12/bin
DOCDIR = /usr/pgsql-12/doc
HTMLDIR = /usr/pgsql-12/doc/html
INCLUDEDIR = /usr/pgsql-12/include
PKGINCLUDEDIR = /usr/pgsql-12/include
INCLUDEDIR-SERVER = /usr/pgsql-12/include/server
LIBDIR = /usr/pgsql-12/lib
PKGLIBDIR = /usr/pgsql-12/lib
LOCALEDIR = /usr/pgsql-12/share/locale
MANDIR = /usr/pgsql-12/share/man
SHAREDIR = /usr/pgsql-12/share
SYSCONFDIR = /etc/sysconfig/pgsql
PGXS = /usr/pgsql-12/lib/pgxs/src/makefiles/pgxs.mk
CONFIGURE = '--enable-rpath' '--prefix=/usr/pgsql-12' '--includedir=/usr/pgsql-12/include' '--libdir=/usr/pgsql-12/lib' '--mandir=/usr/pgsql-12/share/man' '--datadir=/usr/pgsql-12/share' '--with-icu' 'CLANG=/opt/rh/llvm-toolset-7/root/usr/bin/clang' 'LLVM_CONFIG=/usr/lib64/llvm5.0/bin/llvm-config' '--with-llvm' '--with-perl' '--with-python' '--with-tcl' '--with-tclconfig=/usr/lib64' '--with-openssl' '--with-pam' '--with-gssapi' '--with-includes=/usr/include' '--with-libraries=/usr/lib64' '--enable-nls' '--enable-dtrace' '--with-uuid=e2fs' '--with-libxml' '--with-libxslt' '--with-ldap' '--with-selinux' '--with-systemd' '--with-system-tzdata=/usr/share/zoneinfo' '--sysconfdir=/etc/sysconfig/pgsql' '--docdir=/usr/pgsql-12/doc' '--htmldir=/usr/pgsql-12/doc/html' 'CFLAGS=-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic' 'LDFLAGS=-Wl,--as-needed' 'PKG_CONFIG_PATH=:/usr/lib64/pkgconfig:/usr/share/pkgconfig' 'PYTHON=/usr/bin/python2'
CC = gcc -std=gnu99
CPPFLAGS = -D_GNU_SOURCE -I/usr/include/libxml2 -I/usr/include
CFLAGS = -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Werror=vla -Wendif-labels -Wmissing-format-attribute -Wformat-security -fno-strict-aliasing -fwrapv -fexcess-precision=standard -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic
CFLAGS_SL = -fPIC
LDFLAGS = -Wl,--as-needed -L/usr/lib64/llvm5.0/lib -L/usr/lib64 -Wl,--as-needed -Wl,-rpath,'/usr/pgsql-12/lib',--enable-new-dtags
LDFLAGS_EX =
LDFLAGS_SL =
LIBS = -lpgcommon -lpgport -lpthread -lselinux -lxslt -lxml2 -lpam -lssl -lcrypto -lgssapi_krb5 -lz -lreadline -lrt -lcrypt -ldl -lm
VERSION = PostgreSQL 12.1

so now, following instruction i do
[root@postgre02 orafce-master]# export NO_PGXS=1
[root@postgre02 orafce-master]# make

Makefile:25: ../../src/Makefile.global: File o directory non esistente
Makefile:26: /contrib/contrib-global.mk: File o directory non esistente
make: *** Nessuna regola per generare l'obiettivo «/contrib/contrib-global.mk».  Stop.

same problem of previous attempt


Pavel Stehule

unread,
Nov 21, 2019, 8:49:50 AM11/21/19
to orafce-...@googlegroups.com


1. I install pgdg repository

sudo yum -y install https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm

yum install postgresql12 postgresql12-server postgresql12-devel


Directly you can install orafce "yum install orafce12"

su
su - postgres
psql targetdb
create extension orafce

or compilation

cd orafce
export PATH="$PATH:/usr/pgsql-12/bin" # unfortunately pg_config is not on default path

I had to install due build dependency openssl-devel,  bison, flex packages

then

with_llvm=no make -e
su -
with_llvm=no make install -e

that is all

čt 21. 11. 2019 v 12:07 odesílatel L Q <barba...@gmail.com> napsal:
To unsubscribe from this group and stop receiving emails from it, send an email to orafce-genera...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/orafce-general/f369a8e0-625b-402a-a384-8cbdaa21c026%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages