<?xml version="1.0" encoding="utf-8"?>
<installer-script minSpecVersion="1">
    <title>macOS driver for the UPort 1200/1400/1600 Series</title>
    <license file="COPYING-MOXA.rtf"/>
    <readme file="important.txt"/>
    <background mime-type="image/png" file="banner.png" scaling="proportional"/>
    <background-darkAqua mime-type="image/png" file="banner_dark.png" scaling="proportional"/>
    <welcome file="welcome.html" mime-type="text/html"/>
    <conclusion file="conclusion.html" mime-type="text/html"/>
    <options customize="never" allow-external-scripts="no"/>
    <domains enable_localSystem="true"/>
    <installation-check script="installCheck();"/>
    <script>
function installCheck() {
    if(!(system.compareVersions(system.version.ProductVersion, '10.11.0') &gt;= 0)) {
        my.result.title = 'Unable to install';
        my.result.message = 'MxUPortDriver requires macOS 10.11 or later.';
        my.result.type = 'Fatal';
        return false;
    }
    if(system.files.fileExistsAtPath('/Library/MxUPortDriver/1.1/')) {
        my.result.title = 'Previous Installation Detected';
        my.result.message = 'A previous installation of MxUPortDriver exists at /Library/MxUPortDriver/1.1/. This installer will remove the previous installation prior to installing. Please back up any data before proceeding.';
        my.result.type = 'Warning';
        return false;
    }
    return true;
}
    </script>
    <choices-outline>
        <line choice="default">
            <line choice="MxUPortDriver"/>
            <line choice="MxUPortDriver-1"/>
        </line>
    </choices-outline>
    <choice id="default"/>
    <choice id="MxUPortDriver" title="MxUPortDriver">
        <pkg-ref id="MxUPortDriver_kext.pkg"/>
    </choice>
    <pkg-ref id="MxUPortDriver_kext.pkg" auth="Root" packageIdentifier="com.moxa.uport.MxUPortDriver.1.1.kext" version="1.1" installKBytes="936">#MxUPortDriver_kext.pkg</pkg-ref>
    <choice id="MxUPortDriver-1" title="MxUPortDriver">
        <pkg-ref id="MxUPortDriver_lib.pkg"/>
    </choice>
    <pkg-ref id="MxUPortDriver_lib.pkg" auth="Root" packageIdentifier="com.moxa.uport.MxUPortDriver.1.1.lib" version="1.1" installKBytes="80">#MxUPortDriver_lib.pkg</pkg-ref>
    <pkg-ref id="MxUPortDriver_kext.pkg">
        <bundle-version>
            <bundle CFBundleShortVersionString="1.1" CFBundleVersion="1" id="com.apple.xcode.dsym.com.moxa.uport.mxuport" path="MxUPortDriver.kext.dSYM"/>
            <bundle CFBundleShortVersionString="1.1" CFBundleVersion="1" id="com.moxa.uport.mxuport" path="MxUPortDriver.kext"/>
        </bundle-version>
    </pkg-ref>
    <pkg-ref id="MxUPortDriver_lib.pkg">
        <bundle-version>
            <bundle CFBundleShortVersionString="1.2" CFBundleVersion="1" id="com.moxa.uport.mxutty" path="mxutty.app"/>
        </bundle-version>
    </pkg-ref>
</installer-script>