#3 Update to 1.1.0
Merged 4 years ago by lon. Opened 4 years ago by lyarwood.
rpms/ lyarwood/novnc rebase-1.1.0  into  master

file modified
+1
@@ -3,3 +3,4 @@ 

  /v0.5.1.tar.gz

  /v0.6.1.tar.gz

  /v1.0.0.tar.gz

+ /v1.1.0.tar.gz

file modified
+26 -20
@@ -1,15 +1,16 @@ 

  Name:           novnc

- Version:        1.0.0

- Release:        2%{?dist}

+ Version:        1.1.0

+ Release:        1%{?dist}

  Summary:        VNC client using HTML5 (Web Sockets, Canvas) with encryption support

- Requires:       python2-websockify

+ Requires:       python3-websockify

  

  License:        GPLv3

  URL:            https://github.com/novnc/noVNC

  Source0:        https://github.com/novnc/noVNC/archive/v%{version}.tar.gz

  

  BuildArch:      noarch

- BuildRequires:  python2-devel

+ BuildRequires:  python3-devel

+ BuildRequires: /usr/bin/pathfix.py

  

  %description

  noVNC is both a HTML VNC client JavaScript library and an application built on
@@ -19,36 +20,41 @@ 

  %prep

  %setup -q -n noVNC-%{version}

  

- %build

+ # Fix any python shebangs within the novnc codebase

+ # https://fedoraproject.org/wiki/Changes/Make_ambiguous_python_shebangs_error

+ pathfix.py -pni "%{__python3} %{py3_shbang_opts}" .

  

+ %build

  

  %install

- mkdir -p %{buildroot}/%{_usr}/share/novnc/utils

- install -m 444 *html %{buildroot}/%{_usr}/share/novnc

- #provide an index file to prevent default directory browsing

- install -m 444 vnc.html %{buildroot}/%{_usr}/share/novnc/index.html

- mkdir -p %{buildroot}/%{_bindir}

- install utils/launch.sh  %{buildroot}/%{_bindir}/novnc_server

+ mkdir -p %{buildroot}/%{_datadir}/%{name}/

+ cp -r * %{buildroot}/%{_datadir}/%{name}/

+ 

+ # provide an index file to prevent default directory browsing

+ install -m 444 vnc.html %{buildroot}/%{_datadir}/%{name}/index.html

  

- %{__install} -d %{buildroot}%{_sysconfdir}/sysconfig

+ # install a copy of the new vnc_lite.html page as the old <1.0.0 vnc_auto.html page

+ install -m 444 vnc_lite.html %{buildroot}/%{_datadir}/%{name}/vnc_auto.html

  

- %post

- #symlink the <1.0.0 vnc_auto.html page to the new >=1.0.0 vnc_lite.html page.

- ln -s -f %{_usr}/share/novnc/vnc_lite.html %{_usr}/share/novnc/vnc_auto.html

+ # FIXME(lyarwood): launch.sh fails to find the installed version of websockify

+ # Addressed by https://github.com/novnc/noVNC/pull/1259 

+ mkdir -p %{buildroot}/%{_bindir}/

+ install utils/launch.sh  %{buildroot}/%{_bindir}/%{name}_server

  

  %files

  %doc README.md LICENSE.txt

- 

- %dir %{_usr}/share/novnc

- %{_usr}/share/novnc/*.*

- %{_bindir}/novnc_server

+ %{_datadir}/%{name}

+ %{_bindir}/%{name}_server

  

  %changelog

+ * Fri Jul 05 2019 Lee Yarwood <lyarwood@redhat.com> - 1.1.0-1

+ - Update to 1.1.0

+ 

  * Fri Feb 01 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.0-2

  - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild

  

  * Thu Aug 02 2018 Lee Yarwood <lyarwood@redhat.com> - 1.0.0-1

-   Update to 1.0.0

+ - Update to 1.0.0

  

  * Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.6.1-6

  - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild

file modified
+1 -1
@@ -1,1 +1,1 @@ 

- SHA512 (v1.0.0.tar.gz) = 97a86be5f10f382e2ed641360f5f6c3b22998f68f980c78138aca900ef6a011c1f6aa9cbdd8cd07afd4884e8c65af30d65487e87bb34e524c10f16cf4cd116a3

+ SHA512 (v1.1.0.tar.gz) = 9c736912f5a3051027efe779fc64b182f523b9378ff412d78202e52665772678846d97fe3cc5ac18f5c29dd83d5ff2a2dd915e5eadf9af3573fe871db2e7821e

Rebase to 1.1.0, replace python shebangs and rework %install to include all of the required files under /usr/share/novnc.

You may want to have (but probably don't):

Suggests: python3-pillow
Suggests: python3-matplotlib
Suggests: python3-numpy

This is because the included python files reference them - however... maybe not? It doesn't seem to be a regression.

Instead of %{_usr}/share, you can (and probably should) use:

%{_datadir}

Your symlink for launch.sh was wrong:

ln -s -f %{_usr}/%{bindir}/novnc_server %{_usr}/share/novnc/utils/launch.sh

... should be:

ln -s -f %{_bindir}/novnc/utils/launch.sh %{_bindir}/novnc_server

Your patch deleted %{_bindir}/novnc_server as well - you might want to put that back. This is probably because you create this symlink in %post instead of during the build/install. However, because %{_bindir}/novnc_server is not owned by the novnc package, the symlink was left around after 'rpm -e' on my system.

I think we should probably create both symlinks during installation rather than in %post.

An example spec file with the changes is here:

https://bugzilla.redhat.com/attachment.cgi?id=1588558

rebased onto a16fa3f

4 years ago

You may want to have (but probably don't):
Suggests: python3-pillow
Suggests: python3-matplotlib
Suggests: python3-numpy
This is because the included python files reference them - however... maybe not? It doesn't seem to be a regression.

Yeah I don't think these are required by the client or server, just some utility scripts. I'm not going to include them for now.

Instead of %{_usr}/share, you can (and probably should) use:
%{_datadir}

Done.

Your symlink for launch.sh was wrong:
ln -s -f %{_usr}/%{bindir}/novnc_server %{_usr}/share/novnc/utils/launch.sh
... should be:
ln -s -f %{_bindir}/novnc/utils/launch.sh %{_bindir}/novnc_server

Ouch, I thought I had corrected that before pushing, thanks!

Your patch deleted %{_bindir}/novnc_server as well - you might want to put that back. This is probably because you create this symlink in %post instead of during the build/install. However, because %{_bindir}/novnc_server is not owned by the novnc package, the symlink was left around after 'rpm -e' on my system.
I think we should probably create both symlinks during installation rather than in %post.
An example spec file with the changes is here:
https://bugzilla.redhat.com/attachment.cgi?id=1588558

That was due to an issue I encountered with the current launch.sh script while it attempts to find a local websockify install. I've published the following PR for noVNC to correct this:

launch.sh: Check for a local websockify directory
https://github.com/novnc/noVNC/pull/1259

I've left a FIXME note in the latest commit to manually correct this ahead of any 1.2.0 release.

Pull-Request has been merged by lon

4 years ago