-
Notifications
You must be signed in to change notification settings - Fork 16
compiler error #8
Description
Getting below error while compling code
Postgres and go verions also mentioned
root@ceadat-virtual-machine:~# sudo -u postgres psql
could not change directory to "/root": Permission denied
psql (9.6.15)
Type "help" for help.
postgres=# \q
root@ceadat-virtual-machine:~# go version
go version go1.11 linux/amd64
root@ceadat-virtual-machine:~/influxdb_fdw# make USE_PGXS=1 with_llvm=no
gcc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Wendif-labels -Wmissing-format-attribute -Wformat-security -fno-strict-aliasing -fwrapv -fexcess-precision=standard -g -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -fPIC -pie -fno-omit-frame-pointer -fPIC -shared -o influxdb_fdw.so option.o deparse.o influxdb_query.o influxdb_fdw.o query.a -L/usr/lib/x86_64-linux-gnu -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
/usr/bin/ld: query.a(go.o): relocation R_X86_64_TPOFF32 against `runtime.tlsg' can not be used when making a shared object; recompile with -fPIC
query.a: error adding symbols: Bad value
collect2: error: ld returned 1 exit status
/usr/lib/postgresql/11/lib/pgxs/src/makefiles/../../src/Makefile.shlib:309: recipe for target 'influxdb_fdw.so' failed
make: *** [influxdb_fdw.so] Error 1