blob: d50bfce5386bbb24d7b183ec5f1257e3e96cc8e4 [file] [log] [blame]
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2020 Equo
This program and the accompanying materials are made available under the
terms of the Eclipse Public License 2.0 which is available at
http://www.eclipse.org/legal/epl-2.0.
SPDX-License-Identifier: EPL-2.0
Contributors:
Guillermo Zunino, Equo - initial implementation
-->
<project name="org.eclipse.swt.browser.chromium.cocoa.macosx.x86_64" default="build.jars" basedir=".">
<property name="swt.ws" value="cocoa" />
<property name="swt.os" value="macosx" />
<property name="swt.arch" value="x86_64" />
<!-- These properties are used by eclipse when exporting as Deployable plugin and fragments -->
<property name="version.suffix" value="3.115.0" />
<condition property="plugindir" value="../../../eclipse.platform.swt/bundles/org.eclipse.swt.browser.chromium" else="${buildDirectory}/plugins/org.eclipse.swt.browser.chromium">
<available file="../../../eclipse.platform.swt/bundles/org.eclipse.swt" type="dir"/>
</condition>
<target name="@dot" depends="init" unless="@dot" description="Create jar: @dot.">
<path id="@dot.cp">
<fileset dir="../org.eclipse.swt.cocoa.macosx.x86_64/target">
<include name="*.jar"/>
</fileset>
</path>
<property name="dotcp" value="${toString:@dot.cp}"/>
<antcall target="org.eclipse.swt.fragment.@dot"/>
</target>
<target name="copy.cocoa.src">
<property name="copy.src.dir" value="${temp.folder}/@dot.src"/>
<delete dir="${copy.src.dir}" quiet="true"/>
<copy todir="${copy.src.dir}" failonerror="true" overwrite="true">
<fileset dir="${plugindir}/common/" excludes="rust-library/"/>
<fileset dir="${plugindir}/cocoa/"/>
</copy>
</target>
<target name="build_chromium" depends="init_fragment,get_version">
<property name="chromium_subp_output_dir" value="${basedir}/${fragment_dir}/chromium-${cef_ver}/chromium_subp-${swt_version}.app/Contents/MacOS/"/>
<property name="chromium_subp" value="chromium_subp"/>
<antcall target="chromiumbuild.build_chromium"/>
<exec dir="${chromium_subp_output_dir}" executable="install_name_tool" failonerror="true">
<arg line="-change '@rpath/Frameworks/Chromium Embedded Framework.framework/Chromium Embedded Framework' '@loader_path/../../../Chromium Embedded Framework.framework/Chromium Embedded Framework' ${chromium_subp}"/>
</exec>
<exec dir="${basedir}/${fragment_dir}/chromium-${cef_ver}" executable="install_name_tool" failonerror="true">
<arg line="-change '@rpath/Frameworks/Chromium Embedded Framework.framework/Chromium Embedded Framework' '@loader_path/Chromium Embedded Framework.framework/Chromium Embedded Framework' libchromium_swt_${swt_version}.dylib"/>
</exec>
<exec dir="${basedir}/${fragment_dir}/chromium-${cef_ver}" executable="install_name_tool" failonerror="true">
<arg line="-id '@loader_path/libchromium_swt_${swt_version}.dylib' libchromium_swt_${swt_version}.dylib"/>
</exec>
<exec dir="${basedir}/${fragment_dir}/chromium-${cef_ver}" executable="strip" failonerror="true">
<arg line="-r -u libchromium_swt_${swt_version}.dylib"/>
</exec>
</target>
<import file="${plugindir}/buildChromium.xml"/>
</project>