<html><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  </head>
  <body>
    <div class="moz-cite-prefix">Okay something curious, I compiled with
      the scripts/install_openssl the Version 1.1.1k for
      ARCH=ios64-xcrun also verfied that the patch for openssl is
      applied to "Configurations/15-ios.conf"</div>
    <div class="moz-cite-prefix"><br>
    </div>
    <div class="moz-cite-prefix"><br>
    </div>
    <div class="moz-cite-prefix">./otp_build configure     
      --xcomp-conf=./xcomp/erl-xcomp-arm64-ios.conf      
      --with-ssl=/Users/michael/Entwicklung/ios_openssl</div>
    <div class="moz-cite-prefix"><br>
    </div>
    <div class="moz-cite-prefix">
      <p style="font-style: normal; font-variant-caps: normal;
        font-weight: normal; letter-spacing: normal; orphans: auto;
        text-align: start; text-indent: 0px; text-transform: none;
        white-space: normal; widows: auto; word-spacing: 0px;
        -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;
        text-decoration: none; margin: 0px; font-stretch: normal;
        font-size: 11px; line-height: normal; font-family: Menlo; color:
        rgb(0, 0, 0);"><span style="font-variant-ligatures:
          no-common-ligatures;"> LD<span class="Apple-tab-span" style="white-space: pre;">       </span>/Users/michael/Entwicklung/compile/ios/otp/bin/aarch64-apple-ios/beam.emu</span></p>
      <p style="font-style: normal; font-variant-caps: normal;
        font-weight: normal; letter-spacing: normal; orphans: auto;
        text-align: start; text-indent: 0px; text-transform: none;
        white-space: normal; widows: auto; word-spacing: 0px;
        -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;
        text-decoration: none; margin: 0px; font-stretch: normal;
        font-size: 11px; line-height: normal; font-family: Menlo; color:
        rgb(0, 0, 0);"><span style="font-variant-ligatures:
          no-common-ligatures;">Apple clang version 13.0.0
          (clang-1300.0.29.3)</span></p>
      <p style="font-style: normal; font-variant-caps: normal;
        font-weight: normal; letter-spacing: normal; orphans: auto;
        text-align: start; text-indent: 0px; text-transform: none;
        white-space: normal; widows: auto; word-spacing: 0px;
        -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;
        text-decoration: none; margin: 0px; font-stretch: normal;
        font-size: 11px; line-height: normal; font-family: Menlo; color:
        rgb(0, 0, 0);"><span style="font-variant-ligatures:
          no-common-ligatures;">Target: arm64-apple-darwin21.1.0</span></p>
      <p style="font-style: normal; font-variant-caps: normal;
        font-weight: normal; letter-spacing: normal; orphans: auto;
        text-align: start; text-indent: 0px; text-transform: none;
        white-space: normal; widows: auto; word-spacing: 0px;
        -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;
        text-decoration: none; margin: 0px; font-stretch: normal;
        font-size: 11px; line-height: normal; font-family: Menlo; color:
        rgb(0, 0, 0);"><span style="font-variant-ligatures:
          no-common-ligatures;">Thread model: posix</span></p>
      <p style="font-style: normal; font-variant-caps: normal;
        font-weight: normal; letter-spacing: normal; orphans: auto;
        text-align: start; text-indent: 0px; text-transform: none;
        white-space: normal; widows: auto; word-spacing: 0px;
        -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;
        text-decoration: none; margin: 0px; font-stretch: normal;
        font-size: 11px; line-height: normal; font-family: Menlo; color:
        rgb(0, 0, 0);"><span style="font-variant-ligatures:
          no-common-ligatures;">InstalledDir:
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin</span></p>
      <p style="font-style: normal; font-variant-caps: normal;
        font-weight: normal; letter-spacing: normal; orphans: auto;
        text-align: start; text-indent: 0px; text-transform: none;
        white-space: normal; widows: auto; word-spacing: 0px;
        -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;
        text-decoration: none; margin: 0px; font-stretch: normal;
        font-size: 11px; line-height: normal; font-family: Menlo; color:
        rgb(0, 0, 0);"><span style="font-variant-ligatures:
          no-common-ligatures;"> "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld"
          -demangle -lto_library
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/libLTO.dylib
          -dynamic -arch arm64 -platform_version ios 15.0.0 15.0
          -syslibroot
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS15.0.sdk
          -o
/Users/michael/Entwicklung/compile/ios/otp/bin/aarch64-apple-ios/beam.emu
-L/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS15.0.sdk/usr/lib/
          -L../lib/internal/aarch64-apple-ios -lc++
          obj/aarch64-apple-ios/opt/emu/erl_main.o
          obj/aarch64-apple-ios/opt/emu/preload.o
          obj/aarch64-apple-ios/opt/emu/erl_process.o
          obj/aarch64-apple-ios/opt/emu/beam_emu.o
          obj/aarch64-apple-ios/opt/emu/emu_load.o
          obj/aarch64-apple-ios/opt/emu/beam_common.o
          obj/aarch64-apple-ios/opt/emu/beam_bif_load.o
          obj/aarch64-apple-ios/opt/emu/beam_bp.o
          obj/aarch64-apple-ios/opt/emu/beam_catches.o
          obj/aarch64-apple-ios/opt/emu/beam_debug.o
          obj/aarch64-apple-ios/opt/emu/beam_load.o
          obj/aarch64-apple-ios/opt/emu/beam_opcodes.o
          obj/aarch64-apple-ios/opt/emu/beam_ranges.o
          obj/aarch64-apple-ios/opt/emu/beam_transform.o
          obj/aarch64-apple-ios/opt/emu/beam_transform_engine.o
          obj/aarch64-apple-ios/opt/emu/beam_transform_helpers.o
          obj/aarch64-apple-ios/opt/emu/code_ix.o
          obj/aarch64-apple-ios/opt/emu/erl_alloc.o
          obj/aarch64-apple-ios/opt/emu/erl_mtrace.o
          obj/aarch64-apple-ios/opt/emu/erl_alloc_util.o
          obj/aarch64-apple-ios/opt/emu/erl_goodfit_alloc.o
          obj/aarch64-apple-ios/opt/emu/erl_bestfit_alloc.o
          obj/aarch64-apple-ios/opt/emu/erl_afit_alloc.o
          obj/aarch64-apple-ios/opt/emu/erl_init.o
          obj/aarch64-apple-ios/opt/emu/erl_atom_table.o
          obj/aarch64-apple-ios/opt/emu/erl_bif_table.o
          obj/aarch64-apple-ios/opt/emu/erl_bif_ddll.o
          obj/aarch64-apple-ios/opt/emu/erl_bif_guard.o
          obj/aarch64-apple-ios/opt/emu/erl_bif_info.o
          obj/aarch64-apple-ios/opt/emu/erl_bif_op.o
          obj/aarch64-apple-ios/opt/emu/erl_bif_os.o
          obj/aarch64-apple-ios/opt/emu/erl_bif_lists.o
          obj/aarch64-apple-ios/opt/emu/erl_bif_persistent.o
          obj/aarch64-apple-ios/opt/emu/erl_bif_atomics.o
          obj/aarch64-apple-ios/opt/emu/erl_bif_counters.o
          obj/aarch64-apple-ios/opt/emu/erl_bif_trace.o
          obj/aarch64-apple-ios/opt/emu/erl_bif_unique.o
          obj/aarch64-apple-ios/opt/emu/erl_guard_bifs.o
          obj/aarch64-apple-ios/opt/emu/erl_dirty_bif_wrap.o
          obj/aarch64-apple-ios/opt/emu/erl_trace.o
          obj/aarch64-apple-ios/opt/emu/copy.o
          obj/aarch64-apple-ios/opt/emu/utils.o
          obj/aarch64-apple-ios/opt/emu/bif.o
          obj/aarch64-apple-ios/opt/emu/io.o
          obj/aarch64-apple-ios/opt/emu/erl_printf_term.o
          obj/aarch64-apple-ios/opt/emu/erl_debug.o
          obj/aarch64-apple-ios/opt/emu/erl_md5.o
          obj/aarch64-apple-ios/opt/emu/erl_message.o
          obj/aarch64-apple-ios/opt/emu/erl_proc_sig_queue.o
          obj/aarch64-apple-ios/opt/emu/erl_process_dict.o
          obj/aarch64-apple-ios/opt/emu/erl_process_lock.o
          obj/aarch64-apple-ios/opt/emu/erl_port_task.o
          obj/aarch64-apple-ios/opt/emu/erl_arith.o
          obj/aarch64-apple-ios/opt/emu/time.o
          obj/aarch64-apple-ios/opt/emu/erl_time_sup.o
          obj/aarch64-apple-ios/opt/emu/external.o
          obj/aarch64-apple-ios/opt/emu/dist.o
          obj/aarch64-apple-ios/opt/emu/binary.o
          obj/aarch64-apple-ios/opt/emu/erl_db.o
          obj/aarch64-apple-ios/opt/emu/erl_db_util.o
          obj/aarch64-apple-ios/opt/emu/erl_db_hash.o
          obj/aarch64-apple-ios/opt/emu/erl_db_tree.o
          obj/aarch64-apple-ios/opt/emu/erl_thr_progress.o
          obj/aarch64-apple-ios/opt/emu/big.o
          obj/aarch64-apple-ios/opt/emu/hash.o
          obj/aarch64-apple-ios/opt/emu/index.o
          obj/aarch64-apple-ios/opt/emu/atom.o
          obj/aarch64-apple-ios/opt/emu/module.o
          obj/aarch64-apple-ios/opt/emu/export.o
          obj/aarch64-apple-ios/opt/emu/register.o
          obj/aarch64-apple-ios/opt/emu/break.o
          obj/aarch64-apple-ios/opt/emu/erl_async.o
          obj/aarch64-apple-ios/opt/emu/erl_lock_check.o
          obj/aarch64-apple-ios/opt/emu/erl_dyn_lock_check.o
          obj/aarch64-apple-ios/opt/emu/erl_gc.o
          obj/aarch64-apple-ios/opt/emu/erl_lock_count.o
          obj/aarch64-apple-ios/opt/emu/erl_posix_str.o
          obj/aarch64-apple-ios/opt/emu/erl_bits.o
          obj/aarch64-apple-ios/opt/emu/erl_math.o
          obj/aarch64-apple-ios/opt/emu/erl_fun.o
          obj/aarch64-apple-ios/opt/emu/erl_bif_port.o
          obj/aarch64-apple-ios/opt/emu/erl_term.o
          obj/aarch64-apple-ios/opt/emu/erl_node_tables.o
          obj/aarch64-apple-ios/opt/emu/erl_monitor_link.o
          obj/aarch64-apple-ios/opt/emu/erl_process_dump.o
          obj/aarch64-apple-ios/opt/emu/erl_hl_timer.o
          obj/aarch64-apple-ios/opt/emu/erl_cpu_topology.o
          obj/aarch64-apple-ios/opt/emu/erl_drv_thread.o
          obj/aarch64-apple-ios/opt/emu/erl_bif_chksum.o
          obj/aarch64-apple-ios/opt/emu/erl_bif_re.o
          obj/aarch64-apple-ios/opt/emu/erl_unicode.o
          obj/aarch64-apple-ios/opt/emu/packet_parser.o
          obj/aarch64-apple-ios/opt/emu/safe_hash.o
          obj/aarch64-apple-ios/opt/emu/erl_zlib.o
          obj/aarch64-apple-ios/opt/emu/erl_nif.o
          obj/aarch64-apple-ios/opt/emu/erl_bif_binary.o
          obj/aarch64-apple-ios/opt/emu/erl_ao_firstfit_alloc.o
          obj/aarch64-apple-ios/opt/emu/erl_thr_queue.o
          obj/aarch64-apple-ios/opt/emu/erl_sched_spec_pre_alloc.o
          obj/aarch64-apple-ios/opt/emu/erl_ptab.o
          obj/aarch64-apple-ios/opt/emu/erl_map.o
          obj/aarch64-apple-ios/opt/emu/erl_msacc.o
          obj/aarch64-apple-ios/opt/emu/erl_lock_flags.o
          obj/aarch64-apple-ios/opt/emu/erl_io_queue.o
          obj/aarch64-apple-ios/opt/emu/erl_db_catree.o
          obj/aarch64-apple-ios/opt/emu/socket_dbg.o
          obj/aarch64-apple-ios/opt/emu/socket_tarray.o
          obj/aarch64-apple-ios/opt/emu/socket_util.o
          obj/aarch64-apple-ios/opt/emu/erl_flxctr.o
          obj/aarch64-apple-ios/opt/emu/erl_nfunc_sched.o
          obj/aarch64-apple-ios/opt/emu/erl_global_literals.o
          obj/aarch64-apple-ios/opt/emu/beam_file.o
          obj/aarch64-apple-ios/opt/emu/sys.o
          obj/aarch64-apple-ios/opt/emu/sys_drivers.o
          obj/aarch64-apple-ios/opt/emu/sys_env.o
          obj/aarch64-apple-ios/opt/emu/sys_uds.o
          obj/aarch64-apple-ios/opt/emu/driver_tab.o
          obj/aarch64-apple-ios/opt/emu/unix_prim_file.o
          obj/aarch64-apple-ios/opt/emu/sys_float.o
          obj/aarch64-apple-ios/opt/emu/sys_time.o
          obj/aarch64-apple-ios/opt/emu/sys_signal_stack.o
          obj/aarch64-apple-ios/opt/emu/erl_poll.o
          obj/aarch64-apple-ios/opt/emu/erl_check_io.o
          obj/aarch64-apple-ios/opt/emu/erl_mseg.o
          obj/aarch64-apple-ios/opt/emu/erl_mmap.o
          obj/aarch64-apple-ios/opt/emu/erl_osenv.o
          obj/aarch64-apple-ios/opt/emu/erl_unix_sys_ddll.o
          obj/aarch64-apple-ios/opt/emu/erl_mtrace_sys_wrap.o
          obj/aarch64-apple-ios/opt/emu/erl_sys_common_misc.o
          obj/aarch64-apple-ios/opt/emu/erl_os_monotonic_time_extender.o
          obj/aarch64-apple-ios/opt/emu/erl_poll.flbk.o
          obj/aarch64-apple-ios/opt/emu/erlang_lttng.o
          obj/aarch64-apple-ios/opt/emu/inet_drv.o
          obj/aarch64-apple-ios/opt/emu/ram_file_drv.o
          obj/aarch64-apple-ios/opt/emu/ttsl_drv.o
          obj/aarch64-apple-ios/opt/emu/erl_tracer_nif.o
          obj/aarch64-apple-ios/opt/emu/prim_buffer_nif.o
          obj/aarch64-apple-ios/opt/emu/prim_file_nif.o
          obj/aarch64-apple-ios/opt/emu/zlib_nif.o
          obj/aarch64-apple-ios/opt/emu/prim_socket_nif.o
          obj/aarch64-apple-ios/opt/emu/prim_net_nif.o
/Users/michael/Entwicklung/compile/ios/otp/lib/asn1/priv/lib/aarch64-apple-ios/asn1rt_nif.a
/Users/michael/Entwicklung/compile/ios/otp/lib/crypto/priv/lib/aarch64-apple-ios/crypto.a
          -lutil -ldl -lm
/Users/michael/Entwicklung/compile/ios/otp/erts/emulator/zlib/obj/aarch64-apple-ios/opt/libz.a
/Users/michael/Entwicklung/compile/ios/otp/erts/emulator/pcre/obj/aarch64-apple-ios/opt/libepcre.a
          -lethread -lerts_internal_r -lpthread -lSystem
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/13.0.0/lib/darwin/libclang_rt.ios.a</span></p>
      <p style="font-style: normal; font-variant-caps: normal;
        font-weight: normal; letter-spacing: normal; orphans: auto;
        text-align: start; text-indent: 0px; text-transform: none;
        white-space: normal; widows: auto; word-spacing: 0px;
        -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;
        text-decoration: none; margin: 0px; font-stretch: normal;
        font-size: 11px; line-height: normal; font-family: Menlo; color:
        rgb(0, 0, 0);"><span style="font-variant-ligatures:
          no-common-ligatures;">Undefined symbols for architecture
          arm64:</span></p>
      <p style="font-style: normal; font-variant-caps: normal;
        font-weight: normal; letter-spacing: normal; orphans: auto;
        text-align: start; text-indent: 0px; text-transform: none;
        white-space: normal; widows: auto; word-spacing: 0px;
        -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;
        text-decoration: none; margin: 0px; font-stretch: normal;
        font-size: 11px; line-height: normal; font-family: Menlo; color:
        rgb(0, 0, 0);"><span style="font-variant-ligatures:
          no-common-ligatures;"> <span class="Apple-converted-space"> </span>"_BN_CTX_free",
          referenced from:</span></p>
      <p style="font-style: normal; font-variant-caps: normal;
        font-weight: normal; letter-spacing: normal; orphans: auto;
        text-align: start; text-indent: 0px; text-transform: none;
        white-space: normal; widows: auto; word-spacing: 0px;
        -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;
        text-decoration: none; margin: 0px; font-stretch: normal;
        font-size: 11px; line-height: normal; font-family: Menlo; color:
        rgb(0, 0, 0);"><span style="font-variant-ligatures:
          no-common-ligatures;">     <span class="Apple-converted-space"> </span>_mod_exp_nif
          in crypto.a(bn_static.o)</span></p>
      <p style="font-style: normal; font-variant-caps: normal;
        font-weight: normal; letter-spacing: normal; orphans: auto;
        text-align: start; text-indent: 0px; text-transform: none;
        white-space: normal; widows: auto; word-spacing: 0px;
        -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;
        text-decoration: none; margin: 0px; font-stretch: normal;
        font-size: 11px; line-height: normal; font-family: Menlo; color:
        rgb(0, 0, 0);"><span style="font-variant-ligatures:
          no-common-ligatures;">     <span class="Apple-converted-space"> </span>_srp_value_B_nif
          in crypto.a(srp_static.o)</span></p>
      <p style="font-style: normal; font-variant-caps: normal;
        font-weight: normal; letter-spacing: normal; orphans: auto;
        text-align: start; text-indent: 0px; text-transform: none;
        white-space: normal; widows: auto; word-spacing: 0px;
        -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;
        text-decoration: none; margin: 0px; font-stretch: normal;
        font-size: 11px; line-height: normal; font-family: Menlo; color:
        rgb(0, 0, 0);"><span style="font-variant-ligatures:
          no-common-ligatures;">     <span class="Apple-converted-space"> </span>_srp_user_secret_nif
          in crypto.a(srp_static.o)</span></p>
      <p style="font-style: normal; font-variant-caps: normal;
        font-weight: normal; letter-spacing: normal; orphans: auto;
        text-align: start; text-indent: 0px; text-transform: none;
        white-space: normal; widows: auto; word-spacing: 0px;
        -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;
        text-decoration: none; margin: 0px; font-stretch: normal;
        font-size: 11px; line-height: normal; font-family: Menlo; color:
        rgb(0, 0, 0);"><span style="font-variant-ligatures:
          no-common-ligatures;">     <span class="Apple-converted-space"> </span>_srp_host_secret_nif
          in crypto.a(srp_static.o)</span></p>
      <br class="Apple-interchange-newline">
      <br>
    </div>
    <div class="moz-cite-prefix">but the output is also the same as
      before for the undefined symbols.<br>
    </div>
    <div class="moz-cite-prefix"><br>
    </div>
    <div class="moz-cite-prefix">The same otp_build configure is also
      correct with the "with-ssl", because the IOS-BUILD on Erlang said,
      it should match to libcrypto.a file?</div>
    <div class="moz-cite-prefix">or which erlang github otp tag did you
      tried it to compiled it that it works?</div>
    <div class="moz-cite-prefix"><br>
    </div>
    <div class="moz-cite-prefix">Thanks Michael<br>
    </div>
    <div class="moz-cite-prefix"><br>
    </div>
    <div class="moz-cite-prefix"><br>
    </div>
    <div class="moz-cite-prefix">Am 14.01.22 um 16:22 schrieb Dominic
      Letz:<br>
    </div>
    <blockquote type="cite" cite="mid:CACbRgNLUgwAT6eXbSRhmRSyMn-BMjWBTQ1JKdh-6uL=4WuMgLg@mail.gmail.com">
      
      <div dir="ltr">
        <div>Looks like the OpenSSL build you have created is missing
          some symbols. Getting OpenSSL to cross-compile correctly was
          fun for me as well although I don't recall all the error
          messages.</div>
        <div><br>
          This is the script I'm using to compile OpenSSL (you probably
          want ARCH=ios64-xcrun for native iOS or ARCH=<span class="gmail-pl-s">iossimulator-<span class="gmail-pl-s">arm64
              for the simulator on an M1)</span></span><br>
          <a href="https://github.com/elixir-desktop/runtimes/blob/master/scripts/install_openssl.sh" moz-do-not-send="true" class="moz-txt-link-freetext">https://github.com/elixir-desktop/runtimes/blob/master/scripts/install_openssl.sh</a><br>
          <br>
        </div>
        <div>This is the patched cross-compilation config file to make
          it generate the right symbols:<br>
        </div>
        <div><a href="https://github.com/elixir-desktop/runtimes/blob/master/patch/openssl-ios.conf" moz-do-not-send="true" class="moz-txt-link-freetext">https://github.com/elixir-desktop/runtimes/blob/master/patch/openssl-ios.conf</a><br>
        </div>
        <div>(copy it to openssl-<span class="gmail-pl-smi">$VSN</span>/Configurations/15-ios.conf)</div>
        <div><br>
          And this was my related pull request to get some of this into
          OpenSSL master, they only merged it to OpenSSL-3.0 though
          hence I think the manual patching above is atm the only way.<br>
          <a href="https://github.com/openssl/openssl/pull/16659" moz-do-not-send="true" class="moz-txt-link-freetext">https://github.com/openssl/openssl/pull/16659</a></div>
        <div><br>
        </div>
        <div>Hope this helps to fix the OpenSSL linkage.<br>
        </div>
        <div><br>
        </div>
        <div>Cheers!<br>
        </div>
      </div>
    </blockquote>
    <br>
  </body>
</html>