+6  A: 

To my knowledge, there's no "automatic" way to achieve this but doing it manually shouldn't be too hard.

If the script doesn't depend on the GreaseMonkey API then it should be as simple as copy n' paste, perhaps with some minification to get it all on one line.

You'll probably want to wrap it all in the following code too:

javascript: (function(){ /* Your code here */ })();

Also, be aware of the limits (you can't have an infinitely long bookmarklet): https://www.squarefree.com/bookmarklets/limits.html

J-P