blob: 5177d5a089c315ba4ebbb6ee4c2694609f3b6f20 [file] [log] [blame]
Dennis Kempin31c0fbd2012-07-30 13:20:37 -07001# Copyright (c) 2012 The Chromium OS Authors. All rights reserved.
2# Use of this source code is governed by a BSD-style license that can be
3# found in the LICENSE file.
4
5DESTDIR ?= target
6LOCALDESTDIR=$(shell readlink -f local-install)
Dennis Kempin407627c2013-02-12 11:06:40 -08007OVERLAY=../../third_party/chromiumos-overlay/
Chung-yih Wang2d148e42013-02-26 14:17:26 +08008
Che-Liang Chiou2254c362013-04-01 18:23:29 -07009export DESTDIR
10
Dennis Kempin407627c2013-02-12 11:06:40 -080011all: framework
Dennis Kempin31c0fbd2012-07-30 13:20:37 -070012
13clean:
Chung-yih Wang2d148e42013-02-26 14:17:26 +080014 $(MAKE) -C framework clean
Dennis Kempin31c0fbd2012-07-30 13:20:37 -070015
Dennis Kempin31c0fbd2012-07-30 13:20:37 -070016framework:
Chung-yih Wang2d148e42013-02-26 14:17:26 +080017 $(MAKE) -C framework all
Dennis Kempin31c0fbd2012-07-30 13:20:37 -070018
19tests:
Chung-yih Wang2d148e42013-02-26 14:17:26 +080020 $(MAKE) -C framework tests
Dennis Kempin31c0fbd2012-07-30 13:20:37 -070021
22install:
23 mkdir -p $(DESTDIR)
Chung-yih Wang2d148e42013-02-26 14:17:26 +080024 $(MAKE) -C framework install
Dennis Kempin31c0fbd2012-07-30 13:20:37 -070025
26 install -D touchtests $(DESTDIR)/touchtests
27
28 # for each filetype in tests folder
Dennis Kempin31c0fbd2012-07-30 13:20:37 -070029 for extension in dat props log py ; do \
30 find tests \( -iname \*.$$extension ! -wholename \*/.\* ! -wholename \
31 \*/:\* \) -exec install -D -m 0755 \{\} $(DESTDIR)/\{\} \; ; \
32 done
33
Dennis Kempinf6144e62013-02-22 12:51:59 -080034setup-in-place:
Chung-yih Wang2d148e42013-02-26 14:17:26 +080035 OUT=. $(MAKE) -C ../mttools setup-in-place
Dennis Kempinf6144e62013-02-22 12:51:59 -080036
37 # Create local-install folder with links to
Dennis Kempin31c0fbd2012-07-30 13:20:37 -070038 # original folders. So there is no need to reinstall after changes.
39 install -D touchtests $(LOCALDESTDIR)/touchtests
40
Dennis Kempin407627c2013-02-12 11:06:40 -080041 ln -sfn ../framework/src local-install/framework
42 ln -sfn ../tests local-install/tests
Dennis Kempin31c0fbd2012-07-30 13:20:37 -070043 ln -sf $(LOCALDESTDIR)/touchtests /usr/bin/touchtests
44
Dennis Kempinf6144e62013-02-22 12:51:59 -080045in-place:
Chung-yih Wang2d148e42013-02-26 14:17:26 +080046 OUT=. $(MAKE) -C ../mttools in-place
Dennis Kempinf6144e62013-02-22 12:51:59 -080047
48clean-in-place:
Chung-yih Wang2d148e42013-02-26 14:17:26 +080049 OUT=. $(MAKE) -C ../mttools clean-in-place
Dennis Kempin72bc9d42013-01-22 11:33:46 -080050
Dennis Kempin407627c2013-02-12 11:06:40 -080051.PHONY: all clean framework tests install local-install