Skip to content

Commit

Permalink
SL-20617: Use set_target shell function for Mac CMake
Browse files Browse the repository at this point in the history
to prevent CMake from inferring a -target incompatible with our
-mmacosx-version-min.

Also remove Mac codesigning stanza: we sign code at viewer integration.
  • Loading branch information
nat-goodspeed committed Nov 16, 2023
1 parent b47a2ad commit 5d9d14d
Showing 1 changed file with 1 addition and 29 deletions.
30 changes: 1 addition & 29 deletions build-cmd.sh
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ case "$AUTOBUILD_PLATFORM" in
rm -rf "$cef_no_wrapper_build_dir"
mkdir -p "$cef_no_wrapper_build_dir"
cd "$cef_no_wrapper_build_dir"
opts="$LL_BUILD_RELEASE"
opts="$(set_target $LL_BUILD_RELEASE)"
plainopts="$(remove_cxxstd $opts)"
cmake -G Xcode \
-DPROJECT_ARCH="x86_64" \
Expand Down Expand Up @@ -191,34 +191,6 @@ case "$AUTOBUILD_PLATFORM" in
cp "$top/CEF_LICENSE.txt" "$stage/LICENSES"
cp "$top/LICENSE.txt" "$stage/LICENSES"

# sign the binaries (both CEF and DullahanHelper)
CONFIG_FILE="${build_secrets_checkout:-<no build_secrets_checkout>}/code-signing-osx/config.sh"
if [[ -n "${build_secrets_checkout:-}" && -f "$CONFIG_FILE" ]]; then
source $CONFIG_FILE

pushd "$stage/lib/release/Chromium Embedded Framework.framework/Libraries"
for dylib in lib*.dylib;
do
if [ -f "$dylib" ]; then
codesign --force --timestamp --options runtime --entitlements "$dullahan_source_dir/dullahan.entitlements" --sign "$APPLE_SIGNATURE" "$dylib"
fi
done
codesign --force --timestamp --options runtime --entitlements "$dullahan_source_dir/dullahan.entitlements" --sign "$APPLE_SIGNATURE" "../Chromium Embedded Framework"
popd

pushd "$stage/lib/release/"
for app in DullahanHelper*.app;
do
if [ -d "$app" ]; then
sed -i "" "s/DullahanHelper/${app%.*}/" "$app/Contents/Info.plist"
codesign --force --timestamp --options runtime --entitlements "$dullahan_source_dir/dullahan.entitlements" --sign "$APPLE_SIGNATURE" "$app"
fi
done
popd
else
echo "No config file $CONFIG_FILE found; skipping codesign."
fi

# populate version_file (after CMake runs)
g++ \
-I "$cef_no_wrapper_dir/include/" \
Expand Down

0 comments on commit 5d9d14d

Please sign in to comment.