Renamed find_dep to dependency.

This commit is contained in:
Jussi Pakkanen 2013-06-02 14:06:43 +03:00
parent d4284aae89
commit 11e81618d2
8 changed files with 13 additions and 13 deletions

View File

@ -616,7 +616,7 @@ class Interpreter():
self.funcs = {'project' : self.func_project,
'message' : self.func_message,
'executable': self.func_executable,
'find_dep' : self.func_find_dep,
'dependency' : self.func_dependency,
'static_library' : self.func_static_lib,
'shared_library' : self.func_shared_lib,
'generator' : self.func_generator,
@ -795,7 +795,7 @@ class Interpreter():
raise InvalidArguments('External library "%s" not found.' % libname)
return libobj
def func_find_dep(self, node, args, kwargs):
def func_dependency(self, node, args, kwargs):
self.validate_arguments(args, 1, [str])
name = args[0]
identifier = dependencies.get_dep_identifier(name, kwargs)

View File

@ -4,8 +4,8 @@ project('boosttest', 'cxx')
# within one project. The need to be independent of each other.
# Use one without a library dependency and one with it.
nolinkdep = find_dep('boost', modules: 'utility')
linkdep = find_dep('boost', modules : 'thread')
nolinkdep = dependency('boost', modules: 'utility')
linkdep = dependency('boost', modules : 'thread')
nolinkexe = executable('nolinkedexe', 'nolinkexe.cc', deps : nolinkdep)
linkexe = executable('linkedexe', 'linkexe.cc', deps : linkdep)

View File

@ -1,6 +1,6 @@
project('gtest', 'cxx')
gtest = find_dep('gtest')
gtest = dependency('gtest')
e = executable('testprog', 'test.cc', deps : gtest)
test('gtest test', e)

View File

@ -3,8 +3,8 @@ project('gmock test', 'cxx')
# Using gmock without gtest is a pain so just
# don't support that then.
gtest = find_dep('gtest')
gmock = find_dep('gmock')
gtest = dependency('gtest')
gmock = dependency('gmock')
e = executable('gmocktest', 'gmocktest.cc', deps : [gtest, gmock])
test('gmock test', e)

View File

@ -1,6 +1,6 @@
project('qt5 build test', 'cxx')
qt5dep = find_dep('qt5', modules : 'Widgets')
qt5dep = dependency('qt5', modules : 'Widgets')
q5exe = executable('qt5test',
sources : ['main.cpp', 'mainWindow.cpp'], # Sources that don't need preprocessing.

View File

@ -1,7 +1,7 @@
project('protocol buffer test', 'cxx')
protoc = find_program('protoc')
dep = find_dep('protobuf')
dep = dependency('protobuf')
gen = generator(protoc, \
outputs : ['@BASENAME@.pb.cc', '@BASENAME@.pb.h'],

View File

@ -2,11 +2,11 @@ project('external dependency', 'c')
# Zlib is probably on all dev machines.
dep = find_dep('zlib')
dep = dependency('zlib')
exe = executable('zlibprog', 'prog.c', deps : dep)
test('zlibtest', exe)
# Try to find a nonexistant library to ensure requires:false works.
dep = find_dep('nvakuhrabnsdfasdf', required : false)
dep = dependency('nvakuhrabnsdfasdf', required : false)

View File

@ -1,9 +1,9 @@
project('nsstring', 'objc')
if host.name() == 'darwin'
dep = find_dep('appleframeworks', modules : 'foundation')
dep = dependency('appleframeworks', modules : 'foundation')
else
dep = find_dep('gnustep')
dep = dependency('gnustep')
endif
exe = executable('stringprog', 'stringprog.m', deps : dep)
test('stringtest', exe)