![]() |
|
FreeBSD General Other questions regarding FreeBSD which do not fit in any of the categories below. |
![]() |
|
Thread Tools | Display Modes |
|
|||
![]()
I want to create an Incident Response Disk for Unix, but am having trouble finding the source code for the base/core utilities so I can statically compile them. I think I've found the find, and lsof source on ftp://ftp.freebsd.org/pub/FreeBSD/distfiles/. But what about ps, netstat, dmesg, dd, ifconfig, arp, etc.
Any other commands that would be useful? |
|
|||
![]()
BSD != Linux, the "core utilities" are a part of the OS, with FreeBSD/OpenBSD & NetBSD the kernel and user lands are developed together..
Which is different from GNU/Linux (Linux kernel, GNU user land..)... ![]() What you've found in distfiles are 3rd party source archives. You can browse the FreeBSD source at: http://www.freebsd.org/cgi/cvsweb.cgi/src/ And download it: ftp://ftp.freebsd.org/pub/FreeBSD/re...0-RELEASE/src/ Last edited by BSDfan666; 4th July 2008 at 11:01 PM. |
|
|||
![]()
Okay, so to make sure I understand this correctly... I can run the install.sh script from the second link you provided and choose something like "base bin sbin and ubin" and it will extract the source code for the binaries in those directories which I can then statically compile?
|
|
||||
![]()
You will also find most things of interest in bin, sbin, usr.bin, usr.sbin, and contrib under 'app'
e.g. (/usr/src/) usr.bin/head/head.c -> source for /usr/bin/head.
__________________
My Journal Thou shalt check the array bounds of all strings (indeed, all arrays), for surely where thou typest ``foo'' someone someday shall type ``supercalifragilisticexpialidocious''. |
|
||||
![]() Quote:
If you look at pub/FreeBSD/releases/i386/7.0-RELEASE, you are basically browsing what is on the ISO images for 7.0-RELEASE. In the end you just get what you would get if you downloaded the relevant parts of the source tree, which you might already have -> you didn't say.
__________________
My Journal Thou shalt check the array bounds of all strings (indeed, all arrays), for surely where thou typest ``foo'' someone someday shall type ``supercalifragilisticexpialidocious''. |
|
||||
![]()
Install the OS, including the source distribution. Or, install the OS, and use csup to download the source tree. After that, the sources to everything will be in /usr/src/
Edit src.conf(5), and add WITHOUT_DYNAMICROOT. Then rebuild the world. You will now have a statically-compiled base OS (everything under /bin and /sbin). Alternatively, just copy /rescue/. That's a single crunchgen'd binary hardlinked to a bunch of different names. Which gives you a single 3.5 MB "rescue" disk. |
|
|||
![]()
I think I'll go the csup route, just for the learning experience. Thanks for everyones help!
|
![]() |
Thread Tools | |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
explore source code for installed program | bsdnewbie999 | OpenBSD General | 1 | 23rd February 2009 06:13 AM |
Trying to compile GLUT source code on freebsd. | welkin | Programming | 0 | 11th January 2009 03:15 PM |
Google released Android source code | graudeejs | Off-Topic | 1 | 22nd October 2008 10:02 PM |
Source code for ed? | matt | FreeBSD Ports and Packages | 1 | 21st October 2008 08:18 PM |
Tried to create new partition using sysinstall but change is not permanent | disappearedng | FreeBSD General | 7 | 6th July 2008 10:00 PM |