Advertisement
Guest User

Untitled

a guest
May 5th, 2015
241
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.95 KB | None | 0 0
  1. #!/bin/sh
  2.  
  3. cp /Library/Frameworks/Mono.framework/Versions/Current/lib/libgdk_pixbuf-2.0.0.dylib "$1/Contents/MonoBundle/"
  4. cp /Library/Frameworks/Mono.framework/Versions/Current/lib/libgio-2.0.0.dylib "$1/Contents/MonoBundle/"
  5. cp /Library/Frameworks/Mono.framework/Versions/Current/lib/libgmodule-2.0.0.dylib "$1/Contents/MonoBundle/"
  6. cp /Library/Frameworks/Mono.framework/Versions/Current/lib/libffi.6.dylib "$1/Contents/MonoBundle/"
  7. cp /Library/Frameworks/Mono.framework/Versions/Current/lib/libxml2.2.dylib "$1/Contents/MonoBundle/"
  8.  
  9. find $1 -name "*.config" | while read FILE; do
  10. sed -i "" 's:/Library/Frameworks/Mono.framework/Versions/3.12.1/lib/:@executable_path/../MonoBundle/:' "$FILE";
  11. done
  12.  
  13. find $1 -name "*.dylib" -or -name "*.so" | while read FILE; do
  14. otool -L "$FILE" |
  15. grep Mono\.framework |
  16. sed 's/\s*//' | sed 's/ .*//' | while read LIB; do
  17. install_name_tool -change "$LIB" '@executable_path/../MonoBundle/'"${LIB##*/}" "$FILE";
  18. done
  19. done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement