1 ##############################################################################
2 # Copyright (c) 2015 Ericsson AB and others.
3 # stefan.k.berg@ericsson.com
4 # jonas.bjurel@ericsson.com
5 # All rights reserved. This program and the accompanying materials
6 # are made available under the terms of the Apache License, Version 2.0
7 # which accompanies this distribution, and is available at
8 # http://www.apache.org/licenses/LICENSE-2.0
9 ##############################################################################
11 include $(BUILD_BASE)/config.mk
13 PACKAGE := odl_$(shell cd /tmp/controller; git rev-parse --short HEAD)
15 DEB_NAME := $(PACKAGE)_$(VERSION)
18 all: release/pool/main/$(DEB_NAME).deb
20 release/pool/main/$(DEB_NAME).deb:
21 ifeq ($(ODL_MAIN_REPO),)
22 @echo "No config-spec target for ODL, nothing to build"
25 @mkdir -p release/pool/main
26 @cp -rp package/$(DEB_NAME) tmp/src
27 @gzip -f9 tmp/src/$(DEB_NAME)/usr/share/doc/$(ODL_NAME_SHORT)/changelog.Debian
28 @fakeroot dpkg-deb --build tmp/src/$(DEB_NAME)
29 @lintian tmp/src/$(DEB_NAME).deb
30 @cp tmp/src/$(DEB_NAME).deb release/pool/main
37 @rm -f $(DEB_DEST)/$(DEB_NAME).deb
39 .PHONY: validate-cache
41 @echo "No cache validation schema available for $(shell pwd)"
42 @echo "Continuing ..."
45 release:release/pool/main/$(DEB_NAME).deb
46 ifneq ($(ODL_MAIN_REPO),)
47 @cp release/pool/main/$(DEB_NAME).deb $(DEB_DEST)
48 @cp -Rvp puppet/modules/* $(PUPPET_DEST)