Using packaged JavaScript libraries on Debian and Ubuntu
Drupal 7 will no longer be supported after January 5, 2025. Learn more and find resources for Drupal 7 sites
Debian's pkg-javascript team has been busy packaging a huge collection of popular JavaScript libraries in a 100% free manner that guarantees adherence to the Debian Free Software Guidelines. This means that they have already done a lot of the groundwork to weed out minified (obfuscated) code that isn't accompanied by readable source code and ensure that there is a mechanism for conveniently and promptly distributing security fixes.
The Drupal Libraries API module has now been packaged for Debian. The goal of this package is to facilitate the automated use of Debian's high-quality JavaScript packages to fulfill the dependency requirements of Drupal modules.
Exact details of how these components fit together is currently explained in the README.Debian file distributed in the package. People packaging JavaScript to use by Drupal modules need to consider making a small `glue' package to help Drupal's Libraries API discover the JavaScript. In many cases the glue package needs to do little more than creating a symlink from /usr/share/javascript to /usr/share/drupal7/libraries - this process can also potentially be automated by a future version of dh-make-drupal
The final goal of this work is that a server administrator may simply be able to do:
# apt-get install drupal7-mod-foo
And the apt system will automatically install the module foo, drupal7 itself, the Libraries API module and any required JavaScript packages. Once deployed, the sysadmin will automatically receive security fixes for the third-party code whenever they run:
# apt-get upgrade
Obviously, this should also work the same way for systems that are derived from Debian, such as Ubuntu
Help improve this page
You can:
- Log in, click Edit, and edit this page
- Log in, click Discuss, update the Page status value, and suggest an improvement
- Log in and create a Documentation issue with your suggestion