mirror of
https://github.com/mdbtools/mdbtools.git
synced 2025-09-19 18:47:54 +08:00
Updated package script and readme.
* Includes build instructions for rpm package * Provide better link for rpm package
This commit is contained in:
@@ -23,8 +23,10 @@ $ sudo apt-get install cyber-mdbtools
|
|||||||
No repository for RPM distribution, but you can install from rpm file:
|
No repository for RPM distribution, but you can install from rpm file:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
$ wget https://rpm.cybercoder.site/rpm/cyber-mdbtools-0.8.1-2.x86_64.rpm
|
# Replace the <version> with the version number you wish to install. For list of versions see the releases on GitHub
|
||||||
$ rpm -i cyber-mdbtools-0.8.1-2.x86_64.rpm
|
|
||||||
|
$ wget https://rpm.cybercoder.site/rpm/cyber-mdbtools-<version>-1.x86_64.rpm
|
||||||
|
$ rpm -i cyber-mdbtools-<version>-1.x86_64.rpm
|
||||||
```
|
```
|
||||||
|
|
||||||
> The RPM package was created using `alient` from the DEB package, so it may or may not work on your linux distribution.
|
> The RPM package was created using `alient` from the DEB package, so it may or may not work on your linux distribution.
|
||||||
|
@@ -1,12 +1,43 @@
|
|||||||
#!/bin/bash -e
|
#!/bin/bash -ex
|
||||||
|
|
||||||
|
function usage(){
|
||||||
|
echo ""
|
||||||
|
echo "This script packages mdbtools into a .deb and .rpm packages"
|
||||||
|
echo ""
|
||||||
|
echo "Usage package.sh <version> [<release>]"
|
||||||
|
echo ""
|
||||||
|
echo "Arguments:"
|
||||||
|
echo " <version> is the version to build"
|
||||||
|
echo " <release> is the release number to build; optional (default 1)"
|
||||||
|
echo ""
|
||||||
|
}
|
||||||
|
|
||||||
if [ -z "$1" ]; then
|
if [ -z "$1" ]; then
|
||||||
echo "Missing version"
|
echo "ERROR: Missing version"
|
||||||
echo ""
|
usage
|
||||||
echo "Usage package.sh <version>"
|
|
||||||
echo ""
|
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
sudo checkinstall -y --pkgname=cyber-mdbtools --pkgversion=$1 --pkggroup=Tools --pkgsource=https://github.com/cyberemissary/mdbtools/archive/master.zip \
|
if [ "--help" = "$1" ]; then
|
||||||
|
usage
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
PKG_VERSION=$1
|
||||||
|
PKG_RELEASE=1
|
||||||
|
|
||||||
|
if [ ! -z "$2" ]; then
|
||||||
|
PKG_RELEASE=$2
|
||||||
|
fi
|
||||||
|
|
||||||
|
sudo checkinstall -y --pkgname=cyber-mdbtools --pkgversion=${PKG_VERSION} --pkgrelease=${PKG_RELEASE} --pkggroup=Tools \
|
||||||
|
--pkgsource=https://github.com/cyberemissary/mdbtools/archive/master.zip \
|
||||||
--maintainer=admin@cyberemissary.com --provides=mdbtools
|
--maintainer=admin@cyberemissary.com --provides=mdbtools
|
||||||
|
|
||||||
|
# remove directory in case we are rebuilding the same version and we quite prematurely before
|
||||||
|
rm -Rf cyber-mdbtools-${PKG_VERSION}
|
||||||
|
sudo alien -r -g -v -k cyber-mdbtools_${PKG_VERSION}-${PKG_RELEASE}_amd64.deb
|
||||||
|
|
||||||
|
cd cyber-mdbtools-${PKG_VERSION}
|
||||||
|
sudo rpmbuild --buildroot $(pwd)/ --bb cyber-mdbtools-${PKG_VERSION}-${PKG_RELEASE}.spec
|
||||||
|
cd
|
Reference in New Issue
Block a user