forked from pool/docker
Accepting request 311406 from home:jordimassaguerpla:branches:Virtualization:containers
Remove unneeded dependencies: * go-go-md2man: this is required to build the man pages. * systemd-devel: this was a build time dependency required to have some directories inside of the build root Exclude the whole "/usr/src/docker/bundles" directory from the final package. OBS-URL: https://build.opensuse.org/request/show/311406 OBS-URL: https://build.opensuse.org/package/show/Virtualization:containers/docker?expand=0&rev=11
This commit is contained in:
parent
9017ee55c3
commit
84f28f19ef
@ -19,7 +19,7 @@ Index: docker/hack/make/.dockerinit
|
|||||||
===================================================================
|
===================================================================
|
||||||
--- docker.orig/hack/make/.dockerinit
|
--- docker.orig/hack/make/.dockerinit
|
||||||
+++ docker/hack/make/.dockerinit
|
+++ docker/hack/make/.dockerinit
|
||||||
@@ -25,5 +25,7 @@ else
|
@@ -29,5 +29,7 @@
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@ -4,3 +4,11 @@ addFilter ("^docker.x86_64: W: statically-linked-binary /usr/lib/docker/dockerin
|
|||||||
addFilter ("^docker.x86_64: W: unstripped-binary-or-object /usr/lib/docker/dockerinit")
|
addFilter ("^docker.x86_64: W: unstripped-binary-or-object /usr/lib/docker/dockerinit")
|
||||||
addFilter ("^docker.x86_64: W: no-manual-page-for-binary docker")
|
addFilter ("^docker.x86_64: W: no-manual-page-for-binary docker")
|
||||||
addFilter ("^docker.x86_64: W: no-manual-page-for-binary nsinit")
|
addFilter ("^docker.x86_64: W: no-manual-page-for-binary nsinit")
|
||||||
|
addFilter ("test.noarch.*: E: devel-file-in-non-devel-package")
|
||||||
|
addFilter ("test.noarch.*: W: pem-certificate")
|
||||||
|
addFilter ("test.noarch.*: W: non-executable-script")
|
||||||
|
addFilter ("test.noarch.*: W: hidden-file-or-dir")
|
||||||
|
addFilter ("test.noarch.*: W: files-duplicate")
|
||||||
|
addFilter ("test.noarch.*: W: script-without-shebang /usr/src/docker/docs/README.md")
|
||||||
|
addFilter ("test.noarch.*: W: sourced-script-with-shebang /etc/bash_completion.d/docker bash")
|
||||||
|
addFilter ("test.noarch.*: W: suse-filelist-forbidden-fhs23 /usr/src/docker")
|
||||||
|
@ -1,3 +1,8 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Jun 9 16:35:46 UTC 2015 - jmassaguerpla@suse.com
|
||||||
|
|
||||||
|
- Add test subpackage and fix line numbers in patches
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Fri Jun 5 15:29:45 UTC 2015 - fcastelli@suse.com
|
Fri Jun 5 15:29:45 UTC 2015 - fcastelli@suse.com
|
||||||
|
|
||||||
|
41
docker.spec
41
docker.spec
@ -109,6 +109,27 @@ BuildArch: noarch
|
|||||||
%description zsh-completion
|
%description zsh-completion
|
||||||
Zsh command line completion support for %{name}.
|
Zsh command line completion support for %{name}.
|
||||||
|
|
||||||
|
%package test
|
||||||
|
Summary: Test package for docker
|
||||||
|
Group: System/Management
|
||||||
|
Requires: device-mapper-devel >= 1.2.68
|
||||||
|
Requires: glibc-devel-static
|
||||||
|
%ifarch ppc ppc64 s390x ppc64p7 ppc64le
|
||||||
|
Requires: gcc5-go >= 5.0
|
||||||
|
%else
|
||||||
|
Requires: go >= 1.3
|
||||||
|
%endif
|
||||||
|
Requires: apparmor-parser
|
||||||
|
Requires: bash-completion
|
||||||
|
Requires: libapparmor-devel
|
||||||
|
Requires: libbtrfs-devel >= 3.8
|
||||||
|
Requires: procps
|
||||||
|
Requires: sqlite3-devel
|
||||||
|
BuildArch: noarch
|
||||||
|
|
||||||
|
%description test
|
||||||
|
Test package for docker. It contains the source code and the tests.
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n docker
|
%setup -q -n docker
|
||||||
%patch0 -p1
|
%patch0 -p1
|
||||||
@ -126,11 +147,23 @@ ln -s /usr/bin/go-5 /tmp/dirty-hack/go
|
|||||||
export PATH=/tmp/dirty-hack:$PATH
|
export PATH=/tmp/dirty-hack:$PATH
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
|
(cat <<EOF
|
||||||
export AUTO_GOPATH=1
|
export AUTO_GOPATH=1
|
||||||
export DOCKER_BUILDTAGS="exclude_graphdriver_aufs apparmor selinux"
|
export DOCKER_BUILDTAGS="exclude_graphdriver_aufs apparmor selinux"
|
||||||
export DOCKER_GITCOMMIT=%{git_version}
|
export DOCKER_GITCOMMIT=%{git_version}
|
||||||
|
EOF
|
||||||
|
) > docker_build_env
|
||||||
|
. ./docker_build_env
|
||||||
./hack/make.sh dynbinary
|
./hack/make.sh dynbinary
|
||||||
docs/man/md2man-all.sh
|
docs/man/md2man-all.sh
|
||||||
|
# remove git files
|
||||||
|
find . -name ".gitignore" | xargs rm
|
||||||
|
# remove other than systemd
|
||||||
|
# otherwise the resulting package will have extra requires
|
||||||
|
rm -rf contrib/init/openrc
|
||||||
|
rm -rf contrib/init/sysvinit-debian
|
||||||
|
rm -rf contrib/init/sysvinit-redhat
|
||||||
|
rm -rf contrib/init/upstart
|
||||||
|
|
||||||
%install
|
%install
|
||||||
install -d %{buildroot}%{go_contribdir}
|
install -d %{buildroot}%{go_contribdir}
|
||||||
@ -144,6 +177,9 @@ install -Dd -m 0755 \
|
|||||||
|
|
||||||
install -D -m0644 contrib/completion/bash/docker "%{buildroot}/etc/bash_completion.d/%{name}"
|
install -D -m0644 contrib/completion/bash/docker "%{buildroot}/etc/bash_completion.d/%{name}"
|
||||||
install -D -m0644 contrib/completion/zsh/_docker "%{buildroot}/etc/zsh_completion.d/%{name}"
|
install -D -m0644 contrib/completion/zsh/_docker "%{buildroot}/etc/zsh_completion.d/%{name}"
|
||||||
|
# copy all for the test package
|
||||||
|
install -d %{buildroot}/usr/src/docker/
|
||||||
|
cp -av . %{buildroot}/usr/src/docker/
|
||||||
|
|
||||||
#
|
#
|
||||||
# systemd service
|
# systemd service
|
||||||
@ -210,4 +246,9 @@ groupadd -r docker 2>/dev/null || :
|
|||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
%config %{_sysconfdir}/zsh_completion.d/%{name}
|
%config %{_sysconfdir}/zsh_completion.d/%{name}
|
||||||
|
|
||||||
|
%files test
|
||||||
|
%defattr(-,root,root)
|
||||||
|
/usr/src/docker/
|
||||||
|
%exclude /usr/src/docker/bundles/
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
@ -2,7 +2,7 @@ Index: docker/utils/utils.go
|
|||||||
===================================================================
|
===================================================================
|
||||||
--- docker.orig/utils/utils.go
|
--- docker.orig/utils/utils.go
|
||||||
+++ docker/utils/utils.go
|
+++ docker/utils/utils.go
|
||||||
@@ -111,7 +111,7 @@ func isValidDockerInitPath(target string
|
@@ -110,7 +110,7 @@
|
||||||
}
|
}
|
||||||
return os.SameFile(targetFileInfo, selfPathFileInfo)
|
return os.SameFile(targetFileInfo, selfPathFileInfo)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user