Skip to content

Error compiling on Fedora 30

  • I agree that I have searched opened and closed issues to prevent duplicates.

Hi, I tried following the instructions to compile Redox listed in the repo and met the following issues. I tried both the script and cloning the repo manually, following the help section after each failure.

Description

  • patch, aclocal and automake were required but not installed (based on the book my impression was that they should be installed by the script)
  • failure due to undefined reference to `setrlimit', some logs below
x86_64-unknown-redox-gcc -Wall -g -O2  -static -Wl,--fatal-warnings -o dash alias.o arith_yacc.o arith_yylex.o cd.o error.o eval.o exec.o expand.o histedit.o input.o jobs.o mail.o main.o memalloc.o miscbltin.o mystring.o options.o parser.o redir.o show.o trap.o output.o printf.o system.o test.o times.o var.o builtins.o init.o nodes.o signames.o syntax.o 
/mnt/ext4/Dev/redox/prefix/x86_64-unknown-redox/relibc-install/bin/../lib/gcc/x86_64-unknown-redox/8.2.0/../../../../x86_64-unknown-redox/bin/ld: miscbltin.o: in function `ulimitcmd':
/mnt/ext4/Dev/redox/cookbook/recipes/dash/build/src/miscbltin.c:499: undefined reference to `setrlimit'
collect2: error: ld returned 1 exit status
make[4]: *** [Makefile:428: dash] Error 1
make[4]: Leaving directory '/mnt/ext4/Dev/redox/cookbook/recipes/dash/build/src'
make[3]: *** [Makefile:350: all] Error 2
make[3]: Leaving directory '/mnt/ext4/Dev/redox/cookbook/recipes/dash/build/src'
make[2]: *** [Makefile:353: all-recursive] Error 1
make[2]: Leaving directory '/mnt/ext4/Dev/redox/cookbook/recipes/dash/build'
make[1]: *** [Makefile:294: all] Error 2
make[1]: Leaving directory '/mnt/ext4/Dev/redox/cookbook/recipes/dash/build'
./repo.sh failed.make: *** [mk/filesystem.mk:16: build/filesystem.bin] Error 1

I tried looking for something related from before and found this, not sure if it's relevant.

x86_64-unknown-redox-gcc -DHAVE_CONFIG_H -I. -I..  -include ../config.h -DBSD=1 -DSHELL -DIFS_BROKEN  -Wall -g -O2 -MT miscbltin.o -MD -MP -MF .deps/miscbltin.Tpo -c -o miscbltin.o miscbltin.c
...
miscbltin.c:499:7: warning: implicit declaration of function 'setrlimit'; did you mean 'getrlimit'? [-Wimplicit-function-declaration]
   if (setrlimit(l->cmd, &limit) < 0)
       ^~~~~~~~~
       getrlimit

Environment info

  • Operating system: Fedora 30
  • uname -a: Linux localhost.localdomain 5.2.13-200.fc30.x86_64 #1 SMP Fri Sep 6 14:30:40 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
  • rustc -V: rustc 1.38.0-nightly (ad7c55e1f 2019-08-07)
  • git rev-parse HEAD: 5b7e9e3279318c147716c10945e03589411f4c29

Let me know if there's something I should try or have overlooked. Thanks for your work on Redox.