Everything that includes the source code of Unix programs for example compiling, installing or how to retrieve the code for studying.

learn more… | top users | synonyms

266
votes
7answers
23k views

Understanding the Linux kernel source

I am trying to understand how a function, say mkdir, works by looking at the kernel source. This is an attempt to understand the kernel internals and navigate between various functions. I know mkdir ...
14
votes
5answers
5k views

determining path to sourced shell script

Is there a way for a sourced shell script to find out the path to itself? I'm mainly concerned with bash, though I have some coworkers who use tcsh. I'm guessing I may not have a ton of luck here, ...
13
votes
13answers
965 views

Distros that support compiling from source

A long time ago I used to use FreeBSD with its ports system and after that Gentoo for portage in order to install applications via compiling from source. I did this in order to directly target my ...
13
votes
5answers
790 views

How to compile and install programs from source

This is an issue that really limits my enjoyment of Linux. If the application isn't on a repository or if it doesn't have an installer script, then I really struggle where and how to install an ...
11
votes
3answers
1k views

Given a git patch id, how to find out which kernel release contains it?

Assume I have some issue that was fixed by a recent patch to the official Linux git repository. I have a work around, but I’d like to undo it when a release happens that contains my the fix. I know ...
10
votes
2answers
661 views

Where is best place to find sources of standard linux command line tools?

Into: I like learning by reading sources. But it's tiring of searching them across internet splited on many many different project sites. I'd love to see central browsable repo with sources of many ...
9
votes
2answers
568 views

What languages are used to build Unix commands?

Examples of commands I'm referring to are ls, pwd, and cd. Also, how are these built? Do you have an example?
9
votes
2answers
1k views

Why are there no -dev packages in Arch Linux?

I understand that source based distributions like Gentoo or Slackware do not need *-dev versions of programs. They include the source code as well as header files for compiling everything locally. ...
8
votes
7answers
23k views

How to install .tar.bz and .tar.bz2 packages?

I would like to know how to install .tar.bz and .tar.bz2 packages on Debian, please give me a complete explanation.
8
votes
1answer
3k views

What does a kernel source tree contain? Is this related to Linux kernel headers?

In books, I typically read references to the Linux Source Tree at /usr/src/linux with the usual set of subdirectories (arch, block, crypto, ...). I was expecting this tree to contain the binary files ...
6
votes
2answers
1k views

What are the advantages of building tools/libs from source?

By building from source do you gain any benefits? Is the code better optimized to your hardware architecture? Is it optimized better in general? Why would someone choose to build from source rather ...
6
votes
2answers
2k views

Where can I find the source code for `uptime`?

I am learning Python. Till now I've been doing only basic Python coding. A day ago, I checked python implementation of tree command. Suddenly I thought of creating a Python clone for uptime. I don't ...
6
votes
1answer
215 views

Source code of the screens of debian-installer

Where do I can find the source code of the screens of the installation process of Debian? I've tried: apt-get source debian-installer But in this package I do not see the source code. To be more ...
5
votes
4answers
98 views

Get list of required libraries when installing something from source

When installing something from source (say, Ruby 1.9.2), what command can I run to get a complete list of all the dependencies needed to install that application? Is this possible?
5
votes
2answers
814 views

How to grep on source code without catching comments

I search a way to grep on source code without having sometimes false-positive because of comments. For instance if I search on foo on this .c source code : /* * foo has changed [...] and is now a ...
5
votes
3answers
431 views

Installing Git, Curl, and Expat from Source

I have a RHEL 6.4 VM provisioned by my companies internal KVM. We are having some trouble using yum (Cannot retrieve repository metadata, which Ive confirmed in this case is peculiar to my company's ...
4
votes
3answers
984 views

Pointers in Learning Linux 0.01 Source code

I am trying to learn some real programming in C and the concepts of Linux. So i thought i will try by looking at the Linux kernel 0.01 version source. In my understanding, I could find the scratch ...
4
votes
4answers
77 views

When should one compile and install from source?

To install software on a Linux system, many tools like yum, apt-get, rpm, dpkg and so on are available to either fetch a package from a repository or install a downloaded package. Alternatively, it ...
4
votes
1answer
88 views

How to relate a kernel config setting to the source files?

Here is an example that will explain better: I have a selected the audio driver from the picture and i would like to browse through its source. How do i get to the path of the source files from ...
4
votes
3answers
3k views

Source code of netstat

Can I view the source code of netstat on my Linux machine?
4
votes
2answers
112 views

printing .cpp file from command line using emacs

The goal is to print a set of *.cpp files on a network printer, but... in a way that the (color) printer prints the files like they appear in the c++ editor including the colors and highlighting. And ...
4
votes
2answers
160 views

What is the 't' folder?

I'm mainly a Windows guy, programming C#, but I often do use technologies that were intended for Linux machines like git, MySQL, perl scripts, memcached, php, etc... And therefore I am exposed to ...
4
votes
1answer
98 views

Where should I keep the source files of the compiled applications?

I use Slackware Linux and I install most applications from the source. I would like to know how to manage the source files, specially the header files, so they are available to other applications.
3
votes
3answers
4k views

Where can I find the source code of libgio?

I want to study how its GFileInfo components works.
3
votes
3answers
102 views

Where can I find sources for

Emacs lisp source code for .elc files? e.g. cal-mayan.elc Files in the /bin directory? e.g. cat, split, and echo
3
votes
2answers
103 views

Exploding amount of Debian source code lines

According to the table at the Source lines of code article at Wikipedia, the amount of Debian source code lines rapidly grew to over 324m LoC (Lines of Code) in 2009: 2000: 55-59m 2002: 104m 2005: ...
3
votes
2answers
4k views

Passing a variable to a bash script when sourcing it in another bash script?

Suppose I have in main.sh: NAME="$HOME" if [ -f "$HOME/install.sh" ] then . "$HOME/install.sh" "$NAME" fi and in install.sh: echo $1 This is supposed to echo /home/user/, but it echoes ...
3
votes
1answer
125 views

Link a dependency in Synaptic to the one already installed from source

I want to install SVN version of Quantum GIS and already I have a SVN version of GRASS GIS. As instructed in QGIS Wiki here, I added the qgis repository to my sources.list file. Now I am able to see ...
3
votes
3answers
60 views

Source files with `*.in` extension

When poking around in some source code trees, sometimes I encounter files with extension "*.in", typically for non-compiled files that belong somewhere under /etc or /usr/share. For example, in ...
3
votes
2answers
65 views

Edit tree to output in custom format?

I'd like to get a custom output from the tree command, but unlike this question, I don't have a fixed format. I'd like to be able to give the command the format in an argument (for instance perhaps ...
3
votes
1answer
387 views

Confused about ident

I inherited a bunch of files that begin with the following statement at the top Ident:/some/path/to/a/file Ident seems to be related to C coding and make files but I am not really sure. None of the ...
3
votes
1answer
436 views

What does 'mergemaster' do that 'make distribution' doesn't?

After calling make installworld (or make world), there are two ways of updating source files in the new world: calling mergemaster -p or make distribution. I know that megermaster calls make ...
2
votes
4answers
7k views

How to start changing linux source code to make custom OS?

I am doing Under Graduation in CS Major, have medium level knowledge in C, C++, and Java and also learned some operating system concepts (as they are in my course syllabus). I have heard that we can ...
2
votes
1answer
2k views

Why does 'make' complain about a missing rule when I try to build a program from source?

I am a Linux novice, and I am attempting to compile scientific software called DL_POLY_Classic. I downloaded the zip file dl_class_1.6.tar.gz and unzipped it using the command tar xvzf ...
2
votes
1answer
74 views

How can I determine the date when a piece of software was installed from source?

I've been asked to find out when a specific version of software was installed. The only thing I have to go on are the modification times of the directories in question. I'm having a hard time ...
2
votes
1answer
80 views

Where in the linux kernel sources can I find a list of the different keyboard scancodes?

I was looking for a list of keyboard scancodes in the linux kernel sources, but I did not find anything. Does someone know where to find these? Especially the USB scancodes would be interesting.
2
votes
1answer
213 views

Can I use yum to manage a “package” installed from source

I am running CentOS 5.5. I need to upgrade some packages to newer versions, unfortunately they're not available. I am stuck building from source. Is there a simple way to use yum to manage ...
2
votes
1answer
1k views

How do I remove/uninstall a program that I have complied from source? [duplicate]

How do I remove a program that I have compiled from source using the ./configure; make; make install method? Does it matter whether I have kept the original directory that the source was stored in or ...
2
votes
1answer
393 views

Chat source code

Source code of chat program (used for dialog with modem) is open? If it is so, where I can find it? I'm try find it, but no success.
2
votes
4answers
67 views

Is it possible to trace Linux source from initial bootup to desktop-GUI userland code?

I am wondering if, since Linux is 100% open-source, it is possible to follow line-by-line instructions of Linux to observe how the OS works entirely, so that one may get a better knowledge of how OSes ...
2
votes
1answer
143 views

Build binary and dependencies without sudo

I want to install a piece of software (rtorrent) from source to my home folder. It depends on ncurses, which is not installed. I've installed ncurses to my home folder by using the PREFIX option ...
2
votes
2answers
710 views

Use a specific interface for a specific destination subnet (source IP setting)

I am looking for some sort of routing trickery to set a specific source IP: Local machine has two IPs; Eth1: 192.168.0.1 Eth1:2 192.168.0.2 Default gateway is 192.168.0.254 via Eth1 Remote subnet ...
2
votes
1answer
163 views

How should I install software from source so that I can make my configuration manageable and reproducible?

I work with a lot of scientific software on Linux distributions (normally Debian variants and Red Hat variants). In order to maximize performance and get access to the latest features, it's often ...
2
votes
2answers
264 views

OpenBSD patch system

If I install OpenBSD from CD-ROM: http://www.openbsd.org/ftp.html with install48.iso then is it patched? All 10 patches from here are in the ISO file? If those are not included, how can I apply ...
2
votes
2answers
59 views

Is there a distribution-independent tool to autocompile+install dependencies?

I like the way e.g. ArchLinux' yaourt (or if you're not that lazy, abs+makepkg; and from what I read so far, Gentoo's ebuild as well) automatically take care of obtaining, compiling and installing ...
2
votes
1answer
112 views

Modify and boot linux kernel on mobile device [closed]

During my education I have been developing Android iOS apps and websites for almost 18 months. Now, as my final year project, I am working on Linux source code with the goal to boot it on a mobile ...
2
votes
2answers
103 views

How to config my.cfg file for mysql which was installed from sources?

I installed MySQL 5.6 from sources on debian. MySQL folder is /usr/local/mysql. Here is several question: 1) I would like to config my.cfg. But I couldn't find several parameters: socket ...
2
votes
1answer
1k views

Linux source, where are sys_umount and sys_mount system calls? [duplicate]

Possible Duplicate: Understanding the linux kernel source I am sure that I must be missing something, here. I cannot for the life of me find the source code for these system calls. I can ...
2
votes
0answers
481 views

“Kernel panic - not syncing” after building Centos-6/elrepo 3.10.19 kernel from source

I need to rebuild the Centos-6 / elrepo 3.10.19 kernel from source. Background: the GVision touch screen drivers are incompatible with kernels > 3.8 and require source code patches to add code to ...
2
votes
1answer
1k views

Unpacking kernel-source rpm off-system (OpenSuse)?

I'm using OpenSuse 11.2 from a LiveUSB USB flash/stick, which arguably has not much place on it. I need to get the Linux sources for this version of OpenSuse, as they are needed to build a driver for ...