manjaro-tools/README.md

404 lines
10 KiB
Markdown
Raw Normal View History

2015-01-30 02:13:01 +01:00
manjaro-tools
2014-10-04 00:31:47 +02:00
=============
2015-05-11 23:34:20 +02:00
Manjaro-tools-0.9.8
2014-12-27 19:49:53 +01:00
User manual
2015-01-17 21:28:09 +01:00
2015-02-12 22:15:56 +01:00
###1. manjaro-tools.conf
2014-12-27 19:49:53 +01:00
2015-01-30 02:39:15 +01:00
manjaro-tools.conf is the central configuration file for manjaro-tools.
By default, the config is installed in
2015-01-30 02:13:01 +01:00
~~~
2015-01-30 02:39:15 +01:00
/etc/manjaro-tools/manjaro-tools.conf
2015-01-30 02:13:01 +01:00
~~~
2015-01-30 02:39:15 +01:00
A user manjaro-tools.conf can be placed in
2015-01-30 02:13:01 +01:00
~~~
$HOME/.config/manjaro-tools.conf
~~~
2015-01-30 02:39:15 +01:00
If the userconfig is present, manjaro-tools will load the userconfig values, however, if variables have been set in the systemwide
2015-01-30 02:13:01 +01:00
~~~
/etc/manjaro-tools/manjaro-tools.conf
~~~
2015-01-30 02:39:15 +01:00
these values take precedence over the userconfig.
Best practise is to leave systemwide file untouched.
2015-01-30 02:13:01 +01:00
By default it is commented and shows just initialization values done in code.
2015-01-13 13:41:28 +01:00
2015-02-12 22:15:56 +01:00
Tools configuration is done in manjaro-tools.conf or by args.
2015-01-30 02:39:15 +01:00
Specifying args will override manjaro-tools.conf settings.
2015-01-17 21:21:54 +01:00
~~~
2015-03-02 23:42:51 +01:00
######################################################
################ manjaro-tools.conf ##################
######################################################
2015-01-17 21:21:54 +01:00
# unset defaults to given value
# branch=stable
# unset defaults to given value
# arch=$(uname -m)
# cache dir where buildpkg or buildiso cache packages
# cache_dir=/var/cache/manjaro-tools
2015-01-19 05:31:52 +01:00
################ buildtree ###############
# manjaro package tree
# repo_tree=('core' 'extra' 'community' 'multilib' 'openrc')
# host_tree=https://github.com/manjaro
2015-03-02 23:42:51 +01:00
# host_tree_abs=https://projects.archlinux.org/git/svntogit
2015-01-19 05:31:52 +01:00
2015-01-17 21:21:54 +01:00
################ buildpkg ################
# default chroot path
# chroots_pkg=/opt/buildpkg
# custom path to pkg sets
# sets_dir_pkg=/etc/manjaro-tools/sets/pkg
# default pkg buildset; name without .set extension
# buildset_pkg=default
# custom build mirror server
# build_mirror=http://mirror.netzspielplatz.de/manjaro/packages
2015-03-02 23:42:51 +01:00
# Next settings are only useful if you compile packages against eudev
2015-01-17 21:21:54 +01:00
# default packages to trigger blacklist
# blacklist_trigger=('eudev' 'upower-pm-utils' 'eudev-systemdcompat')
# default blacklisted packages to remove from chroot
# blacklist=('libsystemd')
################ buildiso ################
# default work dir where the image chroots are located
# chroots_iso=/opt/buildiso
# custom path to iso sets
# sets_dir_iso=/etc/manjaro-tools/sets/iso
# default iso buildset; name without .set extension
# buildset_iso=default
# unset defaults to given value
2015-03-05 10:54:28 +01:00
# dist_name="Manjaro"
2015-01-17 21:21:54 +01:00
# unset defaults to given value
2015-03-05 10:54:28 +01:00
# dist_release=0.9.0
2015-01-17 21:21:54 +01:00
2015-03-05 10:54:28 +01:00
# unset defaults to value sourced from /etc/lsb-release
# dist_codename="Bellatrix"
2015-03-03 02:53:30 +01:00
2015-01-17 21:21:54 +01:00
# unset defaults to given value
2015-03-05 10:54:28 +01:00
# dist_branding="MJRO"
2015-01-17 21:21:54 +01:00
2015-03-05 10:54:28 +01:00
# unset defaults to given value, specify a date here of have it automatically set
# dist_version="$(date +%Y.%m)"
2015-01-17 21:21:54 +01:00
# unset defaults to given value
2015-03-05 10:54:28 +01:00
# iso_name=manjaro
2015-01-17 21:21:54 +01:00
2015-05-11 23:34:20 +02:00
# publisher
# iso_publisher="Manjaro Linux <http://www.manjaro.org>"
# iso_app_id
# iso_app_id="Manjaro Linux Live/Rescue CD"
2015-01-17 21:21:54 +01:00
# unset defaults to given value
2015-03-05 10:54:28 +01:00
# iso_compression=xz
2015-01-17 21:21:54 +01:00
2015-01-28 21:05:28 +01:00
# valid: md5, sha1, sha256, sha384, sha512
2015-03-05 10:54:28 +01:00
# iso_checksum=md5
2015-03-02 23:42:51 +01:00
~~~
####Config files in iso profiles
Each iso profile must have these files or symlinks to shared:
2015-03-05 17:33:47 +01:00
######* profile.conf
2015-03-02 23:42:51 +01:00
~~~
##########################################
###### use this file in the profile ######
##########################################
# possible values: openrc,systemd
# initsys="systemd"
# displaymanager="lightdm"
2015-01-28 21:05:28 +01:00
2015-01-17 21:21:54 +01:00
################ install ################
2015-03-02 23:42:51 +01:00
# unset defaults to given value
2015-03-05 10:54:28 +01:00
# kernel="linux319"
2015-01-17 21:21:54 +01:00
# unset defaults to given value
2015-03-02 23:42:51 +01:00
# efi_boot_loader="grub"
2015-05-06 23:04:08 +02:00
# set uefi partition size
2015-05-11 23:34:20 +02:00
# efi_part_size=42M
2015-05-06 23:04:08 +02:00
2015-01-17 21:21:54 +01:00
# unset defaults to given value
# plymouth_theme=manjaro-elegant
# unset defaults to given values
# names must match systemd service names
2015-03-02 23:42:51 +01:00
# start_systemd=('bluetooth' 'cronie' 'ModemManager' 'NetworkManager' 'org.cups.cupsd' 'tlp' 'tlp-sleep')
2015-01-17 21:21:54 +01:00
2015-01-30 02:39:15 +01:00
# unset defaults to given values,
2015-01-17 21:21:54 +01:00
# names must match openrc service names
2015-03-02 23:42:51 +01:00
# start_openrc=('acpid' 'bluetooth' 'consolekit' 'cronie' 'cupsd' 'dbus' 'syslog-ng' 'NetworkManager')
2015-01-17 21:21:54 +01:00
################# livecd #################
# unset defaults to given value
# hostname="manjaro"
# unset defaults to given value
# username="manjaro"
# unset defaults to given value
# password="manjaro"
# unset defaults to given values
2015-03-02 23:42:51 +01:00
# addgroups="video,audio,power,disk,storage,optical,network,lp,scanner,wheel"
2015-01-17 21:21:54 +01:00
# unset defaults to given values
# names must match systemd service names
# services in start_systemd array don't need to be listed here
2015-02-12 22:56:41 +01:00
# start_systemd_live=('livecd' 'mhwd-live' 'pacman-init' 'pacman-boot')
2015-01-17 21:21:54 +01:00
2015-01-30 02:39:15 +01:00
# unset defaults to given values,
2015-01-17 21:21:54 +01:00
# names must match openrc service names
# services in start_openrc array don't need to be listed here
2015-02-12 22:56:41 +01:00
# start_openrc_live=('livecd' 'mhwd-live' 'pacman-init' 'pacman-boot')
2015-01-17 21:21:54 +01:00
~~~
2015-05-06 23:04:08 +02:00
######* Packages
2015-01-30 02:39:15 +01:00
Contains root image packages
ideally no xorg
2015-05-06 23:04:08 +02:00
######* Packages-Custom/desktop
2015-01-30 02:39:15 +01:00
Contains the custom image packages
desktop environment packages go here
2015-05-06 23:04:08 +02:00
######* Packages-Xorg
2015-01-30 02:39:15 +01:00
Contains the Xorg package repo
2015-05-06 23:04:08 +02:00
######* Packages-Lng
2015-01-30 02:39:15 +01:00
Contains the language packages repo
2015-05-06 23:04:08 +02:00
######* Packages-Livecd
2015-01-30 02:39:15 +01:00
Contains packages you only want on livecd but not installed on the target system with installer
2015-01-15 06:53:21 +01:00
default files are in shared folder and can be symlinked or defined in a real file
2014-12-27 19:49:53 +01:00
2015-03-02 20:05:27 +01:00
###### optional custom pacman.conf in profile
* for i686
2015-01-30 02:39:15 +01:00
~~~
pacman-default.conf
~~~
2015-03-02 20:05:27 +01:00
* for x86_64
2015-01-30 02:39:15 +01:00
~~~
pacman-multilib.conf
~~~
If you need a custom livecd-overlay, create overlay-livecd folder in profile, and symlink from shared/overlay-livecd/your_selection to the overlay-livecd folder.
2014-12-27 19:49:53 +01:00
2015-01-18 10:04:55 +01:00
###2. buildpkg
2015-01-17 21:16:08 +01:00
2015-02-12 22:15:56 +01:00
buildpkg is the chroot build script oi manjaro-tools.
It it run in a abs/pkgbuilds directory which contains directories with PKGBUILD.
2014-12-27 19:49:53 +01:00
2015-03-02 20:05:27 +01:00
######manjaro-tools.conf supports the makepkg.conf variables
2014-12-27 19:49:53 +01:00
2015-01-17 21:28:09 +01:00
####Arguments
2014-12-27 19:49:53 +01:00
2014-12-27 21:17:22 +01:00
~~~
2014-12-27 19:49:53 +01:00
$ buildpkg -h
Usage: buildpkg [options] [--] [makepkg args]
2015-01-15 06:48:34 +01:00
-p <pkg> Set or pkg [default: default]
-a <arch> Arch [default: x86_64]
2015-03-05 17:33:47 +01:00
-b <branch> Branch [default: stable]
2015-01-15 06:48:34 +01:00
-r <dir> Chroots directory
2015-03-05 17:33:47 +01:00
[default: /opt/buildpkg]
2014-12-27 19:49:53 +01:00
-c Recreate chroot
-w Clean up
-n Install and run namcap check
-s Sign packages
-q Query settings and pretend build
-h This help
2014-12-27 21:17:22 +01:00
~~~
2014-12-27 19:49:53 +01:00
2015-01-30 02:13:01 +01:00
######* build sysvinit package for both arches and branch testing:
2014-12-27 19:49:53 +01:00
2015-03-02 20:05:27 +01:00
* i686(buildsystem is x86_64)
2015-01-17 21:21:54 +01:00
2015-01-17 21:11:03 +01:00
~~~
2014-12-27 19:49:53 +01:00
buildpkg -p sysvinit -a i686 -b testing -cwsn
2015-01-17 21:11:03 +01:00
~~~
2015-01-17 21:21:54 +01:00
2015-03-02 20:05:27 +01:00
* for x86_64
2015-01-17 21:21:54 +01:00
2015-01-17 21:11:03 +01:00
~~~
2014-12-27 19:49:53 +01:00
buildpkg -p sysvinit -b testing -cswn
2015-01-17 21:11:03 +01:00
~~~
2015-01-17 21:21:54 +01:00
2015-05-06 23:04:08 +02:00
You can drop the branch arg if you set the branch in manjaro-tools.conf
2015-03-05 17:33:47 +01:00
The arch can also be set in manjaro-tools.conf, but under normal conditions, it is better to specify the non native arch by -a parameter.
2014-12-27 19:49:53 +01:00
2015-01-30 02:39:15 +01:00
######* -c
2015-05-06 23:04:08 +02:00
Removes the chroot dir
2015-01-17 21:11:03 +01:00
If the -c parameter is not used, buildpkg will update the existing chroot or create a new one if none is present.
2015-01-30 02:39:15 +01:00
######* -w
2015-03-05 17:33:47 +01:00
Cleans pkgcache, and logfiles
2015-01-30 02:39:15 +01:00
######* -s
2015-03-05 17:33:47 +01:00
Signs the package when built
2015-01-30 02:39:15 +01:00
######* -n
2015-03-05 17:33:47 +01:00
Installs the built package in the chroot and runs a namcap check
2014-12-27 19:49:53 +01:00
2015-01-18 10:04:55 +01:00
###3. buildiso
2014-12-27 19:49:53 +01:00
2015-01-15 06:48:34 +01:00
buildiso is used to build manjaro-iso-profiles. It is run insde the profiles folder.
2014-12-27 19:49:53 +01:00
2015-01-30 02:13:01 +01:00
#####Packages for livecd only:
2014-12-27 19:49:53 +01:00
2015-01-30 02:39:15 +01:00
* manjaro-livecd-cli-installer
2015-01-17 21:16:08 +01:00
* manjaro-livecd-openrc
* manjaro-livecd-systemd
2014-12-27 19:49:53 +01:00
2015-01-17 21:28:09 +01:00
####Arguments
2014-12-27 19:49:53 +01:00
2014-12-27 21:17:22 +01:00
~~~
2014-12-27 19:49:53 +01:00
$ buildiso -h
Usage: buildiso [options]
2015-01-30 02:13:01 +01:00
-p <profile> Buildset or profile [default: default]
2015-01-15 06:48:34 +01:00
-a <arch> Arch [default: x86_64]
2015-03-05 17:33:47 +01:00
-b <branch> Branch [default: stable]
2015-01-15 06:48:34 +01:00
-r <dir> Chroots directory
2015-03-05 17:33:47 +01:00
[default: /opt/buildiso]
2015-01-15 06:48:34 +01:00
-c Disable clean work dir
-x Disable clean xorg cache
-l Disable clean lng cache
2015-01-30 02:13:01 +01:00
-i Build images only
-s Generate iso only
Requires pre built images (-i)
-q Query settings and pretend build
2014-12-27 19:49:53 +01:00
-h This help
2014-12-27 21:17:22 +01:00
~~~
2014-12-27 19:49:53 +01:00
2015-01-30 02:13:01 +01:00
######* build xfce iso profile for both arches and branch testing on x86_64 build system
2015-03-02 20:05:27 +01:00
* i686 (buildsystem is x86_64)
2015-01-17 21:21:54 +01:00
2015-01-17 21:11:03 +01:00
~~~
2015-01-30 02:39:15 +01:00
buildiso -p xfce -a i686 -b testing
2015-01-17 21:11:03 +01:00
~~~
2015-01-17 21:21:54 +01:00
2015-03-02 20:05:27 +01:00
* for x86_64
2015-01-17 21:21:54 +01:00
2015-01-17 21:11:03 +01:00
~~~
2015-01-15 06:48:34 +01:00
buildiso -p xfce -b testing
2015-01-17 21:11:03 +01:00
~~~
2015-01-17 21:21:54 +01:00
2015-01-17 21:11:03 +01:00
The branch can be defined also in manjaro-tools.conf, but a manual parameter will always override conf settings.
2014-12-27 19:49:53 +01:00
2015-01-17 21:28:09 +01:00
####Special parameters
2015-01-30 02:39:15 +01:00
######* -i
2015-01-17 21:11:03 +01:00
Build images only will stop after all packages have been installed. No iso sqfs compression will be executed
2015-02-12 22:15:56 +01:00
######* -s
2015-01-17 21:11:03 +01:00
Use this to sqfs compress the chroots if you previously used -i.
2015-01-30 02:39:15 +01:00
######* -x
2015-01-30 02:13:01 +01:00
By default, xorg package cache is cleaned on every build. Disabling the xorg cache cleaning will result in no dowload again for xorg drivers and the cache is used.
2015-01-30 02:39:15 +01:00
######* -l
2015-03-05 17:33:47 +01:00
Disable lng cache, by default lng cache is cleaned on every build. Using this option will enable lng packages from cache rather than downloading them again.
2014-12-27 19:49:53 +01:00
2015-01-30 02:13:01 +01:00
###4. mkset
2014-12-27 19:49:53 +01:00
2015-01-17 21:11:03 +01:00
buildpkg and buildiso support building from buildsets
2014-12-27 19:49:53 +01:00
2015-01-17 21:16:08 +01:00
Default location of sets is:
2015-01-17 21:21:54 +01:00
2015-01-17 21:11:03 +01:00
~~~
/etc/manjaro-tools/manjaro-tools/sets/pkg
/etc/manjaro-tools/manjaro-tools/sets/iso
~~~
2015-01-17 21:21:54 +01:00
2015-01-17 21:11:03 +01:00
but it can be configured in the manjaro-tools.conf file.
2014-12-27 19:49:53 +01:00
2015-01-30 02:13:01 +01:00
mkset is a little helper tool to easily create buildsets.
2015-01-17 21:11:03 +01:00
It is run inside the abs/pkgbuilds or iso profiles directory.
2014-12-27 19:49:53 +01:00
2015-01-17 21:28:09 +01:00
####Arguments
2014-12-27 19:49:53 +01:00
2015-01-17 21:11:03 +01:00
~~~
$ mkset -h
Usage: mkset [options]
-c <name> Create set
-r <name> Remove set
-s <name> Show set
-i Iso mode
-q Query sets
-h This help
~~~
2015-01-15 06:48:34 +01:00
2015-01-30 02:13:01 +01:00
######* create a pkg buildset for lxqt
2014-12-27 19:49:53 +01:00
2015-01-17 21:11:03 +01:00
~~~
mkset -c lxqt-0.8
~~~
2015-01-15 06:48:34 +01:00
2015-01-30 02:13:01 +01:00
######* create a iso buildset
2014-12-27 19:49:53 +01:00
2015-01-17 21:11:03 +01:00
~~~
mkset -ic manjaro-0.9.0
~~~
2015-01-15 06:48:34 +01:00
2015-01-30 02:39:15 +01:00
The buildset name should not be a name of a package or profile!
Else buildpkg/buildiso won't recognize the build list and will only build the package/profile specified. The -p arg handles set and package/profile name.
2015-01-30 02:13:01 +01:00
If you create a buildset manually, the buildset must have a .set extension.
2015-01-07 21:41:33 +01:00
2015-01-30 02:39:15 +01:00
* Examples:
2015-01-15 06:48:34 +01:00
2015-01-17 21:11:03 +01:00
~~~
2015-01-30 02:39:15 +01:00
/etc/manjaro-tools/sets/pkg/lxqt-0.8.set
/etc/manjaro-tools/sets/iso/manjaro-0.9.0.set
2015-01-17 21:11:03 +01:00
~~~
2015-01-19 05:31:52 +01:00
2015-01-30 02:13:01 +01:00
###5. buildtree
2015-01-19 05:31:52 +01:00
2015-01-30 02:13:01 +01:00
buildtree is a little tools to sync arch abs and manjaro packages git repos.
2015-01-19 05:31:52 +01:00
####Arguments
~~~
$ buildtree -h
Usage: buildtree [options]
-s Sync manjaro tree
-a Sync arch abs
-c Clean package tree
-q Query settings
-h This help
~~~
2015-01-30 02:13:01 +01:00
######* sync arch and manjaro trees
2015-01-19 05:31:52 +01:00
~~~
buildtree -as
~~~