# Remove copies of the libpipelight.so and re-create them.
# This is needed because of the way Mozilla browsers evaluate the available
# plugins in the plugins directory: multiple soft- and hardlinks
# to the same file will be seen as _one_ plugin, not several.
#
# Browser plugins need to be enabled by the user (non-root) using the command:
#   $ pipelight-plugin --enable <plugin_name>
# for instance if the user wants to use SilverLight:
#   $ pipelight-plugin --enable silverlight5.1
# That will download and install the necessary Windows files, the very first
# time the plugin is loaded by a browser.
#
chroot . pipelight-plugin --remove-mozilla-plugins
chroot . pipelight-plugin --create-mozilla-plugins
( cd usr/share/pipelight ; rm -rf wine )
( cd usr/share/pipelight ; ln -sf /usr/bin/wine wine )
( cd usr/share/pipelight ; rm -rf wine64 )
( cd usr/share/pipelight ; ln -sf /usr/bin/wine64 wine64 )
