3 # Copyright (c) 2010 Google Inc. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file.
8 Verifies that .so files that are order only dependencies are specified by
9 their install location rather than by their alias.
12 # Python 2.5 needs this for the with statement.
13 from __future__ import with_statement
18 test = TestGyp.TestGyp(formats=['make'])
20 test.run_gyp('shared_dependency.gyp',
22 test.relocate('src', 'relocate/src')
24 test.build('shared_dependency.gyp', test.ALL, chdir='relocate/src')
26 with open('relocate/src/Makefile') as makefile:
27 make_contents = makefile.read()
29 # If we remove the code to generate lib1, Make should still be able
30 # to build lib2 since lib1.so already exists.
31 make_contents = make_contents.replace('include lib1.target.mk', '')
32 with open('relocate/src/Makefile', 'w') as makefile:
33 makefile.write(make_contents)
35 test.build('shared_dependency.gyp', test.ALL, chdir='relocate/src')