Skip to content

awestruct/rubygem-awestruct-rpm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

rubygem-awestruct: Awestruct RPM package spec

This repository hosts the RPM package spec file for the Awestruct static site generator. The package is named rubygem-awestruct.

Prerequisites

This RPM spec was developed for Fedora 18 and above, but may be useful for other RPM-based systems.

Preparing your environment

You first need to install the packages necessary to build the RPM. Begin by installing the @fedora-packager group (as root or using sudo):

yum install @fedora-packager wget

Next, clone this repository and switch to it:

git clone git://github.com/awestruct/rubygem-awestruct-rpm.git
cd rubygem-awestruct-rpm

Finally, install the packages that this build requires (as root or using sudo):

yum-builddep rubygem-awestruct.spec

Next, we need to put the package source and patches in place.

Preparing the sources

You can build RPMs as a non-privileged user, though you need to prepare the directories first. Let’s use the directory rpmbuild in our $HOME directory:

echo "%_topdir %(echo $HOME)/rpmbuild" > $HOME/.rpmmacros

You’ll also need to create all the required folders:

mkdir -p $HOME/rpmbuild/{BUILD,BUILDROOT,RPMS,SOURCES,SPECS,SRPMS}

Next, grab the Asciidoctor gem (the sources) and put it into the $HOME/rpmbuild/SOURCES directory:

wget -O $HOME/rpmbuild/SOURCES/awestruct-0.5.0.gem http://rubygems.org/gems/awestruct-0.5.0.gem

Finally, copy the .patch files from this repository to the same directory:

cp patches/* $HOME/rpmbuild/SOURCES/

You’re now ready to build the RPM.

Building the RPM

With everything in place, building the RPM is easy!

rpmbuild -ba rubygem-awestruct.spec

If all goes well, both the binary and source RPMs will emerge in the $HOME/rpmbuild/RPMS/noarch and $HOME/rpmbuild/SRPMS directories, respectively.

Installing the RPM

There’s nothing special about installing this RPM. I recommend using yum because it will install any dependencies that the package requires (though you should already have them if you built the RPM).

yum localinstall $HOME/rpmbuild/RPMS/noarch/rubygem-awestruct-0.5.0.rpm

Now, it’s time to start using Awestruct! Visit http://awestruct.org to learn more.

About

An RPM package spec for Awestruct (rubygem-awestruct)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published