Skip to content
This repository has been archived by the owner on Jan 15, 2019. It is now read-only.

[dev.icinga.com #1266] Some files have wrong/missing Shebangs #333

Closed
icinga-migration opened this issue Mar 4, 2011 · 10 comments
Closed

Comments

@icinga-migration
Copy link

This issue has been migrated from Redmine: https://dev.icinga.com/issues/1266

Created by theh on 2011-03-04 07:59:46 +00:00

Assignee: mhein
Status: Resolved (closed on 2011-10-11 13:18:02 +00:00)
Target Version: 1.6
Last Update: 2011-12-03 11:30:10 +00:00 (in Redmine)


Rpmlint has complained that several files have wrong or missing shebangs and one is a Windows file.

Wrong shebang (for example "#/bin/bash"):

icinga-web-1.3.0/bin/phing
icinga-web-1.3.0/bin/loc-create-mo.sh

Missing shebang

icinga-web-1.3.0/bin/getopts.php
icinga-web-1.3.0/bin/create-rescuescheme.sh
icinga-web-1.3.0/bin/console.php
(icinga-web-1.3.0/etc/tests/icingaWebTesting.php)

Windows file:

icinga-web-1.3.0/lib/agavi/bin/agavi.bat-dist

Attachments

Changesets

2011-10-11 13:15:39 +00:00 by mhein 33526b3

* Persmissions changed (fixes #1266)
* Remived unused dist binaries (fixes #1266)
@icinga-migration
Copy link
Author

Updated by mjbrooks on 2011-05-08 21:29:43 +00:00

Just trolling around the issue system and noticed this.

This was addressed on 2011-04-14 by Jannis in 57de214

@icinga-migration
Copy link
Author

Updated by theh on 2011-05-19 14:08:51 +00:00

There are still some remaining issues according to rpmlint. It would be great if this could be cleaned upstream so no extra patches are needed.

RPMLINT report:

icinga-web.noarch: W: hidden-file-or-dir /usr/share/icinga-web/lib/jsgettext/doc/html/.#Gettext.html.1.4
icinga-web.noarch: W: hidden-file-or-dir /usr/share/icinga-web/lib/jsgettext/doc/pod/.#Gettext.pod.1.3
icinga-web.noarch: W: hidden-file-or-dir /usr/share/icinga-web/lib/jsgettext/doc/text/.#Gettext.text.1.3
The file or directory is hidden. You should see if this is normal, and delete
it from the package if not.

icinga-web.noarch: W: script-without-shebang /usr/share/icinga-web/lib/agavi/bin/agavi.bat-dist
icinga-web.noarch: W: script-without-shebang /usr/share/icinga-web/etc/tests/icingaWebTesting.php
icinga-web.noarch: W: script-without-shebang /usr/share/icinga-web/pub/styles/icinga.site.css
This text file has executable bits set or is located in a path dedicated for
executables, but lacks a shebang and cannot thus be executed. If the file is
meant to be an executable script, add the shebang, otherwise remove the
executable bits or move the file elsewhere.

icinga-web.noarch: W: wrong-script-end-of-line-encoding /usr/share/icinga-web/lib/agavi/bin/agavi.bat-dist
This script has wrong end-of-line encoding, usually caused by creation or
modification on a non-Unix system. It will prevent its execution.

@icinga-migration
Copy link
Author

Updated by theh on 2011-05-19 15:40:59 +00:00

  • File added icinga-web-missing-shebang.patch

This patch fixes the icingaWebTesting.php and agavi.bat-dist issue.

Icinga.site.css seems to be a problem in the installation script but I haven't checked it yet.

I don't know if the Gettext files are needed so someone else has to check that.

@icinga-migration
Copy link
Author

Updated by theh on 2011-06-08 13:39:34 +00:00

Here are some additional rpmlint warnings:

RPMLINT report:

icinga-web.noarch: W: hidden-file-or-dir /usr/share/icinga-web/lib/jsgettext/doc/html/.#Gettext.html.1.4
icinga-web.noarch: W: hidden-file-or-dir /usr/share/icinga-web/lib/jsgettext/doc/pod/.#Gettext.pod.1.3
icinga-web.noarch: W: hidden-file-or-dir /usr/share/icinga-web/lib/jsgettext/doc/text/.#Gettext.text.1.3
The file or directory is hidden. You should see if this is normal, and delete
it from the package if not.

icinga-web.noarch: W: non-executable-script /usr/share/icinga-web/lib/agavi/bin/agavi.bat-dist 0644
icinga-web.noarch: W: non-executable-script /usr/share/icinga-web/lib/jsgettext/bin/po2json 0644
icinga-web.noarch: W: non-executable-script /usr/share/icinga-web/lib/agavi/bin/agavi 0644
icinga-web.noarch: W: non-executable-script /usr/share/icinga-web/etc/tests/icingaWebTesting.php 0644
icinga-web.noarch: W: non-executable-script /usr/share/icinga-web/lib/agavi/bin/agavi-dist 0644
icinga-web.noarch: W: non-executable-script /usr/share/icinga-web/lib/phing/bin/phing 0644
icinga-web.noarch: W: non-executable-script /usr/share/icinga-web/lib/agavi/src/build/agavi/script/agavi.php 0644
This text file contains a shebang or is located in a path dedicated for
executables, but lacks the executable bits and cannot thus be executed. If
the file is meant to be an executable script, add the executable bits,
otherwise remove the shebang or move the file elsewhere.

icinga-web.noarch: W: script-without-shebang /usr/share/icinga-web/app/modules/AppKit/config/module.site.xml
icinga-web.noarch: W: script-without-shebang /usr/share/icinga-web/app/config/translation.site.xml
icinga-web.noarch: W: script-without-shebang /usr/share/icinga-web/app/modules/Web/config/module.site.xml
icinga-web.noarch: W: script-without-shebang /usr/share/icinga-web/app/config/settings.site.xml
icinga-web.noarch: W: script-without-shebang /usr/share/icinga-web/app/config/routing.modules.xml
icinga-web.noarch: W: script-without-shebang /usr/share/icinga-web/app/modules/Api/config/module.site.xml
icinga-web.noarch: W: script-without-shebang /usr/share/icinga-web/app/modules/Cronks/config/cronks.site.xml
icinga-web.noarch: W: script-without-shebang /usr/share/icinga-web/app/modules/Web/config/icinga-io.site.xml
icinga-web.noarch: W: script-without-shebang /usr/share/icinga-web/app/config/icinga.site.xml
icinga-web.noarch: W: script-without-shebang /usr/share/icinga-web/app/modules/AppKit/config/auth.site.xml
icinga-web.noarch: W: script-without-shebang /usr/share/icinga-web/app/config/databases.site.xml
icinga-web.noarch: W: script-without-shebang /usr/share/icinga-web/pub/styles/icinga.site.css
icinga-web.noarch: W: script-without-shebang /usr/share/icinga-web/app/modules/Cronks/config/module.site.xml
icinga-web.noarch: W: script-without-shebang /usr/share/icinga-web/app/config/factories.site.xml
This text file has executable bits set or is located in a path dedicated for
executables, but lacks a shebang and cannot thus be executed. If the file is
meant to be an executable script, add the shebang, otherwise remove the
executable bits or move the file elsewhere.

@icinga-migration
Copy link
Author

Updated by theh on 2011-06-08 13:44:15 +00:00

We fix the executable warnings with the following part of our icinga-web.spec, so it would be great if you could do this once for the whole package:

  1. fix file permissions
    chmod +x {_datadir}/%{name}/bin/*
    chmod +x {_datadir}/%{name}/lib/agavi/bin/*
    for i in lib/jsgettext/bin/po2json etc/tests/icingaWebTesting.php lib/phing/bin/phing lib/agavi/src/build/agavi/script/agavi.php ; do
    chmod +x {_datadir}/%{name}/$i
    done
    find {_datadir} -name "*.xml" -exec chmod -x {} \;

#fix rpmlint warning - css is not suposed to be executable
chmod -x {_datadir}/%{name}/pub/styles/icinga.site.css

@icinga-migration
Copy link
Author

Updated by jmosshammer on 2011-09-26 15:57:12 +00:00

  • Category set to Installation
  • Target Version set to 1.6

@icinga-migration
Copy link
Author

Updated by mhein on 2011-09-27 12:44:09 +00:00

  • Estimated Hours set to 1

This is a duplicate issue (partly).

Fixing the shebang things.

@icinga-migration
Copy link
Author

Updated by mhein on 2011-10-11 11:44:55 +00:00

  • Assigned to set to mhein

@icinga-migration
Copy link
Author

Updated by mhein on 2011-10-11 12:58:51 +00:00

  • Status changed from New to Assigned

@icinga-migration
Copy link
Author

Updated by mhein on 2011-10-11 13:18:02 +00:00

  • Status changed from Assigned to Resolved
  • Done % changed from 0 to 100

Applied in changeset 33526b3.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant