WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Problem compiling a httpd-only busybox  (Read 2377 times)

Offline PingPing

  • Jr. Member
  • **
  • Posts: 99
Problem compiling a httpd-only busybox
« on: June 08, 2009, 09:53:13 AM »
Running tcl 1.4.3.
Installed compiletc.tce.
Downloaded busybox-1.14.1 from www.busybox.net, unpacked and configured.
Run make and get the following error:
Code: [Select]
/usr/lib/gcc/i686-pc-linux-gnu/4.2.2/../../../../i686-pc-linux-gnu/bin/ld: cannot find -lcrypt
collect2: ld returned 1 exit status
make: *** [busybox_unstripped] Error 1
Can anyone help me with this please?

Offline danielibarnes

  • Hero Member
  • *****
  • Posts: 548
Re: Problem compiling a httpd-only busybox
« Reply #1 on: June 08, 2009, 01:44:11 PM »
This may not be much help, but I was able to build it just fine under TC 1.4.3. It created a 28k executable. My installed extensions are:
bash
compiletc

I executed 'make menuconfig', removed everything except httpd, and executed 'make'.

If you uncheck 'Enable Basic http Authentication' under httpd in 'make menuconfig' it will remove the dependency on libcrypt. This results in a 26k executable and will avoid your error altogether if you do not need that feature.

Daniel

Offline PingPing

  • Jr. Member
  • **
  • Posts: 99
Re: Problem compiling a httpd-only busybox
« Reply #2 on: June 08, 2009, 03:30:03 PM »
I think it was because I was trying to build it with static libraries.  When I built it with shared libraries, I had no problem.  Thanks for the tip about Basic http Authentication.

Offline danielibarnes

  • Hero Member
  • *****
  • Posts: 548
Re: Problem compiling a httpd-only busybox
« Reply #3 on: June 09, 2009, 11:41:36 AM »
Sorry, I should have realized you meant static from the error. As you probably discovered, you can remove the dependency, but it will still try to link statically.

Tiny Core has few static libraries in order to keep the size down. You might have figured this out by now, but if you comment out line 90 in the Makefile.flags file before you run make:

LDLIBS += m crypt

you can build a statically-linked executable of 504K.