Closed (fixed)
Project:
Libraries API
Version:
6.x-1.0-alpha1
Component:
Documentation
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
9 Feb 2010 at 20:24 UTC
Updated:
23 Mar 2010 at 10:00 UTC
Hello all,
Users of the htmlpurifier library have been clamoring for Libraries API support for some time, see #708266: Decouple Location of htmlpurifier Library with Libraries API and #602530: Use Common Repository for Libraries. However, in the process of testing a patch supplied by one of these users, I noticed the following *awesome* behavior:
How do I make this not be a problem?
Comments
Comment #1
wik commentedsubscribing
Comment #2
drewish commentedhook_requirements() might be one way of doing it.
Comment #3
tstoecklerThat's a bad case of #228860: Upgrading a module with a newly added dependencies breaks things badly (Drupal 7 core issue).
See the patch in there for some code you might be able to use.
Comment #4
sunhttp://drupal.org/project/phpmailer 3.x implements optional support for Libraries API. It basically boils down to:
- no module dependency
- a private wrapper function that either leverages Libraries API or falls back to custom/old-school library location.
I'm not saying that its fallback handling is perfect, but it may provide some clues.
Comment #5
ezyang commentedThe procedure in phpmailer is what I'm going to go with. With any luck Drupal will fix the underlying issue!
Comment #6
irakli commentedIn case of libraries it probably is not worth/the best option, but in general, another way of introducing a dependency in a popular module, for existing installations: