https://github.com/xtruder/rpms
Custom fedora rpm packages
https://github.com/xtruder/rpms
copr fedora rpm
Last synced: 12 days ago
JSON representation
Custom fedora rpm packages
- Host: GitHub
- URL: https://github.com/xtruder/rpms
- Owner: xtruder
- Created: 2020-09-09T14:46:10.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2024-05-31T13:46:20.000Z (11 months ago)
- Last Synced: 2024-05-31T14:24:05.891Z (11 months ago)
- Topics: copr, fedora, rpm
- Language: Dockerfile
- Homepage: https://copr.fedorainfracloud.org/coprs/offlinehacker/xtruder-rpms/
- Size: 92.8 KB
- Stars: 2
- Watchers: 3
- Forks: 1
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# RPMs
Custom x-truder rpm packages. You can install packages via https://copr.fedorainfracloud.org/coprs/offlinehacker/xtruder-rpms/
## Writing spec file
### Notes regarding arch and copr
Copr requires `BuildArch` to be set to `x86_64` or `aarch64`, otherwise it will refuse to download
sources for some reason.## Building packages
- Building locally
```
fedpkg --release f38 mockbuild --enable-network
```Building with custom parameters:
```
fedpkg --release f37 mockbuild --mock-config ./fedora-37-x86_64-bazel.cfg --enable-network
```- Cleanup
```
fedpkg clean -x
```## Running builds on copr
Create copr api config by visiting [https://copr.fedorainfracloud.org/api/](https://copr.fedorainfracloud.org/api/)
and put it into `.devcontainer/config/copr` file.## Installing packages
- Add yum repo
```
cat /etc/yum.repos.d/offlinehacker-xtruder-rpms-fedora.repo
[copr:copr.fedorainfracloud.org:offlinehacker:xtruder-rpms]
name=Copr repo for xtruder-rpms owned by offlinehacker
baseurl=https://download.copr.fedorainfracloud.org/results/offlinehacker/xtruder-rpms/fedora-$releasever-$basearch/
type=rpm-md
skip_if_unavailable=True
gpgcheck=1
gpgkey=https://download.copr.fedorainfracloud.org/results/offlinehacker/xtruder-rpms/pubkey.gpg
repo_gpgcheck=0
enabled=1
enabled_metadata=1
```- Installing on fedora silverblue
```
sudo rpm-ostree install
```- Cleaning package cache
```
sudo rpm-ostree refresh-md -f
```## Packaging
### Preparing package and downloading sources
```
fedpkg prep
```This will download and unpack sources
If you have issue with that command you can use `spectool` to download sources instead:
```
spectool -g -C . myspec.spec
```### Packaging python packages
To generate package from pypi use: https://github.com/fedora-python/pyp2rpm (`sudo dnf install pyp2rpm`)
Example usage:
```
pyp2rpm -o fedora trezor_agent > trezor_agent.spec
```### Packaging go packages
This guide will get you started: https://developers.redhat.com/articles/2021/05/21/build-your-own-rpm-package-sample-go-program#
## Notes
- Unpacking rpm files
```shell
rpm2cpio gnome-shell-extension-workspaces-bar-0-0.20211125git667571d.fc37.noarch.rpm | cpio -idmv
```