• Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Register
  • Login
UBports Robot Logo UBports Forum
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Register
  • Login

compiling with gcc in a chroot'ed system

Scheduled Pinned Locked Moved Support
2 Posts 1 Posters 724 Views 1 Watching
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • G Offline
      guru
      last edited by guru 1 Jun 2019, 17:22 6 Jan 2019, 14:34

      I have in my BQ E4.5 below ~phablet/myRoot a complete Linux un-tared to be able to compile and test things there. I did this already in the time of Canonical.

      The root fs was made of un-taring ubports-touch.rootfs-xenial-armhf.tar.gz

      Now I can not figure out to compile something there. The configure fails with:

      # ./configure CC=/usr/bin/arm-linux-gnueabihf-gcc 
      checking for a BSD-compatible install... /usr/bin/install -c
      checking whether build environment is sane... yes
      checking for a thread-safe mkdir -p... /bin/mkdir -p
      checking for gawk... no
      checking for mawk... mawk
      checking whether make sets $(MAKE)... no
      checking whether make supports nested variables... no
      checking whether to enable maintainer-specific portions of Makefiles... no
      checking build system type... armv7l-unknown-linux-gnueabihf
      checking host system type... armv7l-unknown-linux-gnueabihf
      checking whether make supports nested variables... (cached) no
      configure: autobuild project... libassuan
      configure: autobuild revision... 2.5.1
      configure: autobuild hostname... ubuntu-phablet
      configure: autobuild timestamp... 20190106-143049
      checking for style of include used by make... none
      checking for gcc... /usr/bin/arm-linux-gnueabihf-gcc
      checking whether the C compiler works... no
      configure: error: in `/src/libassuan-2.5.1':
      configure: error: C compiler cannot create executables
      See `config.log' for more details
      

      In config.log it is missing the file crt1.o nd maybe others:

      configure:3667: checking whether the C compiler works
      configure:3689: /usr/bin/arm-linux-gnueabihf-gcc    conftest.c  >&5
      /usr/bin/ld: cannot find crt1.o: No such file or directory
      /usr/bin/ld: cannot find crti.o: No such file or directory
      collect2: error: ld returned 1 exit status
      

      I tried as well with he normal compile CC=gcc
      What additional packages I have to install in this system and which gcc to use?

      Thanks

      G 1 Reply Last reply 6 Jan 2019, 17:57 Reply Quote 0
      • G Offline
        guru @guru
        last edited by 6 Jan 2019, 17:57

        To answer my own question:

        root@ubuntu-phablet:/# apt-get install gcc
        root@ubuntu-phablet:/# apt-get install libc-dev
        root@ubuntu-phablet:/# apt-get install make
        

        HIH

        1 Reply Last reply Reply Quote 3
        1 out of 2
        • First post
          1/2
          Last post