Skip to content
Permalink
Browse files

Updating spec to use `make prepare-release` to create binaries (#2283)

Signed-off-by: Mohammed Zeeshan Ahmed <mohammed.zee1000@gmail.com>
  • Loading branch information...
mohammedzee1000 authored and openshift-merge-robot committed Oct 15, 2019
1 parent b1fbd55 commit f439087dd98efc9f199caa235d974d3ec645dc7a
Showing with 16 additions and 11 deletions.
  1. +16 −11 rpms/openshift-odo.spec
@@ -40,18 +40,21 @@ ln -s "$(pwd)" %{gopath}/src/github.com/openshift/odo
export GOPATH=%{gopath}
cd %{gopath}/src/github.com/openshift/odo
make test
make cross
make prepare-release
unlink %{gopath}/src/github.com/openshift/odo
rm -rf %{gopath}

%install
mkdir -p %{buildroot}/%{_bindir}
install -m 0755 dist/bin/linux-amd64/odo %{buildroot}%{_bindir}/odo
mkdir -p %{buildroot}%{_datadir}
install -d %{buildroot}%{_datadir}/%{name}-redistributable/{linux,macos,windows}
install -p -m 755 dist/bin/linux-amd64/odo %{buildroot}%{_datadir}/%{name}-redistributable/linux/odo-linux-amd64
install -p -m 755 dist/bin/darwin-amd64/odo %{buildroot}%{_datadir}/%{name}-redistributable/macos/odo-darwin-amd64
install -p -m 755 dist/bin/windows-amd64/odo.exe %{buildroot}%{_datadir}/%{name}-redistributable/windows/odo-windows-amd64.exe
install -d %{buildroot}%{_datadir}/%{name}-redistributable
install -p -m 755 dist/release/odo-linux-amd64 %{buildroot}%{_datadir}/%{name}-redistributable/odo-linux-amd64
install -p -m 755 dist/release/odo-darwin-amd64 %{buildroot}%{_datadir}/%{name}-redistributable/odo-darwin-amd64
install -p -m 755 dist/release/odo-windows-amd64.exe %{buildroot}%{_datadir}/%{name}-redistributable/odo-windows-amd64.exe
cp -avrf dist/release/odo*.tar.gz %{buildroot}%{_datadir}/%{name}-redistributable
cp -avrf dist/release/SHA256_SUM %{buildroot}%{_datadir}/%{name}-redistributable


%files
%license LICENSE
@@ -69,10 +72,12 @@ Obsoletes: %{package_name}-redistributable

%files redistributable
%license LICENSE
%dir %{_datadir}/%{name}-redistributable/linux/
%dir %{_datadir}/%{name}-redistributable/macos/
%dir %{_datadir}/%{name}-redistributable/windows/
%{_datadir}/%{name}-redistributable/linux/odo-linux-amd64
%{_datadir}/%{name}-redistributable/macos/odo-darwin-amd64
%{_datadir}/%{name}-redistributable/windows/odo-windows-amd64.exe
%dir %{_datadir}/%{name}-redistributable
%{_datadir}/%{name}-redistributable/odo-linux-amd64
%{_datadir}/%{name}-redistributable/odo-linux-amd64.tar.gz
%{_datadir}/%{name}-redistributable/odo-darwin-amd64
%{_datadir}/%{name}-redistributable/odo-darwin-amd64.tar.gz
%{_datadir}/%{name}-redistributable/odo-windows-amd64.exe
%{_datadir}/%{name}-redistributable/odo-windows-amd64.exe.tar.gz
%{_datadir}/%{name}-redistributable/SHA256_SUM

0 comments on commit f439087

Please sign in to comment.
You can’t perform that action at this time.