From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-lj1-f177.google.com (mail-lj1-f177.google.com [209.85.208.177]) by mx.groups.io with SMTP id smtpd.web10.49103.1584299761480301451 for ; Sun, 15 Mar 2020 12:16:01 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20161025 header.b=vhIlaoGq; spf=pass (domain: gmail.com, ip: 209.85.208.177, mailfrom: roolebo@gmail.com) Received: by mail-lj1-f177.google.com with SMTP id d23so16117275ljg.13 for ; Sun, 15 Mar 2020 12:16:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=message-id:date:from:to:cc:subject; bh=Rme3JQcBWKZHyYU0r4NPhspYkPkSVCYuBmZSxDv1K4g=; b=vhIlaoGq+M/p5lbuBbHTFGAf5KU2gVrW0vh7nRQLb3w2wV2NWaBmwK2D+HmIiexFif bpBtaqdI3QUxO6Tt+M8tXGtX5JOJKHQ2ib5gNuObcx9bBta0trUgcHscUp/FSd7L1vOD SVEIVfn3V92IYx5mngajQGOfpCe+aa2HuNi0pjlsCJCfNSUdoqWwnCXheXHJAuX7ZKeO UhQTY3xwrEiFs6unfUnKEKemSEjAjwDZoJkAf2EqvtjS/1MjqK+6dy6Kv+qCu+z3umm3 WZujAVWHhWo7iE1l/p8qihlcwG6260k2hQHzLPwWNjkP9ChDDbb4bAxWqOn/J0eybyFD ROIg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:date:from:to:cc:subject; bh=Rme3JQcBWKZHyYU0r4NPhspYkPkSVCYuBmZSxDv1K4g=; b=kDSaEV5JFctLZTOYrWTlDzU2R1AZICCgikSc32ZuZOR+k48hGdKgBmkdTTItQ+iUwq Kx8keIqFQbKabhbNqjFxOkEUeboS53x6Iny2mwz6TlnR+CU6uq3g7I7BpkCRIOri1ZCi R/whL8DqJqGmZMqbmbjxz9uQs7Q1sjIEiqRp02jdG0bIX763a1uy7ujQndjhuFfAy/Qx vs5eqA5f+lhC/Nb3BEQGs8aloAys/Aw0TOau7+0uYBuftQ35v653VQJFNWaIOP49Q73E OUO/hvtq7dkckd7TDb+aJac/lkpT8ti/DO4DElYVwa8CZZttyB5EkXcWGQu43QioO+2v 8K1w== X-Gm-Message-State: ANhLgQ32J6O1mfHs5lbBUN3Wi4Ek+lwzvfWUXCw6lahLJCTwtU9Hdb4F G7f8W+9hTEXr2nqWw+NX3j6SIZNHWys= X-Google-Smtp-Source: ADFU+vuwtbeTUNMM9+j9/rIXzxwYZy0LbIKHJ8qcKzgvp1I9NMHoBIMspZyl2BD7t9YkhmVILWhu5Q== X-Received: by 2002:a2e:3309:: with SMTP id d9mr3886483ljc.73.1584299759514; Sun, 15 Mar 2020 12:15:59 -0700 (PDT) Return-Path: Received: from localhost ([80.254.50.127]) by smtp.gmail.com with ESMTPSA id q4sm1809103lfc.32.2020.03.15.12.15.59 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 15 Mar 2020 12:15:59 -0700 (PDT) Message-ID: <5e6e7eef.1c69fb81.d4e46.39ab@mx.google.com> Date: Sun, 15 Mar 2020 19:09:58 +0300 From: Roman Bolshakov To: devel@edk2.groups.io Cc: Michael Kinney Subject: [PATCH RESEND] Update mtoc installation guide for Xcode mtoc was added to homebrew in Homebrew/homebrew-core#51730 and can be installed on Catalina, Mojave and High Sierra. Signed-off-by: Roman Bolshakov --- Hello, The patch is intended for tianocore github wiki that has restricted editing for project members, that's why I'm sending it here. If someone is using macOS, could you please verify that EFI built with mtoc from homebrew works as expected. I'm sorry for the extra email with BCC. Thank you, Roman Xcode.md | 47 +---------------------------------------------- 1 file changed, 1 insertion(+), 46 deletions(-) diff --git a/Xcode.md b/Xcode.md index dc7e9fbb..0377fe44 100644 --- a/Xcode.md +++ b/Xcode.md @@ -17,53 +17,8 @@ While Xcode provides a full development environment as well as a suite of differ The mtoc utility is required to convert from the macOS Mach-O image format to the PE/COFF format as required by the UEFI specification. ### Brew Instructions -Brew does not have an inbuilt version of mtoc so you must create it from source - -Go to http://www.opensource.apple.com/ and click on the latest open source version of the developer tools (currently 8.2.1) and you will get a list of projects that can be downloaded. - -* Download the cctools project (currently cctools-895). -* Expand the tar file (double click on it in Finder) -* Open a Terminal window to get a command line prompt. - -To build `mtoc` you will need to copy an include directory from the LLVM project. - -* Download http://llvm.org/releases/download.html#4.0 -* Copy the include/llvm-c and include/llvm directories from LLVM into the cctools include directory, but do not overwrite include/llvm-c/Disassembler.h. - - ``` - $ cp cctools-895/include/llvm-c/Disassembler.h . - $ cp -R llvm-4.0.0.src/include/llvm cctools-895/include/llvm - $ cp -R llvm-4.0.0.src/include/llvm-c cctools-895/include/llvm-c - $ cp Disassembler.h cctools-895/include/llvm-c - ``` - -Then from the top cctools directory type: - -``` -$ cd cctools-895 -$ make -``` - -The make will finish with an error message on the file `strip.c`. This is expected. Then do the following: - -``` -$ cd efitools -$ make -``` - -You have now built the command line application `mtoc.NEW`! Move it to a more useful location. - -``` -$ sudo cp mtoc.NEW /usr/local/bin/mtoc -``` - -If this fails you probably don't have a local/bin directory under /usr. You need to add the directories by hand - ``` -$ cd /usr -$ sudo mkdir local -$ cd local -$ sudo mkdir bin +$ brew install mtoc ``` ## MacPorts Instructions ```