Giter VIP home page Giter VIP logo

barge-pkg's Introduction

Package Installer for Barge

Usage

pkg {build|install} [-f] <package-name> [build options]
pkg show <package-name>
pkg list

pkg build [-f] [build options]

Build a package and create /opt/pkg/<version>/barge-pkg-<package-name>-<version>.tar.gz. Or download it if the prebuilt package is available.
-f option forces it to build a package.

pkg install [-f] [build options]

Install (and build/download if necessary) /opt/pkg/<version>/barge-pkg-<package-name>-<version>.tar.gz into the root filesystem.
-f option forces it to build a package and then install.

pkg show

List files and directroies in /opt/pkg/<version>/barge-pkg-<package-name>-<version>.tar.gz to install.

pkg list

List /opt/pkg/<version>/barge-pkg-*-<version>.tar.gz you have locally.

Notes

  • It installs files in a package onto the root filesystem in RAM disk, so you have to install the pachage at each boot.
  • But once a package is built, installed or downloaded succesfully, it is stored at /opt/pkg for the future installation. In most of Barge distribution, /opt is persistent.
  • You may need [build options] to build a package properly. Please refer to the makefile of the package in Buildroot.
    e.g., https://git.busybox.net/buildroot/tree/package/git/git.mk

Customising

You can use your own resources to install/build packages by creating/editing the configuration file /etc/default/pkg as below.

[bargee@barge ~]$ cat /etc/default/pkg
# Docker image to build a package
# BUILDER="ailispaw/barge-pkg"

# Folder to store built packages locally
# PKG_DIR="/opt/pkg"

# URL of a package repository to store pre-built packages
# PKG_URL="https://github.com/bargees/barge-pkg/releases/download"

Note: <VERSION> from /etc/os-release will append to these values as a tag(:<VERSION>) / a subdirectory(/<VERSION>).

Examples

GNU tar

[bargee@barge ~]$ sudo pkg build tar
Downloading...FAIL
Building...
>>> tar 1.28 Downloading
>>> tar 1.28 Extracting
>>> tar 1.28 Patching
>>> tar 1.28 Updating config.sub and config.guess
>>> tar 1.28 Patching libtool
>>> tar 1.28 Configuring
.
.
.
>>> tar 1.28 Installing to target
.
.
.
DONE
barge-pkg-tar-2.0.0 has been in /opt/pkg/2.0.0.
[bargee@barge ~]$ pkg list
-rw-r--r--    1   1072814 Apr 27 00:45 barge-pkg-tar-2.0.0.tar.gz
[bargee@barge ~]$ sudo pkg install tar
Installing...
barge-pkg-tar-2.0.0 has been installed into the system.

perl

[bargee@barge ~]$ sudo pkg install perl

curl

[bargee@barge ~]$ sudo pkg install libcurl -e BR2_PACKAGE_OPENSSL=y -e BR2_PACKAGE_CURL=y
[bargee@barge ~]$ export CURL_CA_BUNDLE=/etc/ssl/certs/ca-certificates.crt

Pre-built Packages

* marked package is an extra package which is not included in Buildroot.

ACL

[bargee@barge ~]$ sudo pkg install acl

bindfs*

http://bindfs.org/

[bargee@barge ~]$ sudo pkg install bindfs

CRIU*

https://github.com/xemul/criu

[bargee@barge ~]$ sudo pkg install criu

eudev

[bargee@barge ~]$ sudo pkg install eudev

git

[bargee@barge ~]$ sudo pkg install git -e BR2_PACKAGE_OPENSSL=y -e BR2_PACKAGE_LIBCURL=y
[bargee@barge ~]$ git config --global http.sslCAinfo /etc/ssl/certs/ca-certificates.crt

iproute2

[bargee@barge ~]$ sudo pkg install iproute2

ipvsadm*

http://kb.linuxvirtualserver.org/wiki/Ipvsadm

[bargee@barge ~]$ sudo pkg install ipvsadm -e BR2_PACKAGE_LIBNL=y

libfuse

[bargee@barge ~]$ sudo pkg install libfuse

libstdc++*

[bargee@barge ~]$ sudo pkg install libstdcxx

Note: It's a special package which can not be built locally.

locales*

[bargee@barge ~]$ sudo pkg install locales
[bargee@barge ~]$ sudo localedef -i ja_JP -f UTF-8 ja_JP.UTF-8
[bargee@barge ~]$ locale -a
C
C.UTF-8
POSIX
ja_JP.utf8
[bargee@barge ~]$ export LANG=ja_JP.UTF-8

GNU Make

[bargee@barge ~]$ sudo pkg install make

shadow*

https://github.com/shadow-maint/shadow

[bargee@barge ~]$ sudo pkg install shadow

SSHFS

[bargee@barge ~]$ sudo pkg install sshfs

su-exec*

https://github.com/ncopa/su-exec

[bargee@barge ~]$ sudo pkg install su-exec

Tar

[bargee@barge ~]$ sudo pkg install tar

tzdata

To change timezone;

[bargee@barge ~]$ sudo pkg install tzdata -e BR2_TARGET_TZ_ZONELIST=default -e BR2_TARGET_LOCALTIME="Etc/UTC"
[bargee@barge ~]$ echo 'Europe/Paris' | sudo tee /etc/timezone
Europe/Paris
[bargee@barge ~]$ sudo cp -L /usr/share/zoneinfo/Europe/Paris /etc/localtime
[bargee@barge ~]$ date
Thu Mar 31 01:48:15 CEST 2016

To set back to 'UTC';

[bargee@barge ~]$ echo 'Etc/UTC' | sudo tee /etc/timezone
Etc/UTC
[bargee@barge ~]$ sudo ln -sf /usr/share/zoneinfo/Etc/UTC /etc/localtime
[bargee@barge ~]$ date
Wed Apr 27 00:48:41 UTC 2016

vim

[bargee@barge ~]$ sudo pkg install vim

barge-pkg's People

Contributors

ailispaw avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

imjching huapox

barge-pkg's Issues

Singularity: needs more packages

  • curl
    sudo pkg install libcurl -e BR2_PACKAGE_OPENSSL=y -e BR2_PACKAGE_CURL=y
  • comm
    sudo pkg install coreutils
  • file
    sudo pkg install file

Build wireguard appropriately

bargees/barge-os#90 (comment)

$ wget https://raw.githubusercontent.com/bargees/barge-os/master/configs/kernel.config
$ source /etc/os-release
$ sudo pkg build wireguard -v $(pwd)/kernel.config:/build/kernel.config \
-e BR2_LINUX_KERNEL=y \
-e BR2_LINUX_KERNEL_CUSTOM_VERSION=y \
-e BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE=\"${VERSION}\" \
-e BR2_LINUX_KERNEL_VERSION=\"${VERSION}\" \
-e BR2_LINUX_KERNEL_USE_CUSTOM_CONFIG=y \
-e BR2_LINUX_KERNEL_CUSTOM_CONFIG_FILE=\"/build/kernel.config\"

And then remove ./lib/modules/$(uname -r)/kernel and ./lib/modules/$(uname -r)/modules.* from the package archive file.

docker-compose

I can't install docker-compose

find: '/build/buildroot/output/target/usr/lib/python3.7/config-3.7m/': No such file or directory

docker-compose 1.20.1 Downloading
docker-compose 1.20.1 Extracting
docker-compose 1.20.1 Patching
docker-compose 1.20.1 Configuring
docker-compose 1.20.1 Building
/bin/bash: /build/buildroot/output/host/bin/python: No such file or directory
make: *** [/build/buildroot/output/build/docker-compose-1.20.1/.stamp_built] Error 127
package/pkg-generic.mk:238: recipe for target '/build/buildroot/output/build/docker-compose-1.20.1/.stamp_built' failed

any idea?

How to install xfsprogs?

Hi, I'm trying to install xfsprogs but it always fails with the following error:

FATAL ERROR: could not find a valid UUID header. Install the Universally Unique Identifiers development package. make: *** [/build/buildroot/output/build/xfsprogs-4.5.0/.stamp_configured] Error 1

I'm using the following command:

sudo pkg install xfsprogs

Can u tell me what I'm doing wrong? Or how to install that Universally Unique Identifiers development package?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.