mirror of
https://git.yoctoproject.org/poky
synced 2026-05-30 00:20:08 +00:00
recipetool: create: add basic support for extracting dependencies from cmake
Add support for extracting dependencies from CMakeLists.txt. There's still a bunch of things missing that are outside the scope of OE-Core and we still lack a proper extension mechanism, but this is a good start. This also adds an oe-selftest test to exercise the new code a bit. Implements [YOCTO #7635]. (From OE-Core rev: 77e73e6930381fdbd6e78d3913d6467572e16568) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
3eb397fab6
commit
2c8c9fe3b4
@@ -422,6 +422,23 @@ class RecipetoolTests(RecipetoolBase):
|
||||
inherits = ['autotools']
|
||||
self._test_recipe_contents(os.path.join(temprecipe, dirlist[0]), checkvars, inherits)
|
||||
|
||||
def test_recipetool_create_cmake(self):
|
||||
# Try adding a recipe
|
||||
temprecipe = os.path.join(self.tempdir, 'recipe')
|
||||
os.makedirs(temprecipe)
|
||||
recipefile = os.path.join(temprecipe, 'navit_0.5.0.bb')
|
||||
srcuri = 'http://downloads.sourceforge.net/project/navit/v0.5.0/navit-0.5.0.tar.gz'
|
||||
result = runCmd('recipetool create -o %s %s' % (temprecipe, srcuri))
|
||||
self.assertTrue(os.path.isfile(recipefile))
|
||||
checkvars = {}
|
||||
checkvars['LICENSE'] = set(['Unknown', 'GPLv2', 'LGPLv2'])
|
||||
checkvars['SRC_URI'] = 'http://downloads.sourceforge.net/project/navit/v${PV}/navit-${PV}.tar.gz'
|
||||
checkvars['SRC_URI[md5sum]'] = '242f398e979a6b8c0f3c802b63435b68'
|
||||
checkvars['SRC_URI[sha256sum]'] = '13353481d7fc01a4f64e385dda460b51496366bba0fd2cc85a89a0747910e94d'
|
||||
checkvars['DEPENDS'] = set(['freetype', 'zlib', 'openssl', 'glib-2.0', 'virtual/libgl', 'virtual/egl', 'gtk+', 'libpng', 'libsdl', 'freeglut', 'dbus-glib'])
|
||||
inherits = ['cmake', 'python-dir', 'gettext', 'pkgconfig']
|
||||
self._test_recipe_contents(recipefile, checkvars, inherits)
|
||||
|
||||
class RecipetoolAppendsrcBase(RecipetoolBase):
|
||||
def _try_recipetool_appendsrcfile(self, testrecipe, newfile, destfile, options, expectedlines, expectedfiles):
|
||||
cmd = 'recipetool appendsrcfile %s %s %s %s %s' % (options, self.templayerdir, testrecipe, newfile, destfile)
|
||||
|
||||
Reference in New Issue
Block a user