Compiling is the process of transforming source code into byte codes for a particular computer architecture.
59
votes
4answers
14k views
Why is FreeBSD deprecating GCC in favor of Clang/LLVM?
So I was surfing the net and stumbled upon this article. It basically states that FreeBSD, starting from Version 10 and above will deprecate GCC in favor of Clang/LLVM.
From what I have seen around ...
53
votes
12answers
4k views
What is the benefit of compiling your own linux kernel?
What benefit could I see by compiling a Linux kernel myself? Is there some efficiency you could create by customizing it to your hardware?
43
votes
16answers
3k views
Where should I put software I compile myself?
I need to compile some software on my Fedora machine. Where's the best place to put it so not to interfere with the packaged software?
23
votes
4answers
8k views
Why can't gcc find libevent when building tmux from source?
I want to install tmux on a machine where I don't have root access. I already compiled libevent and installed it in $HOME/.bin-libevent and now I want to compile tmux, but configure always ends with ...
19
votes
2answers
1k views
Is it possible to compile a full Linux system with Intel's compiler instead of GCC?
Perhaps this is a stupid idea? Maybe there are some compatibility issues?
I have the impression that for Intel-based systems, the Intel compiler would potentially do a better job than GCC. Perhaps ...
17
votes
6answers
3k views
Force directory to always be in cache
I've been testing out different methods to improve the time it takes to compile my entire c++ project. Currently it takes ~5 minutes. I experimented with distcc, ccache, and others. Recently, I ...
14
votes
5answers
907 views
Is automake and autoconf the standard way to compile code?
I sometimes compile apps from source and I've either been using:
./configure
make
sudo make install
But recently, I came across ./autogen.sh which generates the configure and make scripts for me ...
14
votes
5answers
352 views
Keeping track of programs
When I install a simple program it often uses make && make install and doesn't often even have an uninstall target. If I wish to upgrade a program is it standard protocol to assume it just ...
13
votes
5answers
594 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 ...
13
votes
2answers
891 views
What is Wayland?
I was looking for a lightweight X server, but failed to find one. Then I found out about Wayland. I says that it aims to coexist with X, but can run standalone.
When I try to compile it, it needs ...
12
votes
13answers
651 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 ...
12
votes
2answers
5k views
What is the Fedora equivalent of the Debian build-essential package?
What is the Fedora equivalent of the Debian build-essential package?
10
votes
6answers
752 views
Looking for tools to build minimal linux desktop
Increasingly I am dissatisfied by the fact, that configuring my linux desktop usually means removing bloat instead of adding and tweaking features. I have come to the conclusion that I would rather ...
9
votes
5answers
3k views
Compiling GNU/Linux with -O3 optimization
It's said that compiling GNU tools and Linux kernel with -O3 gcc optimization option will produce weird and funky bugs. Is it true? Has anyone tried it or is it just a hoax?
8
votes
4answers
294 views
What could be causing make to hang when compiling on multiple cores?
Yesterday I was trying to compile the ROOT package from source. Since I was compiling it on a 6 core monster machine, I decided to go ahead and build using multiple cores using make -j 6. The ...
8
votes
2answers
173 views
best way to set up separate linux environment in ~
I do most of my work (involves a lot of C/Python) on a development server that is shared with several other people. As a result we all seem to do a bit of the system administration chores (there is ...
7
votes
6answers
935 views
Compiling code from vim
New to vim and and I want to be able to compile code from within vim without running a new terminal and calling the compiler.
How do I go about doing this? Note that this requirement is not ...
7
votes
5answers
1k views
Benefit of kernel module compiled inside kernel?
What's the benefit of compiling kernel modules into the kernel (instead of as loadable modules)?
6
votes
2answers
834 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
950 views
Why does FreeBSD use the GPL-licensed GCC?
Why does FreeBSD use GCC as its default compiler?
I am under the impression that a core pillar of the FreeBSD philosophy is not to use any GNU software and in particular, GPL code.
Yet GCC which is ...
6
votes
1answer
255 views
Why would one want to compile multiple .cpp files to the same executable?
Why would you do
g++ -Wall -I/usr/local/include/thrift *.cpp -lthrift -o something
instead of:
g++ -Wall -I/usr/local/include/thrift -c Something.cpp -o something.o
g++ -Wall ...
6
votes
2answers
541 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.
...
6
votes
2answers
376 views
How to develop a small linux distro?
Since Linux uses open-source packages, I was wondering if I could develop my own Linux distro by compiling these packages.
I tried to read the Linux From Scratch book but it's quite big and uses lots ...
6
votes
1answer
650 views
What is the proper way to set SELinux context in an RPM .spec?
I am trying to build an RPM that targets RHEL4 and 5. Right now I call chcon from %post but multiple Google entries say "that's not how you are supposed to do it" with very limited help on the right ...
6
votes
1answer
321 views
Grubby fatal error in Linux kernel installation
I have compiled Linux kernel 2.6.24.6 from source (without problem) and tried to install it. Specifically, after unpacking the Linux source code, I did
make && make modules
to compile. ...
6
votes
3answers
244 views
How can I build and install PL/R as a non-privileged user?
There is a postgres instance, and I have the ability to build my own instance.
Using these instructions I ran:
USE_PGXS=1 make
which worked but then
USE_PGXS=1 make install
did not, with this ...
5
votes
3answers
378 views
How to speed up my build
I am doing a build on a Linux machine with ubuntu 10.04 on it. I want to know how can I really speed up my build. I have 4 CPUs and lots of RAM. I already reniced the process group to -20. Is there ...
5
votes
3answers
180 views
Effect of compiling from source on already installed applications
I use Ubuntu 12.04. Say I have installed package x from the repository (with all its dependencies) at version 1.7 but I need some functionality that is only available in version 1.8, so I download the ...
5
votes
4answers
614 views
Does optimizing for size reduce runtime memory usage as well as binary size?
Does optimizing for size with gcc -Os only reduce the binary size of a program, or does it reduce its runtime memory usage as well? I know what exactly the results are depend on the specific code, but ...
5
votes
2answers
87 views
Emacs on OpenBSD for DEC VAX?
I have managed to install OpenBSD 5.2 on my DEC VaxStation 4000 Model 90 but to my surprise have not found a binary for Emacs (any version) for the VAX architecture. As best as I can tell I do not see ...
5
votes
2answers
575 views
Do I need to cross-compile my program when my target is 64 bit arch. and host is 32 bit arch from x86 family?
I have scenario in which
my host is : x86 32 bit processor
my target is : x86 64 bit processor
I have a couple of questions :
I want to know if i can simply
compile a program in my host using
...
5
votes
1answer
681 views
Why is my initial ramdisk so big?
I'm running Ubuntu 11.10, which came with kernel version 3.0.0-14. I downloaded and built a kernel from the 3.1.0 branch. After installing the new kernel, I see that my /boot/initrd.img-3.1.0 file is ...
5
votes
2answers
228 views
What package could “linux-headers-3.7.5-1-ARCH” mean?
I'm debugging a closed-source software installer that seems to have some pre-conceived notions about my distribution. The installation aborts after not finding apt-get. The command it attempts to run ...
5
votes
2answers
271 views
How can I create a .deb package with my compiled OpenCV build?
OpenCV 2.4.2 took 6 hours to compile on the Raspberry Pi and I'd love to package everything up as a deb but I have never done that before. How can I package the compiled files so that they download or ...
5
votes
2answers
3k views
How to include local header files in linux kernel module
Say I have a module mymod with source files as follows:
src/mod/mymod.c
src/inc/mymod.h
I try to include mymod.h as follows
#include <mymod.h>
My makefile contains EXTRA_CFLAGS= ...
5
votes
1answer
372 views
How to recompile a Debian package with -Os?
There are a few larger programs I am interested in compiling with -Os. The normal method I use to patch/recompile programs is apt-get source followed by dpkg-buildpackage.
I learned from the ...
5
votes
1answer
213 views
Compiler flags for mplayer2 to optimize it for old hardware
I just compiled mplayer2 from source (git://git.mplayer2.org/mplayer2-build.git) because the repository (ubuntu 12.04) version didn't work on my system. Since I have old hardware I was just wondering ...
4
votes
3answers
540 views
Mystery of binary files
This is about files straight from the compiler, say g++, and the -o (outfile) flag.
If they are binary, shouldn't they just be a bunch of 0's and 1's?
When you cat them, you get unintelligible ...
4
votes
3answers
207 views
Edit and recompile individual program
whereis pwd
pwd: /bin/pwd /usr/include/pwd.h /usr/share/man/man1/pwd.1.gz
The pwd in the binary folder is not the same as
type pwd
pwd is a shell builtin
so wouldn't it be harmless to do some ...
4
votes
3answers
2k views
Why does my vim-7.3 compile fail to include clientserver?
I am trying to compile vim-7.3 will all features enabled. I ran configure with
$ ./configure --with-features=huge --enable-gui --enable-cscope
$ make ; make install
When I check the version, it ...
4
votes
2answers
446 views
How to compile a c program without leaving the editor?
I am using vim editor on Linux mint. I want to know if there is any way to compile c program without leaving the editor.
4
votes
4answers
229 views
Looking for small distro (to be installed automatically, with g++ and javac)
I'm looking for linux distro only with comand line and i need in it only g++,javac,python. I found Damn Small Linux but it dont have g++ and javac. It should have it out of the box because linux will ...
4
votes
2answers
74 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?
4
votes
2answers
1k views
On Gentoo, how do I rebuild all packages depended on some other package?
I made mistake and changed perl non-threaded version to threaded by unmerge first, change USE flags to include ithreads and emerge perl again. Now most packages depending on perl are broken. How do I ...
4
votes
2answers
4k views
How to create an initrd image on OpenSuSE linux?
/usr/src/linux-3.2.1 # make install
scripts/kconfig/conf --silentoldconfig Kconfig
sh /usr/src/linux-3.2.1/arch/x86/boot/install.sh 3.2.1-12-desktop arch/x86/boot/bzImage \
System.map ...
4
votes
3answers
868 views
Recompile Kernel to Change Stack Size
I need to recompile my kernel on RHEL WS5 with only two changes.
Change stack size from 4k to 8k
Limit usable memory to 4096.
How do I recompile the kernel without changing anything else but ...
4
votes
2answers
163 views
What is an effective method for installing up-to-date software on an out-dated production machine?
Apologies if this has been asked already, but I'm such a beginner, I'm not even able phrase a search query for this.
Background
My company uses a small out-dated cluster (CentOS 5.4) to do number ...
4
votes
1answer
100 views
Relocatable emacs
Is there a way to build emacs on Linux so it doesn't embed the path where it was built into the binary, and it can be relocated harmlessly to a different path?
That is, if you build with ...
4
votes
1answer
1k views
How do I convert a kernel .config file from 32-bit to 64-bit?
At this page you can download a configuration file that lets you target a particular notebook architecture during the compilation of a new 32-bit Linux kernel.
I need a 64 bit version.
What do I ...
4
votes
1answer
544 views
How can I specify OS-conditional build requirements in an RPM spec file?
I am trying to work my way around with the BuildPrereq flag in the spec files.
I want a few pre-requisites to be included if the OS is of a particular version. something like
if os == fedora 4
...

