Bug 15767 - PACKAGE_SCRIPT_DIR should be libexecdir based
Summary: PACKAGE_SCRIPT_DIR should be libexecdir based
Status: RESOLVED FIXED
Alias: None
Product: hal
Classification: Unclassified
Component: hald (show other bugs)
Version: unspecified
Hardware: Other All
: medium minor
Assignee: David Zeuthen (not reading bugmail)
QA Contact:
URL: http://cgit.freedesktop.org/hal/commi...
Whiteboard:
Keywords:
Depends on: 15768
Blocks:
  Show dependency treegraph
 
Reported: 2008-04-30 06:11 UTC by Stanislav Brabec
Modified: 2009-07-15 05:49 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
hal-script_dir.patch (1.73 KB, patch)
2008-04-30 06:49 UTC, Stanislav Brabec
Details | Splinter Review
hal-script-dir.patch (498 bytes, patch)
2008-09-22 08:06 UTC, Stanislav Brabec
Details | Splinter Review

Description Stanislav Brabec 2008-04-30 06:11:48 UTC
According to FHS recommendation, PACKAGE_SCRIPT_DIR should be based on libexecdir, not libdir as it is just now.

It would be nice to make it consistent with addons, which are installed into PACKAGE_LIBEXEC_DIR.
Comment 1 Stanislav Brabec 2008-04-30 06:49:11 UTC
Created attachment 16262 [details] [review]
hal-script_dir.patch

Proposed fix. Not tested in run, as it needs fix of more packages, but all apparent occurrences were changed.

This change would affect:
Redhat
openSUSE on bi-arch platforms

This change would not affect:
Debian

I can imagine better fix adding --with-hald-addon-dir and --with-hald-script-dir to configure. I can prepare it.
Comment 2 David Zeuthen (not reading bugmail) 2008-05-06 12:01:51 UTC
I'd rather not change this as I'm not convinced it won't break anything...
Comment 3 Stanislav Brabec 2008-05-09 03:35:35 UTC
It breaks anyway. libdir differs distribution from distribution. There is no convenient way to get scriptdir (see bug 15768), third party package authors have to guess (and many of them guess incorrectly, as it varies between /usr/lib/hal/scripts, /usr/lib64/hal/scripts, /usr/lib32/hal/scripts).

Yes, it will change default, but it is easy to select libexecdir properly to keep current behavior of particular distro. It would be responsibility of distribution packagers while upgrading.

See related problem for openSUSE: https://bugzilla.novell.com/show_bug.cgi?id=304316
Comment 4 Stanislav Brabec 2008-09-22 08:06:28 UTC
Created attachment 19103 [details] [review]
hal-script-dir.patch

New patch heavily depends on features introduced by the new patch in bug 15768 and changes default patch as they should be by definition of libdir and libexecdir.

After this patch, hal compiled with default options should not introduce bi-architectural clashes (32-bit script is perfectly usable by 64-bit hald, so there is no reason to split them into two directories).

The default path before this patch was not portable, that is why I propose to accept this patch. Distribution maintainers should be warned about this change. Packagers of non-bi-arch distros can easily keep the paths as they were before, packagers of bi-arch distros have to decide about new setup.
Comment 5 Kay Sievers 2009-07-14 13:34:47 UTC
Missed that bug, sorry. Hope that is fixed with the change to --libexecdir=/usr/lib/hal. Otherwise let me know. Thanks!
Comment 6 Stanislav Brabec 2009-07-15 05:49:59 UTC
Yes, it seems that http://cgit.freedesktop.org/hal/commit/?id=fa05be92c4b924ce6a791d2e7c46a467cccf357e will do the change in the current git version.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.