Jump to: navigation, search

Template:Build Documentation Build Package

Get Build Dependencies[edit]

Update your package lists.
sudo apt-get update

Install from Debian repository.
sudo apt-get install devscripts dh-apparmor faketime git

Install genmkfile. Either,

  • a) from source code (see footnote on how to do that) [1] or alternatively,
  • b) if you are already using Whonix, you could easily install it from Whonix repository:

sudo apt-get install genmkfile

Get the Source Code[edit]

Update the package lists.

sudo apt-get update

Install git.

sudo apt-get install git

Get the the package's source code.

git clone https://github.com/Whonix/{{{package}}}.git

Remember it is Whonix, not whonix! If you are prompted for a username for github, it means you have mistyped the web address.

Get the Signing Key[edit]

This chapter is recommended for better security, but not strictly required. (See Trust)

1. Download {{{fullname}}} OpenPGP key. {{{link}}}

Note: If you are already using Whonix, this process can be simplified. See footnotes. [2])

2. Store it as {{{shortname}}}.asc.

3. Import the key.

gpg --import {{{shortname}}}.asc

4. Verify the key using this fingerprint.

gpg --fingerprint {{{longfingerprint}}}

The output should show.

{{{gpgfingerprintparam}}}

5. This only gets the signing key from one source. For better security, learn more about the Whonix Signing Key.

Change Directory[edit]

Get into the package's source code folder.

cd {{{package}}}

OpenPGP Verify the Source Code[edit]

This chapter is recommended for better security, but is not strictly required.[3]

Retrieve a list of available git tags.

git tag

Verify the tag you want to build. Replace it with the tag chosen to build.

git tag -v {{{version}}}

The output should look similar to this.

object 1844108109a5f2f8bddcf2257b9f3675be5cfb22 type commit tag {{{version}}} tagger Patrick Schleizer <adrelanos@riseup.net> 1392320095 +0000

. gpg: Signature made Thu 13 Feb 2014 07:34:55 PM UTC using RSA key ID 77BB3C48 gpg: Good signature from "Patrick Schleizer <adrelanos@riseup.net>" [ultimate]

The warning.

gpg: WARNING: This key is not certified with a trusted signature! gpg: There is no indication that the signature belongs to the owner.

Is explained on the Whonix Signing Key page and can be safely ignored.

Choose Version[edit]

Use git checkout to select the preferred version (or git branch) to build.

In order to build a specific git tag.

git checkout 13.0.0.1.4-stable

Replace 13.0.0.1.4 with the actual version chosen for the build: the stable, testers-only or developers version. Common sense is required when choosing the right version number. For example, the latest available version number is not necessarily the most stable or suitable. To learn more about current Whonix versions, follow the Whonix News Blog.

Clean Up and Sanitize[edit]

This step is also important for security.

Retrieve the list of extraneous files and folders. [4]

git clean -ndff

See if the output looks sane; it generally should, unless Whonix source code is modified by advanced users (who understand git better anyhow). If the output looks like the following, everything is fine.

Would remove packages/apparmor-profile-gwenview/
Would remove packages/kde-privacy/

Remove these folders.

git clean -dff

The output should show.

Removing packages/apparmor-profile-gwenview/
Removing packages/kde-privacy/

Be sure to check out the right commit for each git submodule.

git submodule update --init --recursive

Check there are no extraneous files. This is important for security.

git status

The output should show the following and nothing else.

# Not currently on any branch.
nothing to commit (working directory clean)

If the directory is not clean, the extra files should be removed first.

Build and Install the Package[edit]

Have a look in debian/control file. Manually install all packages under Build-Depends on Depends.

Build the package without signing it (not required for personal use) and install it.

Easy.

make deb-icup

Of if you want to install with debugging enabled, click on expand on the right.

export DEBDEBUG=1
make deb-icup

Clean Up[edit]

Clean up temporary files debhelper files in package source folder as well as debhelper artifacts (.deb file etc.) in parent folder.

make deb-cleanup

Footnotes[edit]

  1. You can use the same instructions as on this page. Just replace the package name to genmkfile.
    git clone https://github.com/Whonix/genmkfile.git
    
    cd genmkfile
    
    make deb-icup
    
  2. Step 1, 2 and 3 can be done with just one command.
    gpg --import /usr/share/whonix/whonix-keys.d/patrick.asc
    
  3. See Trust.
  4. There is currently a small issue with this process (a limitation of git).

Random News:

Please help us to improve the Whonix Wikipedia Page. Also see the feedback thread.


Impressum | Datenschutz | Haftungsausschluss

https | (forcing) onion
Share: Twitter | Facebook | Google+
This is a wiki. Want to improve this page? Help is welcome and volunteer contributions are happily considered! See Conditions for Contributions to Whonix, then Edit! IP addresses are scrubbed, but editing over Tor is recommended. Edits are held for moderation. Whonix (g+) is a licensee of the Open Invention Network. Unless otherwise noted, the content of this page is copyrighted and licensed under the same Libre Software license as Whonix itself.