date int64 1,220B 1,719B | question_description stringlengths 28 29.9k | accepted_answer stringlengths 12 26.4k | question_title stringlengths 14 159 |
|---|---|---|---|
1,308,324,734,000 |
How can I list the configuration options that ssh/sshd was compiled with?
I'm attempting to troubleshoot a SELinux configuration issue, and want to make sure that SSH was compiled with --with-selinux.
|
I don't think there's a way to list compilation options, but something like SELinux support should be apparent from the libraries that the executable is linked against:
$ ldd /usr/bin/ssh /usr/sbin/sshd | egrep '^/|selinux'
/usr/bin/ssh:
/usr/sbin/sshd:
libselinux.so.1 => /lib/libselinux.so.1 (0x00007fbbfed5f0... | Output compiler options from SSH |
1,308,324,734,000 |
When I am building software from source on a GNU+Linux system, during the ./configure stage I frequently see the following line:
checking for suffix of executables...
How do I create such a check in a bash script?
The reason I want to know this is that I want to create a makefile in which it compiles with suffix .exe... |
The test is done by compiling a small dummy C program and by checking how the compiler names the output file.
The following example is a simplified version of what configure is doing
#!/bin/sh
cat << EOT > dummy.c
int main(int argc, char ** argv) {
return 0;
}
EOT
gcc -o dummy dummy.c
if [ -f dummy.exe ] ; then... | Find out extension of executable files? |
1,308,324,734,000 |
I am working on a project that includes building an old kernel version of linux. This is fine, but I still need to patch the kernel of all previously found security vulnerabilities based on CVEs. I have the CVEs and have extracted the names of the vulnerable files mentioned in them, along with the kernel versions it... |
Do the build, then list the .o files. I think every .c or .S file that takes part in the build is compiled into a .o file with a corresponding name. This won't tell you if a security issue required a fix in a header file that's included in the build.
make vmlinux modules
find -name '*.o' -exec sh -c '
for f; do fo... | How do I know which files will be included in a linux kernel before I build it? |
1,308,324,734,000 |
I have a few Linux machines laying around and I wanted to make a cluster computer network. There will be 1 monitor that would be for the controller. The controller would execute a script that would perform a task and split the load onto the computers.
Lets say I have 4 computers that are all connected to the controlle... |
You could try making a Beowulf Cluster. You set up one host as a master and the rest as nodes. It's been done in the past by others, including NASA as the wikipedia entry on Beowulf Cluster says.
Building your own cluster computer farm might cost more in power than you'd gain in compute resources.
I have not tried... | Remotely execute commands but still have control of the host |
1,308,324,734,000 |
I try to build the Linux kernel with Buildroot using Docker. I've created a simple Docker image:
FROM debian:7
MAINTAINER OrangeTux
RUN apt-get update && \
apt-get install -y \
build-essential \
bash \
bc \
binutils \
build-essential \
bzip2 \
cpio \
g++ \
gcc \
git \
... |
After extensive debugging I found out that mounting a folder on my host system at /root/buildroot/output/ causes the problem. Remove this mount and make linux-menuconfig is possible.
Further debugging revealed that mounting a host folder at /root/buildroot/output/build in the container is the problem. I've no clue wh... | Build linux-menuconfig results in: "*** Error during update of the configuration." |
1,308,324,734,000 |
I have an old embedded board that supports only Debian Lenny. I need to install OpenSSL-1.0.1e on it. If I download the source code then try to compile the source code, I get this error
ts7500:/home/openssl-1.0.1e# make
making all in crypto...
make[1]: Entering directory `/home/openssl-1.0.1e/crypto'
gcc -I. -I.. -I.... |
You haven't passed the right options to Configure. Make sure to pass the argument linux-armv4. If you're cross-compiling, in addition to armv4, you need to pass the path to the cross-compiler, as well as include and library paths if necessary.
./Configure --cross-compiler-prefix=/opt/gcc-arm/bin/arm-linux-gnueabi- -I/... | Backporting OpenSSL-1.0.1e to Debian Lenny (armv4l) |
1,308,324,734,000 |
I'm not very knowledgeable on this topic, and therefore can't figure out why the following command does not work:
$ gfortran -o dsimpletest -O dsimpletest.o ../lib/libdmumps.a \
../lib/libmumps_common.a -L/usr -lparmetis -lmetis -L../PORD/lib/ \
-lpord -L/home/eiser/src/scotch_5.1.12_esmumps/lib -lptesmumps -lpt... |
I was able to solve this with the help of the comments, particular credit to @Mat.
Since I wanted to compile the openmpi version, it helped to use mpif90 instead of gfortran, which, on my system, is
$ mpif90 --showme
/usr/bin/gfortran -I/usr/include -pthread -I/usr/lib/openmpi -L/usr/lib/openmpi -lmpi_f90 -lmpi_f77 ... | Why can't ld find this library? |
1,308,324,734,000 |
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 if there are some compiler flags I could use to optimize it for my hardware.
The CPU is an Athlon XP 2200+ (mobile), 1... |
General recommendation
If the version taken from your distribution repository of mplayer2 doesn't
work for you, it is a good thing to report what didn't work to the bug
tracking system, so that it has benefits for both you and others:
It gets fixed for your hardware in this release of your distribution.
It will (with... | Compiler flags for mplayer2 to optimize it for old hardware |
1,308,324,734,000 |
I was trying to make a linux server become a radius client. So I downloaded pam_radius. By following the steps from this website : openacs.org/doc/install-pam-radius.html and by following these steps :
cd /usr/local/src
wget ftp://ftp.freeradius.org/pub/radius/pam_radius-1.3.16.tar
tar xvf pam_radius-1.3.16
cd pam_ra... |
Your error message is:
make: cc: Command not found
which tells you that you are missing the C compiler. As @GAD3R suggests, installing the Development Tools group will correct this. You probably also need the pam-devel package.
But, that said: there's really no reason to build pam_radius yourself, as it already exis... | "cc: Command not found" when compiling a PAM module on Centos |
1,308,324,734,000 |
Why does a Linux distribution have gcc installed in advance? Is it because most of the applications in linux are written in C?
What would happen if the gcc directory is deleted?
|
Why does a Linux distribution have gcc installed in advance?
A Linux distribution is rather vague. Some install it, most offer to install it (possibly even if you select the defaults during installation). However not all distributions will install it and you usually have a choice.
Is it because most of the applicat... | Why does Linux have a C compiler by default? |
1,308,324,734,000 |
I'm trying to install soundconverter via git. This is what I did in Terminal:
$ sudo apt-get update && sudo apt-get upgrade && sudo apt-get install git
$ git clone https://github.com/kassoulet/soundconverter.git
$ cd soundconverter
$ ./autogen.sh
And here is the output from running /home/USERNAME/soundconverter/aut... |
Researching missing package
As you kind of picked up on this is your issue:
configure.ac:22: warning: macro 'AM_GLIB_GNU_GETTEXT' not found in library
aclocal: installing 'm4/intltool.m4' from '/usr/share/aclocal/intltool.m4'
aclocal: installing 'm4/nls.m4' from '/usr/share/aclocal/nls.m4'
./autogen.sh: 27: ./autogen.... | Warning: macro 'AM_GLIB_GNU_GETTEXT' not found in library |
1,308,324,734,000 |
I read the post here and I tried to make do with what I understood from the post but here are some questions:
Where is the /lib/firmware located in for example /usr/src/linux/lib/firmware or /usr/lib/firmware or elsewhere?
Could I use a pre-build EDID in that address the post gave and tweak it with an editor like Gvi... |
Where is /lib/firmware?
The final resting place for your EDID mode firmware should be under /lib/firmware/edid. However, many linux distributions place the example EDID mode-setting firmware source and the Makefile under the directory for the linux kernel documentation. For Fedora, this is provided by the kernel-doc... | How to make EDID |
1,308,324,734,000 |
I am trying to build using ./configure.
I have
Three include directories
-I/path1/include
-I/path2/include
-I/path3/include
Two link directories
-L/path1/lib
-L/path2/lib
Two -l flag options
-ltensorflow
-lasan
Two compile flags
-O3
-g
How can I put all these flags effectively as options in ./configure?
|
The canonical way to do this is to provide values for various variables in the ./configure invocation:
./configure CPPFLAGS="-I/path1/include -I/path2/include -I/path3/include" \
CFLAGS="-O3 -g" \
LDFLAGS="-L/path1/lib -L/path2/lib" \
LIBS="-ltensorflow -lasan"
If the C++ compiler ... | How to put multiple -I, -L and -l flags in ./configure? |
1,308,324,734,000 |
I have chosen Gentoo for my Linux distribution. I installed it in VirtualBox for practice purposes only, so I just gave it 10GB of disk space. Yesterday when I tried to emerge the Chromium package, it printed the following:
"There is NOT at least 5GB disk space at /var/tmp/portage/www-client/chromium-42.0.2311.90/temp... |
Gentoo is a Linux distribution that compiles packages from sources. Compiling packages requires much more space that installing pre-compiled binaries (that is, binaries that are compiled on the machines of the distribution maintainers). When you install something from the sources, you also need the sources for all the... | Why does Chromium use so much disk space on Gentoo Linux? |
1,308,324,734,000 |
I need to compile an old Apache version, 1.3, and the compilation process fails because:
mod_auth_dbm.c:77:18: fatal error: ndbm.h: File or directory not found
Where is this ndbm.h file?
|
That file here (Fedora 18) belongs to gdbm-devel, the package containing it for Ubuntu should be named similarly. Check the dependencies for the source, you'll probably need a swath of -devel packages corresponding to each dependency.
What do you need an outdated apache, which moreover has known vulnerabilities? Why d... | Ubuntu: can't find ndbm.h |
1,308,324,734,000 |
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 in general is the result a lower memory usage?
|
Obviously, since the program needs to be loaded into memory, -Os will result in lower memory usage. But that is the only effect on memory usage it will have.
| Does optimizing for size reduce runtime memory usage as well as binary size? |
1,403,713,301,000 |
If I'm installing from source, do I need to keep the extracted tarball directory? So if I download the git tarball. I then do:
tar -xvzf git.tar.gz
This will create a git.x.x. directory, into which I cd, then run ./configure etc. Once I'm done with this process, and git, or whatever is installed, do I need to keep t... |
You don't need to keep it. However, you may want to keep the package tarball itself for:
make uninstall
Generally source packages have this as a make target so that you can tidily remove the package from your system if desired. It should not depend on preserving the state of the build, so you can erase the director... | Installing from source - do I need to keep the extracted tarball directory |
1,403,713,301,000 |
For a client I needed to add boost 1.54 to the system. So I downloaded the latest version (1.55) and built it within a special directory: /usr/local/lib/boost1.55/. This works. Then I had to adapt the Makefile in this way.
LIBS = $(SUBLIBS) -L/usr/lib/x86_64-linux-gnu
-LC:/deps/miniupnpc -lminiupnpc -lqre... |
You don't say what distribution of Linux this is, but often times there is a directory where you can add dynamically linkable libraries. On Redhat distros such as Fedora this directory is here, /etc/ld.so.conf.d/.
LD
You can add a file to this directory with the path to your newly installed library like so:
$ cat /etc... | Confusion about linking boost library while compilation |
1,403,713,301,000 |
I am configuring the Linux kernel version 3.9.4. I am being asked questions about RCU (seen below). Specifically, what are each of these and what are the advantages and disadvantages of enabling or disabling some of these?
Consider userspace as in RCU extended quiescent state (RCU_USER_QS) [N/y/?]
Tree-based hierarchi... |
There are some details about these options over on the LTTng Project site. RCU's are (read-copy-update). These are data structures in the kernel which allow for the same data to be replicated across cores in a multi-core CPU and they guarantee that the data will be kept in sync across the copies.
excerpt
liburcu is ... | Understanding RCU when Configuring the Linux Kernel |
1,403,713,301,000 |
I am compiling my first Kernel (3.5 rc1) from source through menuconfig.
Certain configuration options are pre-set.
Who / what determines if they are pre-set?
Does the make menuconfig somehow detect my computer and its devices and characteristics and generates them?
Or do the default configs come with the source, p... |
make menuconfig doesn't dynamically determine your environment and tries to set the appropriate config but uses your .config file and the default entries in kconfig.
So yes the defaults come with the source and are specified in the kconfig files which also specify the help text, dependencies and other things. Have a l... | How are Linux kernel compile config's determined? |
1,403,713,301,000 |
I am installing gcc version 5.1 on a supercomputer cluster. I configured it and am now running the make command. It has been several hours and is still running as it is a long install, but the work day is now over and I have to leave. If I use Ctrl+C to quit the make, if I re-run make tomorrow morning will it resume w... |
When you press Ctrl+C, the process (technically, the process group) that is running in your terminal is killed. You can't resurrect it. All you can do is run it again.
Running make involves a lot of steps that each compile a single file, or link some files, or run one test, etc. When you press Ctrl+C, the current step... | Can I resume make after a Ctrl+C? |
1,403,713,301,000 |
I'm trying to configure liquidsoap and compile it from source. The ./configure process gets stuck at this point:
checking lo/lo.h usability... no
checking lo/lo.h presence... no
checking for lo/lo.h... no
configure: error: LO headers not found.
Now it's quite difficult to find out which lib or package is needed. I se... |
There should be a package called liblo-dev on Debian that should provide this header. Simply install it using apt-get or aptitude:
aptitude install liblo-dev
| Which library are LO headers belonging to? |
1,403,713,301,000 |
On one computer I installed an application from source using configure make and make install. Now I want to install the same application on another computer that lacks gcc, make and all the other build tools. Both computers are running Kubuntu 12.04. How can I locate all the files to copy to the second computer? What ... |
If your source code already have debian configuration files , you'll just need to run (in the sorce directory):
dpkg-buildpackage
Otherwise you can create a deb package with checkinstall
Launch the configure script first , e.g ./configure --prefix=/usr , then do
checkinstall --install=no
It will ask few questions , j... | How to copy an installed application to another computer that lacks the build tools? |
1,403,713,301,000 |
I had asked about applying patches here . I tried today using the same procedure on a different source-package and it failed. Sharing -
~/games $ mkdir decopy
~/games/decopy $ apt-get source decopy
Reading package lists... Done
NOTICE: 'decopy' packaging is maintained in the 'Git' version control system at:
https://... |
This is a "3.0 (quilt)" package (see debian/source/format), so you'll need to use quilt to manage the patch. Revert the patch:
patch -R -p1 < ../use_tqdm_progress.patch
then create the appropriate structure:
mkdir -p debian/patches
cp ../use_tqdm_progress.patch debian/patches
echo use_tqdm_progress.patch >> debian/pa... | Applying patches in debian packages - Part 2 |
1,403,713,301,000 |
I'm compiling FFMPEG from source using the guide for Ubuntu which I've used before with success.
I'm compiling on a Vagrant virtual machine in VirtualBox on Ubuntu server 14.04. You can clone the project and vagrant up, and you'll have FFMPEG installed in the box: github.com/rfkrocktk/vagrant-ffmpeg.
I'm using Ansib... |
My problem lay in the fact that I never ran ldconfig after installing everything.
In order for shared object libraries to be found on Debian, you must run sudo ldconfig to rebuild the shared library cache.
| Compiling FFMPEG from source: cannot find shared library |
1,403,713,301,000 |
I was curious if it's possible to build Linux kernel without GNU toolchain (gcc+autotools).
I found out that it is possible: after applying patches from llvm.linuxfoundation.org, it was possible to build Linux kernel with clang. GNU linker was used.
The alternative to ld is gold which is also part of GNU binutils. Pop... |
As of 2018 lld seems mature enough to be used in production, not 100% compatible with bfd, but can be used as drop-in replacement in most cases.
Update: recently, a new linker appeared, and it is under active development: mold.
| What are the alternatives to GNU ld? |
1,403,713,301,000 |
I am compiling the Linux kernel for my specific hardware and I only select the drivers/options which I really need. This is in contrast to a typical distribution kernel, where they compile almost everything, to be compatible with as many hardware configurations as possible.
I imagine, for my kernel, I am only using 1%... |
Compiling my comment as answer:
Run the following command on one shell. You can make a shell script of it or demonize with the -d option.
inotifywait -m -r -e open --format '%f' /kernel_sources/directory/in_use/ -o /home/user/kernel_build.log
On other shell, execute make
The log file /home/user/kernel_build.log will... | Find out which kernel source files were used when kernel was compiled |
1,403,713,301,000 |
I'm trying to make a redis RPM using fpm
When I run the following commands, all binaries are installed to /tmp/installdir/usr/local/bin
cd /tmp/redis2-8
PREFIX=/tmp/installdir/usr/local/ make
PREFIX=/tmp/installdir/usr/local/ make install
How could I compile redis so that the redis-server binary is installed to /t... |
The fpm dev has this to say on the subject of distribution-specific guidelines:
I want a simple way to create packages without all the bullshit. In my own infrastructure, I have no interest in Debian policy and RedHat packaging guidelines - I have interest in my group's own style culture and have a very strong intere... | How do you separate /bin and /sbin when making an RPM? |
1,403,713,301,000 |
I'm experimenting with different kernel configuration files and wanted to keep a log on the ones I used.
Here is the situation:
There is configuration file called my_config which i want to use as a template
I do make menuconfig, load my_config make NO changes and save as .config.
When i do diff .config my_config, th... |
Why would here be differences
Because you loaded my_config into menuconfig, made changes, then saved it as .config. Of course they are different. If you saved it twice, once with each name, then they would be the same.
If you mean, they are more different than you think they should be, keep in mind there is not a ... | Saving a kernel config file through menuconfig results with different options? |
1,403,713,301,000 |
I have a hacked up Chromebook on which I'm running Gentoo. When I try to compile anything, CPU usage spikes up to 100%, the temperature increases by ~10 degrees C, battery usage spikes (4.X W -> 10 W), and it's a slow process. But I also have an Arch Linux computer running, and I can connect to it over SSH. They are b... |
No, you don't have to cross-compile (that would be necessary if you targeted another architecture.) There are two ways that I can think of that you could set up your systems to do this:
Use distcc. The Gentoo and Arch wikis do a good job of describing how to install and configure the program, so I won't copy the enti... | Offload compilation through SSH? |
1,403,713,301,000 |
I want to enable google bbr on my VPS. But I don't know this feature is integrated on linux kernel or not. How can I check it?
|
Below command used to find the available tcp congestion control algorithms supported.
1. cat /proc/sys/net/ipv4/tcp_available_congestion_control
bic reno cubic
2. This command used to find which tcp congestion control configured for your Linux.
sysctl net.ipv4.tcp_congestion_control
3. Below command is used to chang... | How to check what congestion algorithm supported on my linux kernel? |
1,403,713,301,000 |
There is a file version.h in /usr/include/linux. Many header files include this file and use the defines in there for their own ifdefs.
However, when I compile my own kernel, I cannot see how this can possibly be reflected correctly in e.g. version.h.
Actually this holds for all kernel-related header files. AFAICS /... |
When configuring a system against your own custom kernel, I would suggest adding a name to the current version in your modified kernel sources.
For instance, in Armbian they create their own kernel packages, and add a -sunxi to kernel.release.
Takin as an example modifying the 4.6.3 kernel version:
root@ruir:/usr/src/... | How to compile against a custom kernel (Debian)? |
1,403,713,301,000 |
For the first time in my Linux (Debian) career it seems necessary for me to compile a piece of software myself.
The process of compiling is well described on the project-website. However, there is one thing I don't understand, that keeps me from getting started:
I want to keep my package management (APT) tidy. To comp... |
If the package happens to be in a debian repo somewhere, you can use build-dep to install the build dependencies and mark those as 'automatically' installed. You can then use autoremove to cleanup those build deps.
apt-get build-dep -o APT::Get::Build-Dep-Automatic=true WhatImBuilding
apt-get autoremove
If whatever y... | compile packages AND keep apt tidy |
1,403,713,301,000 |
I'm currently trying to install gcc41 using the AUR and I'm experiencing an issue.
Everytime it goes through the compiling process the build fails because it cannot complete compilation of the toplev object because there is a redefinition error.
Here is the error. I don't really know where to go from here.
In file inc... |
I ran into something like this before. I think the issue is that you're trying to compile gcc41 from AUR, using GCC 5.2.0-1 (latest arch version.) GCC adds new errors as versions go on, so the source code of older versions of GCC isn't always considered valid under newer versions of GCC. If you can find a way to di... | Arch: Compiling toplev.o fails in GCC install |
1,403,713,301,000 |
Given two computers A and B with the same specifications, both with the same Linux distribution, is it possible to 'make' compile in computer A and copy the directory to computer B and 'make install' without problems?
|
In general it should be possible, if both hosts really have the same specifications (i.e. same processor architecture, same libraries in same versions installed, same kernel installed, same file system structure for referred config files/libraries, ...). But since you can do nasty things in Makefiles there might be si... | Can I compile in one computer and 'make install' in another? |
1,403,713,301,000 |
I have built pidgin from source on CentOS 7. This is because there is no package available yet. This went well, however, pidgin-otr-4.0.0 cannot find the headers for pidgin and purple.
They reside in /usr/local/include, and I can't work out what the configure script wants with its suggestion:
checking for EXTRA... con... |
I found the answer after having a second look at the pkg-config manual, and better understanding the purpose of those environment variables. I also noticed I could do a Google search for pidgin pkg-config. I was then able to find the solution.
This allows configure to find the required libraries with pkg-config...
$ ... | building pidgin-otr-4.0.0 on CentOS 7: can't find pidgin and purple |
1,403,713,301,000 |
When I enable make V=s to read the full log of make. I always see make[numer] in the log.
e.g:
datle@debian:~/workspace/cpx/trunk$ make
rm -rf openwrt/tmp
cp config/defaut.config openwrt/.config
cd openwrt && make
make[1]: Entering directory `/home/datle/workspace/cpx/trunk/openwrt'
make[1]: Leaving directory `/home/d... |
Those numbers is represent for makelevel, which let us know how sub-make relates to top-level make.
This is the recursive use of make, see more details here.
Digging into make source code, you can see something clearer.
In main.c:
/* Value of the MAKELEVEL variable at startup (or 0). */
unsign... | What does make[number] mean in make V=s? |
1,403,713,301,000 |
I am trying to compile OpenOnload from Solarflare for my nic on a server that I'm building. It is saying something about not having a kernel build.
root@server:/usr/src/openonload-201310-u2# ./scripts/onload_install
onload_install: Building OpenOnload.
mmakebuildtree: No kernel build at '/lib/modules/3.2.0-4-amd64/bu... |
It's talking about the kernel development headers which are needed for compiling certain applications. On Debian-based distributions, you can install them with this command:
sudo apt-get install linux-headers-`uname -r`
If you're asked for that, you may also require the following:
sudo apt-get install build-essential... | What is the "kernel build", and where do I get it? |
1,403,713,301,000 |
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 during the configuration step, but this doesn't seem to work when I try to do the same with rtorrent, as it keeps telling me... |
Most configure scripts allow you to specify the location of libraries they use.
./configure ... --with-ncurses=some/path ...
| Build binary and dependencies without sudo |
1,403,713,301,000 |
I would like to build standalone bash binaries, which would hopefully work on a good portion of the linux distributions out there. Complete coverage is definitely not a goal. How would I approach this? Best-effort suggestions welcome.
I understand that each distribution has e.g. unique readline implementations. If it ... |
Download the bash-static package from Debian and extract the executable.
ar p bash-static_*.deb data.tar.xz | tar -xJ ./bin/bash-static
If you want to see how it's done, look in the sources. The build instructions are in debian/rules. There's a lot of expansion going on, so run it:
debian/rules static-build
I think ... | Build a standalone bash |
1,403,713,301,000 |
I am trying to test the LD_LIBRARY_PATH environment variable. I have a program test.c as follows:
int main()
{
func("hello world");
}
I have two files func1.c and func2.c:
// func1.c
#include <stdio.h>
void func(const char * str)
{
printf("%s", str);
}
And
// func2.c
#include <stdio.h>
void func(const char... |
Use ld -soname:
$ mkdir dir1 dir2
$ gcc -shared -fPIC -o dir1/func.so func1.c -Wl,-soname,func.so
$ gcc -shared -fPIC -o dir2/func.so func2.c -Wl,-soname,func.so
$ gcc test.c dir1/func.so
$ ldd a.out
linux-vdso.so.1 => (0x00007ffda80d7000)
func.so => not found
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 ... | LD_LIBRARY_PATH environment variable |
1,403,713,301,000 |
I wonder if it is possible to compile individual software packages from FreeBSD source tree without compiling the whole kernel and world....Say,for example ex , which is included in the nvi (new vi) source code.
https://svnweb.freebsd.org/base/head/contrib/nvi/
My intention is to compile, if possible, individual softw... |
Sure, with the standard /usr/src installed it might run something like
# cat /etc/src.conf
CFLAGS=-pipe
DEBUG_FLAGS=-g
# cd /usr/src/usr.bin/vi
# make clean && make obj && make depend && make && make install
# gdb -d /usr/src/contrib/nvi/ex -d /usr/src/contrib/nvi/common -tui ex
| Is it possible to compile individual software from the FreeBSD source tree? |
1,403,713,301,000 |
I'm working on a clean Debian 7.7 install. After the install everything was working fine except the webcam in Iceweasel browser. After reading a lot I found that the best solution is to install FlashCam 1.4.5.
After downloading the sources, I did a make and got an error:
ERROR: Kernel configuration is invalid.
... |
Up to date instructions for building out-of-tree kernel modules are here. Installing the kernel config headers to the system include directory is not part of the procedure. Rather you invoke make from inside the kernel source tree and point it to the module's source tree with the M= parameter.
FlashCam hasn't been upd... | Why autoconf.h is not copied automatically to its place? |
1,403,713,301,000 |
I use Gentoo as my primary home Desktop OS. I have since ~2004. I appreciate the emerge command for managing a source based OS as well as it does. Every now and then I check on other distributions, but I'm particularly fond of Linux From Scratch - For those of you Who Don't Know. Granted, I've never been through t... |
Make is simply for convenience. You can build software without it, it is just more difficult.
When you run make to build something, it shows you the commands it is running. You can run those commands manually and get the same effect.
$ echo "int main() {}" > test.c
$ make test
cc test.c -o test
Which created a ... | What Did Users Do or Use Before the Make Command? |
1,403,713,301,000 |
I am just starting out with embedded Android drivers, so any help would be great. I haven't found a lot of resources online.
At the moment, I am working through a tutorial on porting a driver, and the instructions read:
copy the platform data initialization files, “driver_sources/platform.c" and "driver_sources/plat... |
According to elinux.org this should be mach-msm folder. It is a folder for Qualcomm SoCs.
| Embedded Linux: Which machine directory to pick in /arch/arm? |
1,403,713,301,000 |
Some binaries save the command line used to configure them inside the binary (I don't remember any that do, otherwise I'd check the source). Is there a way to obtain the command line used as a macro in configure.ac?
For example, if I compile my code with
./configure --foo bar CXX=g++
I would like to save --foo bar CX... |
configure is essentially a shell script bootstrapped from M4 macros, so you can use $* to grab all the arguments to ./configure. As per the autoconf manual you should do this right after AC_INIT, e.g.:
AC_INIT([My Program], 1.0, ...)
config_flags="$*"
AC_DEFINE_UNQUOTED([CONFIG_FLAGS],["$config_flags"],[Flags passed t... | autoconf save ./configure command line to config.h |
1,403,713,301,000 |
After having worked through Linux From Scratch, I get the eerie feeling that in practice, this is not how new distros are built.
How do I search for tools that other distributions are built with? Is Debian really built from scratch? Googling "Linux distro build tools" have not been very fruitful.
The following are som... |
Debian is built from scratch in the sense that each package maintainer builds his package from the source, so that you don't have to. Most distros work that way (exceptions are for example Gentoo or LFS). So the "tools" to build the software are depending on each component, and the packaging into a .deb or .rpm is oft... | How do I search for Linux distro build tools? |
1,403,713,301,000 |
How/why can a Firefox 64bit (or 32bit) package work on different Linux distributions since each Linux distribution has a different version for gcc, glibc, linux kernel, etc. ?
|
The way it's coded the application is not using any calls that would limit it on any particular distribution. Having said that the statement you are making is completely false because unless libstdc++.so.6, libm.so.6, libc.so.6 are present on the system firefox will not work. So your question is predicated on gcc an... | How/why can Firefox packages work on all Linuxes? |
1,403,713,301,000 |
So I've been at this for a while and have been poking around for an answer for a few days, and figure it's about time to ask for help. I am running Ubuntu 10.10 in VMWare Fusion, and have downloaded a copy of the 3.2 kernel and built it with all default settings. When I try to boot into the new kernel after a call t... |
You forgot to build your initrd that goes with the kernel. Run update-initramfs -c -k kernelversion and then update-grub to find it and add it to the grub menu.
| Kernel Panic - not syncing: VFS: Unable to mount root fs after new kernel compile |
1,403,713,301,000 |
Is there any patch for Linux kernel to use different memory allocators, such as ned allocator or TLSF allocator?
|
The allocators you mention are userspace allocators, entirely different to kernel allocators. Perhaps some of the underlying concepts could be used in the kernel, but it would have to be implemented from scratch.
The kernel already has 3 allocators, SLAB, SLUB, SLOB, (and there was/is SLQB). SLUB in particular is desi... | Kernel memory allocator patch |
1,403,713,301,000 |
I have built Qt6 in an Alma8 based Docker container, with the Docker host being Fedora 35.
Under some circumstances (described below), all Qt libs cannot load libQt6Core.so[.6[.2.4]]. But that file exists and the correct directory is searched for that file. Other Qt libs (e.g., libQt6Dbus.so) are found and loaded.
E... |
The question got answer in the Qt forums.
Summary:
The .so contains an ABI tag that denotes the minimum kernel version required. You can see this via objdump -s -j .note.ABI-tag libQt6Core.so.6.2.4. The result is in the last three blocks (0x03 0x11 0x00 -> 3.17.0 in my case).
This information is placed there on purp... | Existing .so file cannot be loaded even though it exists, seems to depend on Docker host OS |
1,403,713,301,000 |
I tried to compile the Hello World program in C, inside Eclipse PTP, but it gives me an error related to mpi.h.
I have included /usr/local/include and /usr/local/lib in my paths, and also tried running a search with find / -name mpi.h. I still get a No such file or directory error.
I tried to install mpich2, but still... |
This Stack Overflow question answers yours.
According to yum, the mpi.h header file is provided by the following packages:
$ yum whatprovides '*/mpi.h'
openmpi-devel-1.8.1-1.el6.x86_64
mpich2-devel-1.2.1-2.3.el6.x86_64
mvapich2-devel-2.0rc1-1.el6.x86_64
mvapich-devel-1.2.0-0.3563.rc1.5.el6.x86_64
mvapich2-psm-devel-2.... | mpi.h not found |
1,403,713,301,000 |
I have a simple shared library that is currently compiled on Linux using:
gcc -c -fPIC foo.c -o foo.o
gcc -shared -o foo.so foo.o
I need to relay instructions to a colleague for compiling the same on AIX.
I do not know if my colleague will be using gcc on AIX or a native compiler.
Will these gcc instructions also work... |
On AIX you can have 3 compilers:
GCC
newer XL C/C++ Enterprise Edition
older VisualAge C++ Professional
For GCC since late 2.x, syntax for creating shared libraries is:
gcc -shared -Wl,-soname,your_soname -o library_name file_list library_list
Example:
gcc -fPIC -g -c -Wall a.c
gcc -fPIC -g -c -Wall b.c
gcc -shared... | How to compile shared library on AIX |
1,403,713,301,000 |
I want to know if there is any tool that, given the output of configure, cmake, autoconf or whatever library/dependencies matcher you have; installs the required packages/sources for you from your distro repo.
In other words, some tool that resolves library dependencies for you, installing needed packages depending on... |
No, it can't fully automatically infer dependencies.
If it had been packaged, apt-get build-dep oprofile would have helped. If you can find a package elsewhere, you can look up the dependencies there. For example, if the package exists in the next release of your distribution. e.g. here:
http://archive.ubuntu.com/ubu... | Is there any automatic tool for installing required libraries to compile a program from source? |
1,420,103,176,000 |
I needed to compile apache2 on ubuntu but I wanted it to use the original configuration and layout. It took me a very long time to find the information to do this, so I thought I would create this question and answer to help others.
Note: I needed the latest version of apache that was not yet supported by my version o... |
Preamble
This worked for me. If there is a simpler way, I am sure you will let me know.
In theory these steps should work for any linux distribution, you just need to find the original configure options that are used to compile apache for your distro. Perhaps you could add comments to this answer on where you found th... | How do I compile the latest apache2 on ubuntu using the original layout, configuration and configure options |
1,420,103,176,000 |
I have tried compile a driver for my kernel 3.13.0-40-generic. I have also tried compile a custom kernel with this driver but both have failed.
The name of the driver is vizzini for Linux 2.6.18-3.4.x. I have downloaded it from here.
The error is:
/home/usuario/Descargas/xr21v141x-lnx2.6.18-to-3.4-pak/vizzini.c:137:26... |
I was using a driver for <3.4 kernel and I have the 3.13. I had downloaded a new driver. I saw "3.1.3"...
| Error compiling custom kernel with a new usb serial driver |
1,420,103,176,000 |
Background
I discovered Ms. PacMan some time ago, but you don't see many of that game in arcades. Then I did find out about mame (version 0.145), available on my Linux (Ubuntu) machine and about running Ms. PacMan and that works.
Problem
When I save a game (so I don't have to start from the beginning every time (so to... |
Compiling and setting up mame or advancemame, with svgalib or newer replacements is not easy. You should stick with the working version of mame that you have.
If you get the message that the game is properly restored, the first thing to try is restoring from the same position a second time, do this while the system is... | MAME saving but not restoring games |
1,420,103,176,000 |
I'm using Buildroot for compiling embedded linux. It works well because I have target Makefile configurations, but now I need driver for my usb devices. I manage to compile Qt appilactions(c++) on my host linux to target linux by using buildroots /output/host/usr/bin/arm-none-linux-gnueabi-c++ . Works well.
Now I'm t... |
asm/ is a symbolic link to your target architecture, if it doesn't exist probably you're missing some target in your kernel build directory, configure (if not, maybe just module_headers can make it)
It is not clear from your question if you're using the command line, a custom Makefile, or a Buildroot package (which ve... | buildroot compiling driver |
1,420,103,176,000 |
I'm trying to use the IP_TRANSPARENT declaration. I am using debian 6.0.5. IP_TRANSPARENT is only defined in linux/in.h however it conflicts with netinet/in.h.
In centos for example, IP_TRANSPARENT is defined in both linux/in.h and bits/in.h.
When I look at the top of bits/in.h (which I get when I include netinet/in.h... |
I'm sure you already have the right versions, but linux/in.h is a kernel header that you should not be trying to include directly in a user space program.
You also shouldn't include bits/in.h as that is a header fragment that will be included by other headers when necessary.
The netinet/in.h is what you should be incl... | IP_TRANSPARENT missing from glibc headers |
1,420,103,176,000 |
I want to run SSH on Qtopia (on my FriendlyARM). My own distribution is Ubuntu, so I cannot copy and paste the ssh binary file into the device.
If I can copy and paste a binary file, where can I find it? If I must compile SSH, how is it possible in my ubuntu?
|
Your device has an ARM processor. Your PC has an x86 processor. ARM and x86 are different processor architectures with different instruction sets. An executable program compiled for x86 consists of x86 instructions that an ARM processor cannot execute, and vice versa.
You need an ARM binary. Furthermore, you need an A... | Adding ssh on embedded linux |
1,420,103,176,000 |
I'm working on a Davinci DSP ARM embedded board. The board itself is the Texas Instruments 816X/389X EVM. I'm currently trying to get apache working on the board. The problem is that the SDK for the board is extremely basic and doesn't include 'make' or any update manager like RPM, yum, or apt-get. So I'm having a har... |
When you are compiling something for another system, it needs to be cross-compiled to that architecture. Most likely your host is an x86. The TI is an ARM. The instruction set isn't the same. You need to setup a cross toolchain to compile apache with an ARM version of g++. TI should have included cross tools with the ... | Embedded board with apache |
1,420,103,176,000 |
How can i create initrd image for a new(experimental) kernel without actually installing it.
(Existing tools to create initrd based on config and details from installed kernel.)
Say i compile a new kernel with experimental features turned on, i have this in another separate partition. I would like to boot into this k... |
Creating an initrd doesn't have anything to do with installing a kernel. All you do is to create a file structure for the initrd, copy the required files, write the init script and package all of that into a cpio archive. I used the instructions in the Gentoo Wiki to make my initrd. Some distributions make tools to ge... | Creating new initrd without installing kernel |
1,420,103,176,000 |
There is an very old game (named "six") that is still available on Fedora as package six.x86_64 that I want to use in a hobby project of mine. I have more recent source from the original author, but cannot compile it because I don't have tools that old (think 2010 or older -- Qt3 and such).
Fedora seems able to keep ... |
How do I get a copy of the source
The easiest way is to download the source RPM with dnf download --source six (or if you are not on Fedora you can download it from Koji). You'll get a .src.rpm archive which contains the upstream source tarball, patches from Fedora and the SPEC file.
How does Fedora keep it working... | How to download and compile source code from Fedora |
1,420,103,176,000 |
I just bought a set top box (digital reciever - Vu+ Solo2) which runs Linux, and would like to compile some C software on it. It uses OPKG as the package manager. I executed
opkg update
and:
root@vusolo2:~# opkg install gcc
Unknown package 'gcc'.
Collected errors:
opkg_install_cmd: Cannot install package gcc.
root@vu... |
I found myself in this position today and the answer seems to be – simply: You don't want to. Just cross compile.
The Entware-ng opkg repository project provides a nice toolchain for this purpose, with instructions here. They only support native compilation on ARM|x86* and conclusively state:
There is no gcc for mips... | How to install compiler tools with opkg on MIPS CPU architecture |
1,420,103,176,000 |
I want to analyze code coverage datas. I want to create gcov files from OpenSSL (and from other projects), but I can only create them in the same directory of the project, and only for the files in the current folder.
I want to create them in a different directory, preserve the source original directory structure, an... |
You have the commands, so put them in a script!
To run a bunch of commands on different data, put the changing data in a variable.
To run gcov and mv on all the files, there are several possible methods, including:
Run gcov on all files, then move them.
Run gcov on one file, then move its output.
Run gconv on the fil... | How to create gcov files for a project in a different dir? |
1,420,103,176,000 |
I am trying to build a 3.12 Linux Kernel and I see some of the options (sub menus) are hidden and their branch (menu entry) is disabled in make menuconfig. [---- instead of being --->]
I know it is because of my system profile or their dependencies but I want to view all of them.
What helped in the previous kernel... |
Looking through the Wikipedia page for menuconfig I do not see a similar option. There's a bullet within that page that states the following:
The help information is distributed throughout the kernel source tree in the various files called Kconfig.
So one could use grep to search for whatever you wanted through thes... | View all disabled or hidden linux kernel options |
1,420,103,176,000 |
I run across such a weird problem:
According to this:
The kernel and modules must be moved to special locations in order to
be used,
1. make modules_install
2. make install
The first will create the /lib/modules/ directory and place
the modules there. The second make target will,
1. Move the kernel, bzImage, to ... |
This document appears to be incorrect or long-obsolete. Looking at the source, I see only bzImage and System.map being copied. This was the case at least as far back as 2.6.12. Copying an initrd or the .config file would have to be done by a distribution's scripts.
For some reason this depends on the architecture: arm... | Why is the .config file not copied to /boot after installing new kernel? |
1,420,103,176,000 |
I have Slackware installed on my computer, and I install a lot of software from source. Now I want to install ffmpeg from source just to recompile it with some more options. But I already have ffmpeg installed on my computer, so what's gonna happen?
Is it going to overwrite my old install or is it going to create new... |
If you use the configure, make, make install routine to install software under any Linux distro, then the new version will usually overwrite the previous. The only caveat is that if the newer version happens to change the install location or names of certain files then you may end up with the old version or parts of t... | New source install over existing one |
1,420,103,176,000 |
I want to compile and install a kernel.org kernel on a custom HDD volume, say /dev/sda5, instead of being merged with my current Ubuntu's directories.
I can find information about configuration and compilation process all over the web, but there's no track of how to put the kernel on a custom volume (different than th... |
You can compile a kernel anywhere you like, including your home directory. The only time directories outside the build tree are modified is when you make one of the install* targets. So, to install a kernel you'd do the obvious:
cd $SOME_DIRECTORY
tar -xjvf linux-$VERSION.tar.bz2
cd linux-$VERSION
make mrproper menuco... | Compiling and installing a kernel.org kernel to a custom volume on disk |
1,420,103,176,000 |
The instructions to build bitcoind are vague enough, but I can't work out what to do on OpenBSD. I've installed boost, and the system has berkeley db 4.6, OpenSSL, etc already in the base install of OpenBSD.
# gmake -f makefile.unix
Building LevelDB ...
gmake[1]: Entering directory `/root/... |
Use the bitcoin port from OpenBSD-WIP: https://github.com/jasperla/openbsd-wip/tree/master/net/bitcoin.
| Compiling bitcoind on OpenBSD |
1,420,103,176,000 |
I am trying to compile User Mode Linux on a 64 bit machine with defconfig and getting the following error.
arch/x86/um/user-offsets.c:1: sorry, unimplemented: code model "large" not supported yet
Any idea what this means?
|
From my shaky understanding: the compilation script is passing the -mcmodel=large option to GCC. This option is only supported since GCC 4.3 (or perhaps 4.4). You seem to have an older version where the option is recognized on the command line but not implemented under the hood.
This option produces an executable runn... | User Mode Linux compile fails |
1,420,103,176,000 |
Just out of curiosity, I am interested in compiling the Linux kernel with both the clang and zapcc compilers; one at a time.
I can't find a guide to follow. Only GCC is getting used to compile the Linux kernel.
How do I compile the Linux kernel with other compilers?
|
The kernel build allows you to specify the tools you want to use; for example, to specify the C compiler, set the CC and HOSTCC variables:
make CC=clang HOSTCC=clang
The build is only expected to succeed with GCC, but there are people interested in using Clang instead, and it is known to work in some circumstances (s... | How do I compile the Linux kernel with Clang? [closed] |
1,420,103,176,000 |
Take a look at the following command line:
gcc -o hello -Wall -D_BSD_SOURCE hello-world.c
Now, is there a way to know about these options by doing some processing on the 'hello' executable.
|
Sadly, no. But if you think about it before you create a binary, there are some ways. Here's another. With recent gcc, you can use -frecord-gcc-switches option which will add one section to the ELF file with the description you are seeking.
$ gcc -frecord-gcc-switches -o hello -Wall -D_BSD_SOURCE hello-world.c
$ reade... | Is there a way to know which options were used at compile time? |
1,420,103,176,000 |
I am connected to a linux system with SSH in my college. I found that ctorrent is a console alternative of bitorrent. I have downloaded the tar.gz source but to compile/install it needs sudo access
Is there a way to install the program without sudo access?
I don't know a lot about linux and cannot make this answer wor... |
you can install it locally in your home directory. Ususally it can be done by specifying the parameter prefix for configure script.
For example,
./configure --prefix=$HOME
So, when you compile sources configured in such way, then you will call
make install
the binaries will install into you $HOME/bin
Also, you sho... | Compile a program without sudo access |
1,420,103,176,000 |
I am interested to use NetBSD as the operating system on my server. I have not used a system where security updates are performed by source, but have read enough in the guide to feel comfortable trying it. However, I do not know how long this operation is likely to take.
Given a fairly modest server of say 1 processor... |
I would suggest that any decent not-so-modern x86_64 true server should be able do a full build in a couple of hours or maybe less, including xsrc.
My NetBSD-current build server is a Xen domU with 8GB RAM and 8 VCPUs running on a Dell PE2950 8-core (Xeon E5440 @2.83GHz) with 32GB RAM and with a decently fast set of S... | How long might it take to build NetBSD userland and kernel? |
1,420,103,176,000 |
I need to compile a package but the ./configure command does not work?
I'm getting the following error:
-bash ./configure : No such file or directory
Where is that script?
I used the locate command but it did not return anything.
|
locate will not work unless you have an up-to-date database.
Try find . -type f -name configure instead, or issue an updatedb command first, then do the locate (make sure the current path isn't excluded)
But first, you should always check the documentation - maybe the way to compile it does not use the configure mecha... | "./configure" command does not work |
1,420,103,176,000 |
I am on Linux Mint 18 Cinnamon 64-bit.
I was about to compile file-roller known as Archive manager for GNOME from source.
But when running:
./autogen.sh
There is a following M4 macro missing:
Checking for required M4 macros...
yelp.m4 not found
***Error***: some autoconf macros required to build Package
were not fou... |
You can use apt-file for this, without necessarily knowing where the M4 files go:
apt-file search yelp.m4
will tell you where the particular file should be located even without having the package (yelp-tools) installed.
yelp-tools: /usr/share/aclocal/yelp.m4
This tells you that installing yelp-tools should allow the... | Checking for required M4 macros... yelp.m4 not found |
1,420,103,176,000 |
g++ -Wall -I/usr/local/include/thrift *.cpp -lthrift -o something
This is from the Apache Thrift website.
Also is the -I/usr supposed to be -I /usr?
|
Here is a breakdown of the command. First the original command, for reference
g++ -Wall -I/usr/local/include/thrift *.cpp -lthrift -o something
Now, for the breakdown.
g++
This is the actual command command, g++. It is the program that is being executed. Here is what it is, from the man page:
gcc - GNU project C an... | What does this Linux command do? |
1,420,103,176,000 |
Historically speaking I know when I run the cc command or gcc my output generally always compiles to a.out unless I have a make file or use a particular flag on the compiler. But why a.out? Why not c.out or c.run or any myriad of a million possibilities?
|
It is a historical artefact, so in other words a legacy throwback. Historically a.out stands for "assembler output".
a.out is now only the name of the file but before it was also the file format of the executable.
The a.out executable format is nowadays uncommonly supported. The ELF format has wider use, but we still ... | Why do programs always compile to a.out? why not p.out or c.out or g.prog? |
1,420,103,176,000 |
I have to demonstrate a practical where I have to make my own module, add this module to a kernel's source and implement the system call. I'm using 3.16 kernel on Ubuntu but it takes around 2 hours to install the kernel from source.
Is it possible to remove some part of kernel(like unnecessary drivers,etc) from the so... |
As mentioned in comments, you should be building using something like make -j4. Use a number equal or slightly higher than the number of CPU cores you have.
make localmodconfig
The following instructions apply to building a kernel from upstream. Personally I find that simplest. I don't know how to obtain a tree wit... | Saving time while compiling Kernel |
1,420,103,176,000 |
I am programming a code to simulate a membrane which will run on computation cluster (single node). I want to optimize the code for that machine. I have used the -optimize, -O3 and -march=core2.
How can I tell if I can improve the march factor and is there any other thing I can do to improve this?
thanks
|
Use -mtune. -march is used to determine the allowed instruction set, whereas -mtune is to be used to tune performance of the code (as always, see man gcc). Depending on the precise CPU type, you might also consider values other than core2. And if you use a recent GCC version (at least 4.4, I think), you might best use... | Optimizing c++ compiliation for a specific machine |
1,420,103,176,000 |
When trying to install python 3.7 on Ubuntu 18.04
I get error messages like:
zipimport.ZipImportError: can't decompress data; zlib not available
or
ModuleNotFoundError: No module named '_ctypes'
or
~/.pyenv/plugins/python-build/bin/python-build: line 775: make: command not found
or
configure: error: no accept... |
From https://bugs.python.org/issue31652#msg321260
sudo apt-get install build-essential libsqlite3-dev sqlite3 bzip2 libbz2-dev zlib1g-dev libssl-dev openssl libgdbm-dev libgdbm-compat-dev liblzma-dev libreadline-dev libncursesw5-dev libffi-dev uuid-dev
| What libraries are needed to install Python 3.7 on Ubuntu 18.04 |
1,366,812,867,000 |
I am working on building Python 2.7.4 on CentOS 6.4. When running the make test step, the test_gdb step fails, and I would like to get some more info as to why.
Build commands I'm running:
./configure --prefix=/usr/local/python-2.7.4 --enable-ipv6 --enable-unicode=ucs4 --enable-shared
make
make test
Output of make... |
The actual lines around 679 in Lib/test/regrtest.py are:
NOTTESTS = {
'test_support',
'test_future1',
'test_future2',
}
This defines a mutable set and is syntax back-ported from 3.1 to 2.7. This syntax is not available in 2.6 or earlier version of python.
That your test raises a syntax error is probably b... | Running 'make test' on an individual module for Python 2.7.4 build |
1,366,812,867,000 |
I try to install subversion from source, but on ./configure receive:
configure: error: no suitable apr found
I have download apr source and installed:
libraries have been installed in:
/usr/local/apr/lib
So I returned to configure of subversion but receive the same error.
What I should do?
Thanks.
|
When configuring Subversion, try
./configure --with-apr=/usr/local/apr/
That might not be exactly the right path. Try finding apr-config and giving the path to that. I'm guessing it might be:
./configure --with-apr=/usr/local/apr/bin/apr-config
Try ./configure --help to see what your options are. There are a lot ... | How to make apr available for subversion install? |
1,366,812,867,000 |
A few questions about FreeBSD
Where/how should I obtain the source code (ex. through terminal, Download off website)
How (on ubuntu) should I build it?
Before I build it can I customize it (in other words is possible)?
|
You can check the source for FreeBSD out of version control here. The developer's handbook answers a lot of questions about developing FreeBSD. Why aren't you building it from FreeBSD itself? It seems kind of... odd to be building from Ubuntu.
| FreeBSD source and how to build |
1,366,812,867,000 |
Many a times while compiling some binary or library, I feel a need to have much verbose output of the build/compilation. Is there a flag or something I can write in the cmakelists.txt so I get much more verbose output. FWIW, I'm using cmake 3.16.3 on Debian testing which will eventually become Debian bullseye. Any hel... |
When running cmake itself, there are a couple of options you can use to generate more detailed output:
cmake --debug-output
and
cmake --trace
(the latter with even more detail than the former).
When running the build, you can ask for a verbose build by running
make VERBOSE=1
or at the cmake stage, define CMAKE_VERB... | Is there a way to make cmakelists.txt more verbose for compilation |
1,366,812,867,000 |
I'm having trouble linking the Intel MKL libraries to use in building Julia with MKL support. I've had this problem with other projects as well, but here I'll focus on Julia. I have MKL installed in /opt/intel. I've tried:
Running /opt/intel/bin/compilervars.sh intel64
Running /opt/intel/mkl/bin/mklvars.sh intel64
Ad... |
LD_LIBRARY_PATH and files in /etc/ld.so.conf.d configure the runtime linker, not the linker used during builds.
To build Julia with MKL, you should
add
USE_INTEL_MKL = 1
to Make.user
run
source /opt/intel/bin/compilervars.sh intel64
and build Julia from the same shell (so that the variables set by compilervars are ... | ld linker ignores LD_LIBRARY_PATH |
1,366,812,867,000 |
I am compiling a model using make. The model has a Makefile that connects the source code with dependent libraries via flags that look like -L/lib1 -L/lib2. But when I try to run that model, it fails unless I also ensure the environmental variable
export LD_LIBRARY_PATH=/lib1:/lib2
and points to the exact same libra... |
Although everyone uses compilation in the colloquial sense of turning source code into an executable it's technically a single step in a rather long pipeline:
The input file is run through the preprocessor resulting in a single translation unit.
The output of the preprocessor is compiled to assembly.
The assembler ta... | Why do I have to set LD_LIBRARY_PATH before running a program, even though I already linked the library locations in the compile stage? [duplicate] |
1,366,812,867,000 |
I'm doing some heavy number crunching on one system and I'd like to compile (and finetune) a custom GMP 6.1.0 for the user launching the number crunching computation. Previously I had a Debian wheezy (7.6) system on which I installed a custom GMP lib while being root and modificating things left and right in the files... |
You could use the following steps as normal user
tar xvjf gmp-6.1.0.tar.bz2
cd gmp-6.1.0
./configure --prefix=${HOME}/gmp/6.1.0
make
make install
This will install gmp in ~/gmp/6.1.0. Now if you want to use this version to compile software against or use it at runtime, you have to set some environment variables:
GMP... | How to install a custom GMP lib for just one user? |
1,366,812,867,000 |
Of course, the first question is: why I'm doing this. Just for fun! I'm learning more about Linux kernels and I have a virtual machine that I can replace in 15 minutes.
Getting to business, I don't know how to do this, so I went to trying to edit the makefile (trying to learn). So I started with the makefile in the pa... |
First learn to walk, then learn to fly.
If you want to learn, read. Have you read this instruction manual for building the kernel with the Intel C compiler? It's a rethorical question b/c this manual uses a different approach to choosing icc over gcc.
You are doing three things at once:
fiddle with some adopted and ... | Compile the Ubuntu “Raring” Kernel with the Intel Compiler |
1,366,812,867,000 |
I'm trying to use
pip install mysql-python
inside a virtualenv container and am getting the error
building '_mysql' extension
gcc -pthread -fno-strict-aliasing -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i686 -mtune=atom -fasynchronous-unwind-tables ... |
You can set your architecture manually by setting the CFLAGS environmental variable.
CFLAGS='-march=x86-64' pip install mysql-python
This variable's contents are appended to gcc's argument list.
| Pip install - CPU you selected does not support x86-64 instruction set |
1,366,812,867,000 |
I have installed ncurses package from source, and now I have
$HOME/local/include/ncurses/curses.h
$HOME/local/include/ncurses/ncurses.h
on my filesystem. I have also set up the search pathes so that
$ echo $C_INCLUDE_PATH
$HOME/local/include:
$ echo $CPLUS_INCLUDE_PATH
$HOME/local/include:
(i have eddited the output... |
configure scripts produce config.log (in the same folder) files which contain all the details on the tests it ran. They're not particularly easy to read, but open it up and search for "checking ncurses.h usability". Look at what went wrong with the small test program it tried to compile.
My guess is, it doesn't care a... | ncurses.h is not found, even though it is on the search path |
1,366,812,867,000 |
I can't get the pg gem to install. I have tried --with-pg_config and it didn't work.
Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
/usr/local/rvm/rubies/ruby-1.9.3-p194/bin/ruby extconf.rb
checking for pg_config... no
No pg_config... trying anyway. If building fails, please try ... |
Can't find the 'libpq-fe.h header
If you haven't done it already, install and initialize apt-file. This tool tells you what package contains a file with the given name.
sudo apt-get install apt-file
apt-file update
Then run apt-file search libpq-fe.h to find out what package contains this file, and install the pack... | Can't install pg gem |
1,366,812,867,000 |
I tried compiling a kernel from sources that I got from kernel.org (mainline) with make allyesconfig and make allmodconfig, but both builds resulted in a kernel, that won't boot.
I was thinking, that by compiling everything, It should work on close to any hardware. What am I doing wrong?
And how do I compile a working... |
One thing you can do is boot a working kernel, run lsmod, and make sure that all the modules listed are turned on in your config (either built-in or as modules).
It's easiest to start with a working config, and then tweak it. If you're lucky, your distribution ships the config file along with the kernel. For example... | How to compile a decent kernel from kernel.org? |
1,366,812,867,000 |
I need/want to have the whole build log when compiling a tool. The tool uses autotools.
I tried the most obvious way $ make > make.txt but that just gave the very end of the build to make.txt when I wanted to have the whole build log. Is there a way to do it ?
|
You need to run make as follow:
make 2>&1 | tee make.txt
| Is there a way to have a build log when running 'make'? |
1,366,812,867,000 |
I'm trying my hand at creating a very minimal custom Busybox/Linux distro, a task that is admittedly above my head, but I figured I'd give it a shot. My issue is that whenever I try to run a C program that is not Busybox or a Busybox utility, ash complains and tells me that the file is not found. I mounted the partiti... |
My guess is that you don't have the correct dynamic linker on the Busybox system.
On your Arch system do this:
ldd ./simplestprogram
I imagine ldd will give you output similar to this:
linux-vdso.so.1 => (0x00007fff9b34f000)
libc.so.6 => /lib64/libc.so.6 (0x0000003b19e00000
/lib64/ld-linux-x86-64.so.2 (0x0000003b... | Minimal Busybox/Linux Installation - Won't Run C |
1,366,812,867,000 |
My teacher wants to be able to compile our programs without having to type ./.
For example we would write:
g++ some_program.cpp -o some_program
some_program
He says to type:
cp .bash_profile .bash_profile.ORIG
Then load .bash_profile into text editor
Then go to the end of the file PATH=$Path: and add a period
exp... |
1) Do I just type cp .bash_profile .bash_profile.ORIG into the
terminal right after I open it?
Yes. You are essentially making a backup copy of your current ~/.bash_profile (assuming there is one).
2) How do I load it into my text editor?
It depends on what text editor you intend to use. I do this:
$ emacs ~/.... | How can I run my program without having to type ./? |
1,366,812,867,000 |
I tried to compile the program Testing Li’s criterion in Ubuntu. However, when I do gcc demo.c, I get the output as,
demo.c:2:19: fatal error: fmpcb.h: No such file or directory
#include "fmpcb.h"
^
compilation terminated.
How can I compile that program? I think I need some bash-script to make the... |
The file fmpcb.h no longer exists in the most recent version of Arb. The fmprb_t and fmpcb_t types in Arb 1.x were obsoleted by the (more efficient) arb_t and acb_t types in Arb 2.x. The most recent release removed the legacy fmpcb_t type entirely.
You should be able to get the code from that blog post working by subs... | How can I link my C program against the Arb library? |
1,366,812,867,000 |
I'm trying to compile a program prog and link it against OpenSSL's 1.0.2 beta, built from source and installed in /usr/local/ssl-1.0.2. On an older system using 0.9.8, this works without too much trouble. On a more recent system with 1.0.1 installed, this requires a bit more work. I'm wondering why.
1) On Ubuntu 10.04... |
There are three things you need to take care of when compiling/linking against a non-default package:
headers (usually CFLAGS)
compile-time library path (usually LDFLAGS)
run-time library path (rpath via LDFLAGS, LD_RUN_PATH, LD_LIBRARY_PATH or ld.so.conf)
You haven't said what prog is, so I can't how well-behaved ... | Get ld to pick the correct library |
1,366,812,867,000 |
In the process of building one library (Webdriver) I got the following error:
Package ibus-1.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `ibus-1.0.pc'
to the PKG_CONFIG_PATH environment variable
No package 'ibus-1.0' found
It seems to be because of the following line... |
If you need it for a build, then you need the #include headers as well. These, and the pkgconfig files, are not in the normal packages because they don't serve any purpose outside of compiling. Instead, they are included in separate -dev packages which you can install if you want to build something which must be com... | Should I install ibus-1.0 to build Webdriver? |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.