-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add pack-handle codes for generating deb package. (#138)
- Loading branch information
Showing
3 changed files
with
84 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
PKG_NAME := testkit-lite | ||
SPECFILE = $(addsuffix .spec, $(PKG_NAME)) | ||
PKG_VERSION := $(shell grep '^Version: ' $(SPECFILE)|awk '{print $$2}') | ||
|
||
TARBALL := $(PKG_NAME)_$(PKG_VERSION).tar.gz | ||
|
||
dsc: $(TARBALL) | ||
$(eval MD5=$(shell md5sum $(TARBALL) | sed "s/ / $(shell stat -c '%s' $(TARBALL)) /")) | ||
@sed -i 's/^Version:.*/Version: $(PKG_VERSION)/' $(PKG_NAME).dsc | ||
@sed -i 's/ [a-f0-9]\+ [0-9]\+ $(PKG_NAME).*tar.*/ $(MD5)/' $(PKG_NAME).dsc | ||
|
||
$(TARBALL): | ||
cd "$$(git rev-parse --show-toplevel)" \ | ||
&& git archive --prefix $(PKG_NAME)-$(PKG_VERSION)/ HEAD \ | ||
| gzip > "$(CURDIR)/$(TARBALL)" | ||
|
||
clean: | ||
rm -f $(PKG_NAME)*.tar.gz | ||
|
||
all: clean dsc | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
Source: testkit-lite | ||
Section: utils | ||
Priority: standard | ||
Maintainer: Bruce Dai <feng.dai@intel.com> | ||
Build-Depends: debhelper (>= 8.0.0), python-setuptools, python-support (>= 0.8.4) | ||
Standards-Version: 3.9.2 | ||
Homepage: https://github.com/testkit/testkit-lite | ||
Version: 3.1.18 | ||
Files: | ||
15082459086308f1b4f188e7833cabcf6255efd5 1398131 testkit-lite_3.1.18.tar.gz | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
Summary: TCT-Lite | ||
Name: testkit-lite | ||
Version: 3.1.18 | ||
Release: 1 | ||
License: GPLv2 | ||
Group: Applications/System | ||
Source: %{name}_%{version}.tar.gz | ||
|
||
BuildRequires: python-distribute | ||
|
||
%{!?python_sitelib: %define python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} | ||
|
||
%description | ||
testkit-lite is a test runner with command-line interface.It has the following functions | ||
1. Accepts .xml test case descriptor files as input. | ||
2. drives automatic test execution. | ||
3. provide multiple options to meet various test requirements. | ||
|
||
%prep | ||
%setup -q | ||
|
||
%build | ||
|
||
%install | ||
python setup.py install --prefix=%{_prefix} --root=%{buildroot} | ||
# remove tests | ||
rm -rf %{buildroot}/%{python_sitelib}/tests | ||
|
||
%clean | ||
rm -rf %{buildroot} | ||
|
||
%post | ||
# Set permissions | ||
chmod ugo+rwx /opt/testkit/lite | ||
|
||
%files | ||
%{python_sitelib}/testkitlite/* | ||
%{python_sitelib}/testkit_lite-*.egg-info/* | ||
/etc/dbus-1/system.d/com.intel.testkit.conf | ||
/opt/testkit/lite/VERSION | ||
/opt/testkit/lite/commodule/CONFIG | ||
/opt/testkit/lite/mh.html | ||
%{_bindir}/testkit-lite | ||
%{_bindir}/testkit-lite-dbus | ||
%defattr(-,root,root) | ||
|
||
%doc | ||
/opt/testkit/lite/testkit-lite_user_guide.pdf | ||
/opt/testkit/lite/testkit-lite_tutorial.pdf | ||
/opt/testkit/lite/test_definition_schema.pdf | ||
|
||
%changelog |