Skip to content

Commit

Permalink
fixing dylib installation
Browse files Browse the repository at this point in the history
  • Loading branch information
leogdion committed Oct 25, 2017
1 parent 6b68308 commit cb56159
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Speculid.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1444,7 +1444,7 @@
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "#otool -L \"$TARGET_BUILD_DIR/$EXECUTABLE_PATH\"\n\n\"$SRCROOT/install_dylib.sh\" /usr/local/opt/librsvg/lib/librsvg-2.2.dylib\n\"$SRCROOT/install_dylib.sh\" /usr/lib/libSystem.B.dylib\n\"$SRCROOT/install_dylib.sh\" /usr/local/opt/glib/lib/libgio-2.0.0.dylib\n\"$SRCROOT/install_dylib.sh\" /usr/local/opt/gdk-pixbuf/lib/libgdk_pixbuf-2.0.0.dylib\n\"$SRCROOT/install_dylib.sh\" /usr/local/opt/glib/lib/libgobject-2.0.0.dylib\n\"$SRCROOT/install_dylib.sh\" /usr/local/opt/glib/lib/libglib-2.0.0.dylib\n\"$SRCROOT/install_dylib.sh\" /usr/local/opt/gettext/lib/libintl.8.dylib\n\"$SRCROOT/install_dylib.sh\" /System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation\n\"$SRCROOT/install_dylib.sh\" /usr/local/opt/cairo/lib/libcairo.2.dylib\n\"$SRCROOT/install_dylib.sh\" /System/Library/Frameworks/Foundation.framework/Versions/C/Foundation\n\"$SRCROOT/install_dylib.sh\" /usr/lib/libobjc.A.dylib\n\n\"$SRCROOT/codesign-framework.sh\"";
shellScript = "DYLIBS=`otool -L \"$TARGET_BUILD_DIR/$EXECUTABLE_PATH\" | grep \"/opt\" | awk -F' ' '{ print $1 }'`\nfor dylib in $DYLIBS; do install -m 755 $dylib \"$TARGET_BUILD_DIR\"; done;\nfor dylib in $DYLIBS; do install_name_tool -change $dylib @executable_path/`basename $dylib` \"$TARGET_BUILD_DIR/$EXECUTABLE_PATH\"; done;";
};
B37C74B71F8C5CB500DF505B /* ShellScript */ = {
isa = PBXShellScriptBuildPhase;
Expand Down
4 changes: 3 additions & 1 deletion install_dylib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,6 @@ mkdir -p "$TARGET_BUILD_DIR/$FRAMEWORKS_FOLDER_PATH"

cp -f $1 "$TARGET_BUILD_DIR/$FRAMEWORKS_FOLDER_PATH"

install_name_tool -change $1 "@executable_path/../Frameworks/$DYLIB" "$TARGET_BUILD_DIR/$EXECUTABLE_PATH"
install_name_tool -change $1 "$FRAMEWORKS_FOLDER_PATH/$DYLIB" "$TARGET_BUILD_DIR/$EXECUTABLE_PATH"

echo "Installing $DYLIB to $FRAMEWORKS_FOLDER_PATH/$DYLIB"

0 comments on commit cb56159

Please sign in to comment.