Linux

How to build libsodium (NaCl) DEB packages

Problem:

You want to create a binary DEB package of libsodium. However, there is no official DEB package available for the latest version.

Continue reading →

Posted by Uli Köhler in Cryptography, Linux

User Mode Linux for Beginners – Setup and first VM

Why another UML tutorial?

This is not the first tutorial on UML — there are hundreds of them publicly available on the internet. However, none of them seems to fulfill my requirements:

  • All my computers and servers (= UML hosts) run on x86_64, not on i386.
  • Use an up-to date (self-compiled) UML version, so you can use the latest features
  • One simple set of scripts. Execute them in the correct order to get it up and running – no config file editing etc.
  • Root should not be required (disregarding debootstrap) —> No /mnt mounts or similar
  • No nasty filesystem image that eats up space on the host and limits resources on the UML VM. HostFS eliminates all those disadvantages – if you want to limit VM space, use quotas.
  • No global state (e.g. mounting sth into /mnt), you should get another VM up and running concurrently by executing the setup scripts in another directory.
  • Step-by-step instructions, as automated and portable as possible, but still made to be read by humans.
  • No expansive techtalk. There are reference documentations out there for techtalk. A tutorial should tell you how to get it working, not why it works.

Continue reading →

Posted by Uli Köhler in Container, Linux

How to fix “Cannot find crt1.o” on Ubuntu

Problem:

You’re trying to compile something (e.g. using GCC) on Ubuntu, but you get an error message similar to this one:

/usr/bin/ld: error: cannot open crt1.o: No such file or directory
/usr/bin/ld: error: cannot open crti.o: No such file or directory
/usr/bin/ld: error: cannot open crtn.o: No such file or directory

Continue reading →

Posted by Uli Köhler in Build systems, Linux

How to compile & install libc++ on Linux

Problem:

You want to compile and install libc++ (sometimes also named libcxx), but CMake complains with this error message

CMake Error at cmake/Modules/MacroEnsureOutOfSourceBuild.cmake:7 (message):
libcxx requires an out of source build. Please create a separate</em>

build directory and run 'cmake /path/to/libcxx [options]' there.
Call Stack (most recent call first):
 CMakeLists.txt:24 (MACRO_ENSURE_OUT_OF_SOURCE_BUILD)
CMake Error at cmake/Modules/MacroEnsureOutOfSourceBuild.cmake:8 (message):
 In-source builds are not allowed.

CMake would overwrite the makefiles distributed with Compiler-RT.
 Please create a directory and run cmake from there, passing the path
 to this source directory as the last argument.
 This process created the file `CMakeCache.txt' and the directory `CMakeFiles'.
 Please delete them.
Call Stack (most recent call first):
 CMakeLists.txt:24 (MACRO_ENSURE_OUT_OF_SOURCE_BUILD)

Continue reading →

Posted by Uli Köhler in Build systems, C/C++, Linux

How to solve LT_INIT command not found on Linux

Problem:

You are running a configure script on Linux. It exits with a message like this:

./configure: line 3638: LT_INIT: command not found

Continue reading →

Posted by Uli Köhler in Linux

Creating a highly compressed SquashFS from a folder

Problem:

You have a large compressible read-only folder that eats up a lot of disk space. You want to compress it using SquashFS.

Continue reading →

Posted by Uli Köhler in Linux

VNC: Scale VNC window

Problem:

You want to view a VNC on a screen with a different resolution than the screen you’re viewing (e.g. you want to view your Full HD desktop display on your Notebook).

Usually VNC viewers show scroll bars, but in some cases you need to view the entire screen at once.

Continue reading →

Posted by Uli Köhler in Linux