Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Gprolog build fails with segfault in fd2c.pl
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
KJ4TIP
n00b
n00b


Joined: 28 Feb 2017
Posts: 10

PostPosted: Thu Mar 16, 2017 12:38 am    Post subject: Gprolog build fails with segfault in fd2c.pl Reply with quote

Hey,

I'm trying to install gprolog, and the build fails during compilation with a segmentation fault during compilation of fd2c.pl. Does anyone happen to know what is causing this/if there is any solution?

Here is the output of "emerge -pqv gprolog:"

Code:
[ebuild  N    ] dev-lang/gprolog-1.4.4  USE="-debug -doc -examples"


Here is the build log:

Code:

 * Package:    dev-lang/gprolog-1.4.4
 * Repository: gentoo
 * Maintainer: prolog@gentoo.org
 * USE:        abi_x86_32 elibc_glibc kernel_linux pie selinux ssp userland_GNU x86
 * FEATURES:   preserve-libs sandbox selinux sesandbox userpriv usersandbox
>>> Unpacking source...
>>> Unpacking gprolog-1.4.4.tar.gz to /var/tmp/portage/dev-lang/gprolog-1.4.4/work
>>> Source unpacked in /var/tmp/portage/dev-lang/gprolog-1.4.4/work
>>> Preparing source in /var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4 ...
 * Applying gprolog-1.4.4-ldflags.patch ...
 [ ok ]
 * Applying gprolog-1.4.4-links.patch ...
 [ ok ]
 * Applying gprolog-1.4.4-nodocs.patch ...
 [ ok ]
 * Applying gprolog-1.4.4-txt-file.patch ...
 [ ok ]
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4 ...
 * econf: updating gprolog-1.4.4/src/config.guess with /usr/share/gnuconfig/config.guess
 * econf: updating gprolog-1.4.4/src/config.sub with /usr/share/gnuconfig/config.sub
./configure --prefix=/usr --build=i686-pc-linux-gnu --host=i686-pc-linux-gnu --mandir=/usr/share/man --infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc --localstatedir=/var/lib --libdir=/usr/lib CFLAGS_MACHINE=-march=i686   --with-c-flags=-O2 -march=i686 -pipe -fno-strict-aliasing --with-install-dir=/usr/lib/gprolog-1.4.4 --with-links-dir=/usr/bin --without-doc-dir --without-html-dir --without-examples-dir
checking for i686-pc-linux-gnu-gcc... i686-pc-linux-gnu-gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether i686-pc-linux-gnu-gcc accepts -g... yes
checking for i686-pc-linux-gnu-gcc option to accept ISO C89... none needed
checking build system type... i686-pc-linux-gnu
checking host system type... i686-pc-linux-gnu
checking for i686-pc-linux-gnu-as... i686-pc-linux-gnu-as
checking for i686-pc-linux-gnu-ranlib... i686-pc-linux-gnu-ranlib
checking for i686-pc-linux-gnu-windres... no
checking for windres... no
checking for i686-pc-linux-gnu-ar... i686-pc-linux-gnu-ar
checking for i686-pc-linux-gnu-strip... i686-pc-linux-gnu-strip
checking whether make sets $(MAKE)... yes
checking for a BSD-compatible install... /usr/lib/portage/python3.4/ebuild-helpers/xattr/install -c
checking whether ln -s works... yes
checking how to run the C preprocessor... i686-pc-linux-gnu-gcc -E
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking whether byte ordering is bigendian... no
checking for inline... inline
checking size of long... 4
checking size of void*... 4
checking sys/ioctl_compat.h usability... no
checking sys/ioctl_compat.h presence... no
checking for sys/ioctl_compat.h... no
checking sys/siginfo.h usability... no
checking sys/siginfo.h presence... no
checking for sys/siginfo.h... no
checking termios.h usability... yes
checking termios.h presence... yes
checking for termios.h... yes
checking malloc.h usability... yes
checking malloc.h presence... yes
checking for malloc.h... yes
checking endian.h usability... yes
checking endian.h presence... yes
checking for endian.h... yes
checking sys/endian.h usability... no
checking sys/endian.h presence... no
checking for sys/endian.h... no
checking byteswap.h usability... yes
checking byteswap.h presence... yes
checking for byteswap.h... yes
checking float.h usability... yes
checking float.h presence... yes
checking for float.h... yes
checking for stdlib.h... (cached) yes
checking for unistd.h... (cached) yes
checking for sys/param.h... yes
checking for getpagesize... yes
checking for working mmap... yes
checking for getpagesize... (cached) yes
checking for mprotect... yes
checking for sigaction... yes
checking for mallopt... yes
checking for fgetc... yes
checking whether htole32 is declared... yes
checking whether bswap_32 is declared... yes
checking for atanh... yes
checking for acosh... yes
checking for asinh... yes
checking for socklen_t... yes
checking if struct sigcontext needs asm/sigcontext.h... no
checking for sigsetjmp... yes
checking for a working sigaction... yes
checking constructors execution order... first to last
checking for socket... yes
checking for gethostbyname... yes
DIRECTORIES
--> Installation:       /usr/lib/gprolog-1.4.4
--> Link to binaries:   /usr/bin
--> Documentation:      none
--> HTML documentation: none
--> Examples:           none
configure: creating ./config.status
config.status: creating Makefile
config.status: creating TopComp/Makefile
config.status: creating Pl2Wam/Makefile
config.status: creating Wam2Ma/Makefile
config.status: creating Ma2Asm/Makefile
config.status: creating Fd2C/Makefile
config.status: creating Linedit/Makefile
config.status: creating W32GUICons/Makefile
config.status: creating EnginePl/Makefile
config.status: creating BipsPl/Makefile
config.status: creating EngineFD/Makefile
config.status: creating BipsFD/Makefile
config.status: creating Ma2Asm/FromC/Makefile
config.status: creating Win32/Makefile
config.status: creating Win32/gp-setup.iss
config.status: creating EnginePl/gp_config.h
>>> Source configured.
>>> Compiling source in /var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4 ...
make -j2 -j1
cd EnginePl; make config
make[1]: Entering directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/EnginePl'
i686-pc-linux-gnu-gcc -march=pentiumpro -m32 -fno-strict-aliasing -O2 -march=i686 -pipe -fno-strict-aliasing  -o pl_config pl_config.c
./pl_config

   -------------------------------
   --- GNU PROLOG INSTALLATION ---
   -------------------------------

GNU Prolog version: 1.4.4 (Mar 14 2017)
Operating system  : linux-gnu
Processor         : i686
Size of a WAM word: 32 bits
C compiler        : i686-pc-linux-gnu-gcc
C flags           : -O2 -march=i686 -pipe -fno-strict-aliasing
C flags machine   : -march=pentiumpro -m32 -fno-strict-aliasing
Assembler         : i686-pc-linux-gnu-as
Assembler flags   : --32
Loader flags      : -Wl,-O1 -Wl,--as-needed -nopie
Loader libraries  : -lm
Use line editor   : Yes
Use piped consult : Yes
Use sockets       : Yes
Use FD solver     : Yes
Use fast call     : Yes
Use machine regs. : Yes
Used register(s)  : ebx (TR) 

   ------------------------------

(cd ../TopComp; make gplc)
make[2]: Entering directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/TopComp'
i686-pc-linux-gnu-gcc -march=pentiumpro -m32 -fno-strict-aliasing -Wl,-O1 -Wl,--as-needed -nopie -O2 -march=i686 -pipe -fno-strict-aliasing -o gplc top_comp.c -lm
make[2]: Leaving directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/TopComp'
make[1]: Leaving directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/EnginePl'
. ./SETVARS;for i in EnginePl TopComp Wam2Ma Ma2Asm Linedit BipsPl Pl2Wam Fd2C EngineFD BipsFD;do (cd $i; make) || exit 1; done;\
(cd TopComp; make top-level) || exit 1;\
(cd Pl2Wam; make stage2)
make[1]: Entering directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/EnginePl'
i686-pc-linux-gnu-gcc -march=pentiumpro -m32 -fno-strict-aliasing -O2 -march=i686 -pipe -fno-strict-aliasing  -o cpp_headers cpp_headers.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing' machine.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing' machine1.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing' stacks_sigsegv.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing' mem_alloc.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing' misc.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing' hash_fct.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing' hash.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing' obj_chain.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing' engine.c
gplc -c -o engine1.o engine1.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing' wam_inst.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing' atom.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing' pred.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing' oper.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing' if_no_fd.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing' main.c
rm -f libengine_pl.a
i686-pc-linux-gnu-ar rc  libengine_pl.a machine.o machine1.o stacks_sigsegv.o mem_alloc.o misc.o hash_fct.o hash.o obj_chain.o engine.o engine1.o wam_inst.o atom.o pred.o oper.o if_no_fd.o main.o
i686-pc-linux-gnu-ranlib libengine_pl.a
make[1]: Leaving directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/EnginePl'
make[1]: Entering directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/TopComp'
i686-pc-linux-gnu-gcc -march=pentiumpro -m32 -fno-strict-aliasing -Wl,-O1 -Wl,--as-needed -nopie -O2 -march=i686 -pipe -fno-strict-aliasing -o hexgplc hexfilter.c
make[1]: Leaving directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/TopComp'
make[1]: Entering directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/Wam2Ma'
i686-pc-linux-gnu-gcc -march=pentiumpro -m32 -fno-strict-aliasing -O2 -march=i686 -pipe -fno-strict-aliasing -c wam2ma.c
i686-pc-linux-gnu-gcc -march=pentiumpro -m32 -fno-strict-aliasing -O2 -march=i686 -pipe -fno-strict-aliasing -c wam_parser.c
i686-pc-linux-gnu-gcc -march=pentiumpro -m32 -fno-strict-aliasing -Wl,-O1 -Wl,--as-needed -nopie -o wam2ma wam2ma.o wam_parser.o
make[1]: Leaving directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/Wam2Ma'
make[1]: Entering directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/Ma2Asm'
i686-pc-linux-gnu-gcc -march=pentiumpro -m32 -fno-strict-aliasing -O2 -march=i686 -pipe -fno-strict-aliasing -c ma2asm.c
i686-pc-linux-gnu-gcc -march=pentiumpro -m32 -fno-strict-aliasing -O2 -march=i686 -pipe -fno-strict-aliasing -c ma_parser.c
i686-pc-linux-gnu-gcc -march=pentiumpro -m32 -fno-strict-aliasing -O2 -march=i686 -pipe -fno-strict-aliasing -c ma2asm_inst.c
i686-pc-linux-gnu-gcc -march=pentiumpro -m32 -fno-strict-aliasing -Wl,-O1 -Wl,--as-needed -nopie -o ma2asm ma2asm.o ma2asm_inst.o ma_parser.o
make[1]: Leaving directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/Ma2Asm'
make[1]: Entering directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/Linedit'
i686-pc-linux-gnu-gcc -march=pentiumpro -m32 -fno-strict-aliasing -c -O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char linedit.c
i686-pc-linux-gnu-gcc -march=pentiumpro -m32 -fno-strict-aliasing -c -O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char terminal.c
i686-pc-linux-gnu-gcc -march=pentiumpro -m32 -fno-strict-aliasing -c -O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char ctrl_c.c
rm -f liblinedit.a
i686-pc-linux-gnu-ar rc  liblinedit.a linedit.o terminal.o ctrl_c.o
i686-pc-linux-gnu-ranlib liblinedit.a
make[1]: Leaving directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/Linedit'
make[1]: Entering directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/BipsPl'
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' error_supp.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' c_supp.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' foreign_supp.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' pred_supp.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' term_supp.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' stream_supp.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' scan_supp.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' parse_supp.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' write_supp.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' dynam_supp.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' callinf_supp.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' bc_supp.c
gplc -c foreign.wam
gplc -c pl_error.wam
gplc -c utils.wam
gplc -c unify.wam
gplc -c assert.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' assert_c.c
gplc -c read.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' read_c.c
gplc -c write.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' write_c.c
gplc -c print.wam
gplc -c const_io.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' const_io_c.c
gplc -c oper.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' oper_c.c
gplc -c pred.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' pred_c.c
gplc -c atom.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' atom_c.c
gplc -c control.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' control_c.c
gplc -c call.wam
gplc -c call_args.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' call_args_c.c
gplc -c catch.wam
gplc -c throw.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' throw_c.c
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' flag_supp.c
gplc -c flag.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' flag_c.c
gplc -c arith_inl.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' arith_inl_c.c
gplc -c type_inl.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' type_inl_c.c
gplc -c term_inl.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' term_inl_c.c
gplc -c g_var_inl.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' g_var_inl_c.c
gplc -c all_solut.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' all_solut_c.c
gplc -c sort.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' sort_c.c
gplc -c list.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' list_c.c
gplc -c stat.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' stat_c.c
gplc -c stream.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' stream_c.c
gplc -c file.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' file_c.c
gplc -c char_io.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' char_io_c.c
gplc -c dec10io.wam
gplc -c format.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' format_c.c
gplc -c os_interf.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' os_interf_c.c
gplc -c expand.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' expand_c.c
gplc -c consult.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' consult_c.c
gplc -c pretty.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' pretty_c.c
gplc -c random.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' random_c.c
gplc -c top_level.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' top_level_c.c
gplc -c debugger.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' debugger_c.c
gplc -c src_rdr.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' src_rdr_c.c
gplc -c all_pl_bips.wam
gplc -c sockets.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' sockets_c.c
gplc -c le_interf.wam
gplc -c -C '-O2 -march=i686 -pipe -fno-strict-aliasing -funsigned-char' le_interf_c.c
rm -f libbips_pl.a
i686-pc-linux-gnu-ar rc  libbips_pl.a error_supp.o c_supp.o foreign_supp.o pred_supp.o term_supp.o stream_supp.o scan_supp.o parse_supp.o write_supp.o dynam_supp.o callinf_supp.o bc_supp.o foreign.o pl_error.o utils.o unify.o assert.o assert_c.o read.o read_c.o write.o write_c.o print.o const_io.o const_io_c.o oper.o oper_c.o pred.o pred_c.o atom.o atom_c.o control.o control_c.o call.o call_args.o call_args_c.o catch.o throw.o throw_c.o flag_supp.o flag.o flag_c.o arith_inl.o arith_inl_c.o type_inl.o type_inl_c.o term_inl.o term_inl_c.o g_var_inl.o g_var_inl_c.o all_solut.o all_solut_c.o sort.o sort_c.o list.o list_c.o stat.o stat_c.o stream.o stream_c.o file.o file_c.o char_io.o char_io_c.o dec10io.o format.o format_c.o os_interf.o os_interf_c.o expand.o expand_c.o consult.o consult_c.o pretty.o pretty_c.o random.o random_c.o top_level.o top_level_c.o debugger.o debugger_c.o src_rdr.o src_rdr_c.o all_pl_bips.o sockets.o sockets_c.o le_interf.o le_interf_c.o
i686-pc-linux-gnu-ranlib libbips_pl.a
make[1]: Leaving directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/BipsPl'
make[1]: Entering directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/Pl2Wam'
gplc -c pl2wam.wam
gplc -c read_file.wam
gplc -c syn_sugar.wam
gplc -c internal.wam
gplc -c code_gen.wam
gplc -c reg_alloc.wam
gplc -c inst_codif.wam
gplc -c first_arg.wam
gplc -c indexing.wam
gplc -c wam_emit.wam
[ ! -f  pl2wam ] || cp pl2wam pl2wam0
gplc -o pl2wam --no-fd-lib-warn --no-top-level pl2wam.o read_file.o syn_sugar.o internal.o code_gen.o reg_alloc.o inst_codif.o first_arg.o indexing.o wam_emit.o
make[1]: Leaving directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/Pl2Wam'
make[1]: Entering directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/Fd2C'
gplc -c --fast-math fd2c.pl

Fatal Error: Segmentation Violation (bad address: 0x8107d9c)
compilation failed
make[1]: *** [Makefile:10: fd2c.o] Error 1
make[1]: Leaving directory '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src/Fd2C'
make: *** [Makefile:45: all] Error 1
 * ERROR: dev-lang/gprolog-1.4.4::gentoo failed (compile phase):
 *   emake failed
 *
 * If you need support, post the output of `emerge --info '=dev-lang/gprolog-1.4.4::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=dev-lang/gprolog-1.4.4::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/dev-lang/gprolog-1.4.4/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/dev-lang/gprolog-1.4.4/temp/environment'.
 * Working directory: '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4/src'
 * S: '/var/tmp/portage/dev-lang/gprolog-1.4.4/work/gprolog-1.4.4'


And here is "emerge --info:"

Code:

Portage 2.3.3 (python 3.4.5-final-0, hardened/linux/x86/selinux, gcc-4.9.4, glibc-2.23-r3, 4.4.8-hardened-r1 i686)
=================================================================
System uname: Linux-4.4.8-hardened-r1-i686-Intel-R-_Celeron-R-_CPU_2.40GHz-with-gentoo-2.3
KiB Mem:     1021788 total,    398888 free
KiB Swap:    4694008 total,   4667688 free
Timestamp of repository gentoo: Thu, 16 Mar 2017 00:00:01 +0000
sh bash 4.3_p48-r1
ld GNU ld (Gentoo 2.26.1 p1.0) 2.26.1
app-shells/bash:          4.3_p48-r1::gentoo
dev-lang/perl:            5.22.3_rc4::gentoo
dev-lang/python:          2.7.12::gentoo, 3.4.5::gentoo
dev-util/cmake:           3.7.2::gentoo
dev-util/pkgconfig:       0.28-r2::gentoo
sys-apps/baselayout:      2.3::gentoo
sys-apps/openrc:          0.23.2::gentoo
sys-apps/sandbox:         2.10-r3::gentoo
sys-devel/autoconf:       2.69::gentoo
sys-devel/automake:       1.14.1::gentoo, 1.15::gentoo
sys-devel/binutils:       2.26.1::gentoo
sys-devel/gcc:            4.9.4::gentoo
sys-devel/gcc-config:     1.7.3::gentoo
sys-devel/libtool:        2.4.6-r3::gentoo
sys-devel/make:           4.2.1::gentoo
sys-kernel/linux-headers: 4.4::gentoo (virtual/os-headers)
sys-libs/glibc:           2.23-r3::gentoo
Repositories:

gentoo
    location: /usr/portage
    sync-type: rsync
    sync-uri: rsync://rsync.gentoo.org/gentoo-portage
    priority: -1000

haskell
    location: /var/lib/layman/haskell
    masters: gentoo
    priority: 50

zetok-overlay
    location: /var/lib/layman/zetok-overlay
    masters: gentoo
    priority: 50

ACCEPT_KEYWORDS="x86"
ACCEPT_LICENSE="* -@EULA"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=i686 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt /var/bind"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -march=i686 -pipe"
DISTDIR="/usr/portage/distfiles"
FCFLAGS="-march=i686 -O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news parallel-fetch preserve-libs protect-owned sandbox selinux sesandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-march=i686 -O2 -pipe"
GENTOO_MIRRORS="ftp://ftp.gtlib.gatech.edu/pub/gentoo"
LANG="en_US.iso88591"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
USE="aac acl acpi alsa apache2 bash-completion berkdb bindist bzip2 cgi cli cracklib crypt curl cxx dri gdbm git gzip hardened iconv ipv6 modules ncurses nls nptl open_perms openmp pam pax_kernel pcre perl pic pie postgres python readline ruby seccomp selinux session sockets sqlite3 ssl ssp syslog tcpd threads udev unconfined unicode urandom vim-syntax wifi x86 xattr xml xtpax zlib" ABI_X86="32" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="libinput keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-6" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_4" RUBY_TARGETS="ruby21" USERLAND="GNU" VIDEO_CARDS="amdgpu fbdev intel nouveau radeon radeonsi vesa dummy v4l" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON

Back to top
View user's profile Send private message
limn
l33t
l33t


Joined: 13 May 2005
Posts: 997

PostPosted: Fri Mar 17, 2017 12:25 pm    Post subject: Reply with quote

Try disabling your FEATURES and see if it will compile.
Back to top
View user's profile Send private message
KJ4TIP
n00b
n00b


Joined: 28 Feb 2017
Posts: 10

PostPosted: Fri Mar 17, 2017 10:30 pm    Post subject: Reply with quote

limn wrote:
Try disabling your FEATURES and see if it will compile.


I haven't added anything custom to FEATURES; everything there is already part of the hardened/selinux profile. Is there any specific feature I should try disabling?
Back to top
View user's profile Send private message
limn
l33t
l33t


Joined: 13 May 2005
Posts: 997

PostPosted: Sat Mar 18, 2017 10:54 am    Post subject: Reply with quote

All of them. Then
Code:
# cd /usr/portage/dev-lang/gprolog/
# ebuild gprolog-1.4.4.ebuild comile

If that compiles, you could try removing them one by one, and testing again, cleaning up between compiles, depending on your curiosity.
Or you could emerge gprolog, put them back and see how it goes.
Gprolog compiles on my non-hardened.
Back to top
View user's profile Send private message
KJ4TIP
n00b
n00b


Joined: 28 Feb 2017
Posts: 10

PostPosted: Sat Mar 18, 2017 3:33 pm    Post subject: Reply with quote

I disabled all of the features listed in the build log (preserve-libs sandbox selinux sesandbox userpriv usersandbox) and compilation still fails at the same place.
Back to top
View user's profile Send private message
limn
l33t
l33t


Joined: 13 May 2005
Posts: 997

PostPosted: Sat Mar 18, 2017 4:03 pm    Post subject: Reply with quote

I keep forgetting all the things portage adds by default.
If this is the only thing that does not compile, it may be gprolog will not compile on hardened.
You could try compiling it outside of portage. Untar/zip the source in /tmp and follow the directions in the INSTALL or README file.
Back to top
View user's profile Send private message
KJ4TIP
n00b
n00b


Joined: 28 Feb 2017
Posts: 10

PostPosted: Mon Mar 20, 2017 11:06 pm    Post subject: Reply with quote

Does anyone know if this is related to hardened forcing position-independent executables?
Back to top
View user's profile Send private message
limn
l33t
l33t


Joined: 13 May 2005
Posts: 997

PostPosted: Tue Mar 21, 2017 5:24 pm    Post subject: Reply with quote

ebuild says no
Code:
        if gcc-specs-pie ; then
                # gplc generates its own native ASM; disable PIE
                append-ldflags -nopie
        fi

gcc compiled with the "hardened" USE flag is causing the error.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum