summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorMagnus <mfeuer@jaguarlandrover.com>2014-09-14 16:45:13 -0700
committerMagnus <mfeuer@jaguarlandrover.com>2014-09-14 16:45:13 -0700
commitf0f53cf69a83980af80c664b304493dd90b0f006 (patch)
treea44c6ef894ba2d9f10f85b5b32726ea996c3fbc8 /Makefile
parent7b13e3a6e0b330c5e991a73fd415cebd4f11fb27 (diff)
downloadrvi_core-f0f53cf69a83980af80c664b304493dd90b0f006.tar.gz
Now builds RPM files correctly. Still need to %install rpm/rvi start/stop script in /etc/init.d
Signed-off-by: Magnus <mfeuer@jaguarlandrover.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile36
1 files changed, 26 insertions, 10 deletions
diff --git a/Makefile b/Makefile
index 584be93..e61fe73 100644
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,14 @@
#
+# Copyright (C) 2014, Jaguar Land Rover
+#
+# This program is licensed under the terms and conditions of the
+# Mozilla Public License, version 2.0. The full text of the
+# Mozilla Public License is at https://www.mozilla.org/MPL/2.0/
+#
+
+#
# Makefile for the RVI node.
#
-#
.PHONY: all deps compile clean rpm rpmclean
@@ -26,12 +33,21 @@ clean: rpmclean
./rebar clean
rpmclean:
- rm -rf ./rpm/BUILD ./rpm/BUILDROOT ./rpm/RPM ./rpm/RPMS
- rm -rf ./rpm/SOURCES ./rpm/SPECS ./rpm/SRPM ./rpm/SRPMS
-
-rpm: deps compile
- ./setup_rvi_node.sh -n rvi-$(VERSION) -c rvi_sample.config
- mkdir -p ./rpm/BUILD ./rpm/BUILDROOT ./rpm/RPM ./rpm/RPMS
- mkdir -p ./rpm/SOURCES ./rpm/SPECS ./rpm/SRPM ./rpm/SRPMS
- (cd rel; tar czf ../rpm/SOURCES/rvi-$(VERSION).tgz rvi-$(VERSION))
- rpmbuild --define "_topdir $$PWD/rpm" -ba rpm/rvi-0.2.spec
+ rm -rf ./rpm/BUILD/* \
+ ./rpm/BUILDROOT/* \
+ ./rpm/RPMS/* \
+ ./rpm/SOURCES/* \
+ ./rpm/SRPMS/*
+
+
+# Create a SOURCES tarball for RPM
+rpm_tarball: rpmclean clean
+ tar czf /tmp/rvi-$(VERSION).tgz BUILD.md CONFIGURE.md doc \
+ hvac_demo LICENSE Makefile README.md rebar rebar.config rel \
+ RELEASE.md rpm rvi_node.sh rvi_sample.config setup_rvi_node.sh \
+ src tizen_vehicle.config TODO
+ mv /tmp/rvi-$(VERSION).tgz ./rpm/SOURCES/
+
+
+rpm: rpm_tarball
+ rpmbuild --define "_topdir $$PWD/rpm" -ba rpm/SPECS/rvi-$(VERSION).spec