Skip to content

Commit

Permalink
Add capability to 'make rpm' check the dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
jpereira authored and arr2036 committed Apr 3, 2019
1 parent 383391f commit d8bff6f
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -71,3 +71,6 @@ appendonly*.aof

# Local scripts
run.sh

# rpm packages
rpmbuild/
12 changes: 10 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@
# Version: $Id$
#

#
# we didn't called ./configure? just define the version.
#
RADIUSD_VERSION_STRING := $(shell cat VERSION)

#
# The default rule is "all".
#
Expand Down Expand Up @@ -360,8 +365,11 @@ rpmbuild/SOURCES/freeradius-server-$(RADIUSD_VERSION_STRING).tar.bz2: freeradius
@cp $< $@

rpm: rpmbuild/SOURCES/freeradius-server-$(RADIUSD_VERSION_STRING).tar.bz2
@rpmbuild --define "_topdir `pwd`/rpmbuild" -bb redhat/freeradius.spec

@if ! yum-builddep -q -C --assumeno redhat/freeradius.spec 1> /dev/null 2>&1; then \
echo "ERROR: Required depdendencies not found, install them with: yum-builddep redhat/freeradius.spec"; \
exit 1; \
fi
@QA_RPATHS=0x0003 rpmbuild --define "_topdir `pwd`/rpmbuild" -bb redhat/freeradius.spec

# Developer checks
.PHONY: warnings
Expand Down

0 comments on commit d8bff6f

Please sign in to comment.