Skip to content

Commit

Permalink
Building HTX with only needed exercisers
Browse files Browse the repository at this point in the history
Some exercisers like hxecapi, hxeocapi, hxedapl have dependent
library packages, which are not available in some distros. To
handle it, we are ignoring those packages during HTX compilation

Adopted from io/net/htx_nic_devices.py

Signed-off-by: Harish <[email protected]>
  • Loading branch information
Harish committed May 9, 2019
1 parent b739388 commit 3f93c78
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions generic/htx_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,11 +53,12 @@ def setUp(self):

packages = ['git', 'gcc', 'make']
if detected_distro.name in ['centos', 'fedora', 'rhel', 'redhat']:
packages.extend(['gcc-c++', 'ncurses-devel',
'dapl-devel', 'libcxl-devel'])
packages.extend(['gcc-c++', 'ncurses-devel', 'tar'])
elif detected_distro.name == "Ubuntu":
packages.extend(['libncurses5', 'g++', 'libdapl-dev',
'ncurses-dev', 'libncurses-dev', 'libcxl-dev'])
packages.extend(['libncurses5', 'g++',
'ncurses-dev', 'libncurses-dev'])
elif detected_distro.name == 'SuSE':
packages.extend(['libncurses5', 'gcc-c++', 'ncurses-devel', 'tar'])
else:
self.cancel("Test not supported in %s" % detected_distro.name)

Expand All @@ -72,6 +73,11 @@ def setUp(self):
htx_path = os.path.join(self.teststmpdir, "HTX-master")
os.chdir(htx_path)

exercisers = ["hxecapi_afu_dir", "hxedapl", "hxecapi", "hxeocapi"]
for exerciser in exercisers:
process.run("sed -i 's/%s//g' %s/bin/Makefile" % (exerciser,
htx_path))

build.make(htx_path, extra_args='all')
build.make(htx_path, extra_args='tar')
process.run('tar --touch -xvzf htx_package.tar.gz')
Expand Down

0 comments on commit 3f93c78

Please sign in to comment.