summaryrefslogtreecommitdiffstats
path: root/lldb/scripts/build-llvm.pl
Commit message (Collapse)AuthorAgeFilesLines
* modify Xcode build to use cmake/ninja for internal llvm/clangTodd Fiala2016-01-281-407/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change restores the Xcode build to working after Makefile support was stripped from LLVM and clang recently. With this change, the Xcode build now requires cmake (2.8.12.2+). The cmake must either be on the path that Xcode sees, or it must exist in one of the following locations: * /usr/local/bin/cmake * /opt/local/bin/cmake * $HOME/bin/cmake If the ninja build tool is present on the path, it will be used. If not, ninja will be cloned (via git), bootstrap-built, and used for the llvm/clang build. LLDB now requires a minimum deployment target of OS X 10.9. Prior to this, it was 10.8. The llvm/clang cmake build will not run with Xcode 7.2 or Xcode 7.3 beta's compiler with the minimum deployment target set to anything lower than 10.9. This is related to #include <atomic>. When llvm or clang source code does not exist in the lldb tree, it will be cloned via git using http://llvm.org/git/{project}.git. Previously it used SVN. If this causes any heartache, we can make this smarter, autodetect an embedded svn and use svn instead. (And/or use SVN if a git command is not available). This change also fixes an lldb-mi linkage failure (needed libncurses) as exposed by one of the LLVM libs. llvm-svn: 259027
* I've been seeing a problem with xcodebuilds on macosx forJason Molenda2015-10-161-8/+8
| | | | | | | | | | | | | | | | | a few days now where compiler-rt gets an error when trying to run its install step (related to not being able to find an ios version of a dylib), breaking the lldb build. I don't know if I'm the only one seeing this or if everyone has been doing the same hack I've been doing - removing the compiler-rt project from the default checkout. It's only used for the ASAN test case. So I'm temporarily checking in my hackaround of not checking out compiler-rt by default, I'll try to get back and look at what's actually happening in the compiler-rt install step that is causing the problems when built as a part of lldb. llvm-svn: 250487
* A little more cleanup in the build script that creates a list of archive ↵Greg Clayton2015-09-101-12/+17
| | | | | | directories to make things more clear. llvm-svn: 247329
* Removed debug prints that I accidentally left in.Greg Clayton2015-09-101-6/+0
| | | | llvm-svn: 247227
* On MacOSX, revamp the way we link against the llvm/clang .a files by making ↵Greg Clayton2015-09-101-38/+39
| | | | | | a text file that contains all .a filenames and use that when linking in Xcode. llvm-svn: 247224
* Fix the build-llvm.pl to not create one monster .a file from all of the llvm ↵Greg Clayton2015-09-091-62/+24
| | | | | | and clang .a files. We now just make a file list which we pass to the linker. llvm-svn: 247202
* include compiler-rt in build-llvm.plKuba Brecka2014-10-111-3/+13
| | | | | | | | Reviewed at http://reviews.llvm.org/D5736 The new test cases for ASan fail if the llvm build that is used with LLDB doesn't have compiler-rt (because the resulting compiler then cannot build with -fsanitize=address). Let's include compiler-rt in build-llvm.pl script and make sure we actually *build* it by removing the NO_RUNTIME_LIBS=1 argument used in the make line. After this, the ASan tests pass on a fresh svn checkout. llvm-svn: 219555
* Remove print statements I was using to debug this script additions.Greg Clayton2014-04-241-3/+0
| | | | llvm-svn: 207150
* Fix the build-llvm.pl to use glob to find all llvm and clang .a files for ↵Greg Clayton2014-04-241-76/+13
| | | | | | libllvmclang.a. llvm-svn: 207149
* Include additional libLLVMARM64Utils.a file.Greg Clayton2014-04-141-0/+1
| | | | llvm-svn: 206212
* lldb arm64 import.Jason Molenda2014-03-291-1/+7
| | | | | | | | | | | | | | | | These changes were written by Greg Clayton, Jim Ingham, Jason Molenda. It builds cleanly against TOT llvm with xcodebuild. I updated the cmake files by visual inspection but did not try a build. I haven't built these sources on any non-Mac platforms - I don't think this patch adds any code that requires darwin, but please let me know if I missed something. In debugserver, MachProcess.cpp and MachTask.cpp were renamed to MachProcess.mm and MachTask.mm as they picked up some new Objective-C code needed to launch processes when running on iOS. llvm-svn: 205113
* Link in the llvm/lib/ProfileData build product.Jason Molenda2014-03-271-0/+1
| | | | llvm-svn: 204895
* Detect when llvm or clang sources have changed and rebuild llvm/clang ↵Greg Clayton2014-03-111-5/+92
| | | | | | automatically. llvm-svn: 203594
* Add -stdlib=c++ to the LDFLAGS when configuring llvm. The lldbJason Molenda2014-01-171-0/+6
| | | | | | | | | | | | | | xcode project file sets the MACOSX_DEPLOYMENT_TARGET to 10.7. llvm/configure (as of r199313) tries to compile a .cpp file which includes <atomic> with -std=c++0x. If the deployment target is set to earlier than 10.9 and no C++ library is specified, clang will error out at this point. Fixes xcode building of lldb on Mac OS X. If this change causes problems for any of the other build workflows, please let me know and I'll fix it. llvm-svn: 199511
* Request for review: Fix build-llvm.plJean-Daniel Dupas2013-12-021-3/+1
| | | | | | | | | | | | Summary: - Stop to try to rebuild llvm on each invocation by removing the invalid library entry libLLVMArchive.a which no longer exists. - Remove the useless ranlib invocation. "libtools -static" automatically takes care of the archive table of content. CC: lldb-commits Differential Revision: http://llvm-reviews.chandlerc.com/D2296 llvm-svn: 196128
* Add --enable-cxx11 to llvm builds. As of r195239, SmallPtrSet.h /Jason Molenda2013-11-231-5/+5
| | | | | | | | | SmallPtrSet.cpp use different methods if SmallPtrSet.h is included in C++11 mode. Building llvm in C++03 mode and lldb in C++11 mode resulted in a link-time failure with the C++11-mode-specific method not being found in the llvm build. llvm-svn: 195544
* Updated build-llvm to use a more generic ioctlSean Callanan2013-11-191-1/+1
| | | | | | to determine the number of available processors. llvm-svn: 195172
* Changed LLVM configure options to reflect the newSean Callanan2013-08-131-1/+1
| | | | | | way of making LLVM not rely on terminfo. llvm-svn: 188305
* Ensure that we don't build LLVM with a dependencySean Callanan2013-08-081-1/+3
| | | | | | on curses. llvm-svn: 188015
* Fixing a linking issue when building LLDB with ToT LLVMEnrico Granata2013-06-171-0/+1
| | | | llvm-svn: 184127
* SDKROOT should only be unset/cleared for ARM builds. The first fix by Bob ↵Greg Clayton2013-01-161-5/+14
| | | | | | Wilson removed it for ARM for both configure and make, but only unset it for desktop configure, not for the make. My next fix unset/cleared it all the time. This fix only unset/clears it for ARM builds. llvm-svn: 172593
* Fix clang builds that were broken due to SDKROOT changes of you have an ↵Greg Clayton2013-01-161-3/+3
| | | | | | internal OS build. llvm-svn: 172582
* Fix cross-compiling problems in build-llvm.pl script. <rdar://problem/12986905>Bob Wilson2013-01-121-3/+5
| | | | | | | | | | As with llvm svn r172138, this patch is basically copying some changes that we've been using for building clang at Apple. Besides cleaning it up to use xcrun to locate the proper versions of tools, especially for cross compiling, it fixes the build to work with newer versions of clang that honor SDKROOT settings in the environment. llvm-svn: 172324
* Fix typo in function name and one more whitespace tweak.Bob Wilson2013-01-111-7/+7
| | | | llvm-svn: 172240
* Fix whitespace.Bob Wilson2013-01-111-230/+226
| | | | | | | | | This script used an inconsistent mix of spaces and tabs, and even ignoring that, it still had inconsistent indentation, which is pretty scary for a Python script. I also removed trailing whitespace from some lines. llvm-svn: 172237
* Removed a directive to delete the test subdirectoriesSean Callanan2012-10-041-3/+0
| | | | | | | | from LLVM and Clang. This made "svn update" very unpleasant if the original repository was fetched by build-llvm.pl. llvm-svn: 165268
* Added a new Xcode build configuration, DebugClang,Sean Callanan2012-09-241-0/+1
| | | | | | | | | | which builds a Debug+Asserts build of Clang and links LLDB against it. The Debug configuration builds Clang with Release+Asserts, for faster linking and smaller memory footprint when debugging the build LLDB. llvm-svn: 164573
* Brought LLDB top-of-tree into sync with LLVM/ClangSean Callanan2012-09-241-48/+2
| | | | | | | | | | | | | top-of-tree. Removed all local patches and llvm.zip. The intent is that fron now on top-of-tree will always build against LLVM/Clang top-of-tree, and that problems building will be resolved as they occur. Stable release branches of LLDB can be constructed as needed and linked to specific release branches of LLVM/Clang. llvm-svn: 164563
* On Mac OS X, lldb will now build c++11 and useSean Callanan2012-08-091-4/+4
| | | | | | | | | | | | | | libc++. We also no longer use the GNU extensions to C++ and C (we didn't use them anyway). This also means that the LLVM we use must be built with the new libc++. I will commit llvm.zip next. <rdar://problem/11930775> llvm-svn: 161562
* Building llvm for multiple arches could cause problemsJason Molenda2012-04-021-1/+3
| | | | | | with some archs, tweak the way we update PATH to fix that. llvm-svn: 153868
* Updated the revision of LLVM/Clang used by LLDB.Sean Callanan2012-03-081-2/+3
| | | | | | | | | | | | | | | This takes two important changes: - Calling blocks is now supported. You need to cast their return values, but that works fine. - We now can correctly run JIT-compiled expressions that use floating-point numbers. Also, we have taken a fix that allows us to ignore access control in Objective-C as in C++. llvm-svn: 152286
* Updated LLVM to take a new MC JIT that supportsSean Callanan2012-03-011-2/+2
| | | | | | | | | | allocations by section. We install these sections in the target process and inform the JIT of their new locations. Also removed some unused variable warnings. llvm-svn: 151789
* Updated LLVM to take some fixes that make theSean Callanan2012-02-231-2/+2
| | | | | | | | | | | Intel disassembler usable. Also flipped the switch: we are now exclusively using Disassembler.h instead of EnhancedDisassembly.h for all disassembly in LLDB. llvm-svn: 151306
* Brought LLVM/Clang up to top of tree. The onlySean Callanan2012-02-091-2/+2
| | | | | | | | change (besides logging) is that now string literals in the IR are ConstantDataArrays instead of ConstantArrays. llvm-svn: 150142
* I have brought LLDB up-to-date with top of treeSean Callanan2012-02-041-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | LLVM/Clang. This brings in several fixes, including: - Improvements in the Just-In-Time compiler's allocation of memory: the JIT now allocates memory in chunks of sections, improving its ability to generate relocations. I have revamped the RecordingMemoryManager to reflect these changes, as well as to get the memory allocation and data copying out fo the ClangExpressionParser code. Jim Grosbach wrote the updates to the JIT on the LLVM side. - A new ExternalASTSource interface to allow LLDB to report accurate structure layout information to Clang. Previously we could only report the sizes of fields, not their offsets. This meant that if data structures included field alignment directives, we could not communicate the necessary alignment to Clang and accesses to the data would fail. Now we can (and I have update the relevant test case). Thanks to Doug Gregor for implementing the Clang side of this fix. - The way Objective-C interfaces are completed by Clang has been made consistent with RecordDecls; with help from Doug Gregor and Greg Clayton I have ensured that this still works. - I have eliminated all local LLVM and Clang patches, committing the ones that are still relevant to LLVM and Clang as needed. I have tested the changes extensively locally, but please let me know if they cause any trouble for you. llvm-svn: 149775
* Updated Clang to take an enhancement to the waySean Callanan2011-12-161-2/+2
| | | | | | | | | | | | | | we handle Objective-C method calls. Currently, LLDB treats the result of an Objective-C method as unknown if the type information doesn't have the method's signature. Now Clang can cast the result to id if it isn't explicitly cast. I also added a test case for this, as well as a fix for a type import problem that this feature exposed. llvm-svn: 146756
* Picked up a new revision of Clang to pull in Objective-CSean Callanan2011-12-011-2/+2
| | | | | | | | | | | | | | | | | enhancements. With these enhancements, the return values of Objective-C methods with unknown return types can be implicitly cast to id for the purpose of making method calls. So what would have required this: (int)[(id)[ClassWithNoDebugInfo methodReturningObject] methodReturningInt] can now be written as: (int)[[ClassWithNoDebugInfo methodReturningObject] methodReturningInt] llvm-svn: 145567
* Pulled in a new revision of LLVM/Clang and addedSean Callanan2011-11-191-2/+2
| | | | | | | | | | | | | several patches. These patches fix a problem where templated types were not being completed the first time they were used, and fix a variety of minor issues I discovered while fixing that problem. One of the previous local patches was resolved in the most recent Clang, so I removed it. The others will be removed in due course. llvm-svn: 144984
* This commit completes the rearchitecting of ClangASTSourceSean Callanan2011-11-181-1/+8
| | | | | | | | | | | | | | | | | | | | | to allow variables in the persistent variable store to know how to complete themselves from debug information. That fixes a variety of bugs during dematerialization of expression results and also makes persistent variable and result variables ($foo, $4, ...) more useful. I have also added logging improvements that make it much easier to figure out how types are moving from place to place, and made some checking a little more aggressive. The commit includes patches to Clang which are currently being integrated into Clang proper; once these fixes are in Clang top-of-tree, these patches will be removed. The patches don't fix API; rather, they fix some internal bugs in Clang's ASTImporter that were exposed when LLDB was moving types from place to place multiple times. llvm-svn: 144969
* Pulled in a new version of LLVM/Clang to solve a varietySean Callanan2011-11-151-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | of problems with Objective-C object completion. To go along with the LLVM/Clang-side fixes, we have a variety of Objective-C improvements. Fixes include: - It is now possible to run expressions when stopped in an Objective-C class method and have "self" act just like "self" would act in the class method itself (i.e., [self classMethod] works without casting the return type if debug info is present). To accomplish this, the expression masquerades as a class method added by a category. - Objective-C objects can now provide methods and properties and methods to Clang on demand (i.e., the ASTImporter sets hasExternalVisibleDecls on Objective-C interface objects). - Objective-C built-in types, which had long been a bone of contention (should we be using "id"? "id*"?), are now fetched correctly using accessor functions on ClangASTContext. We inhibit searches for them in the debug information. There are also a variety of logging fixes, and I made two changes to the test suite: - Enabled a test case for Objective-C properties in the current translation unit. - Added a test case for calling Objective-C class methods when stopped in a class method. llvm-svn: 144607
* Updated LLVM/Clang to pull in a fix for Objective-CSean Callanan2011-11-111-2/+2
| | | | | | | | | | interfaces. This allows us to pull in Objective-C method types on demand, which is also now implemented. Also added a minor fix to prevent multiple-definition errors for "Class" and "id". llvm-svn: 144405
* Updated LLVM/Clang to pick up a fix for imports ofSean Callanan2011-11-041-10/+10
| | | | | | | | | | | | | | | C++ vtables, fixing a record layout problem in the expression parser. Also fixed various problems with the generation and unpacking of llvm.zip given our new better handling of multiple architectures in the LLVM build. (And added a log message that will hopefully catch record layout problems in the future.) llvm-svn: 143741
* Fixed the Xcode project building of LLVM to be a bit more user friendly:Greg Clayton2011-11-041-95/+124
| | | | | | | | | | | | | | | | | | | - If you download and build the sources in the Xcode project, x86_64 builds by default using the "llvm.zip" checkpointed LLVM. - If you delete the "lldb/llvm.zip" and the "lldb/llvm" folder, and build the Xcode project will download the right LLVM sources and build them from scratch - If you have a "lldb/llvm" folder already that contains a "lldb/llvm/lib" directory, we will use the sources you have placed in the LLDB directory. Python can now be disabled for platforms that don't support it. Changed the way the libllvmclang.a files get used. They now all get built into arch specific directories and never get merged into universal binaries as this was causing issues where you would have to go and delete the file if you wanted to build an extra architecture slice. llvm-svn: 143678
* ...And forgot to check in build-llvm.pl. Sigh.Sean Callanan2011-11-021-2/+2
| | | | llvm-svn: 143586
* Updated LLVM/Clang to pull in a variety of typeSean Callanan2011-10-211-2/+2
| | | | | | | | importation fixes, reducing the amount of requests made to LLDB for unknown types and increasing fidelity of the expression parser. llvm-svn: 142639
* Updated LLVM/Clang to pull in the latest ARM disassembler.Sean Callanan2011-10-071-3/+2
| | | | | | | | This involved minor changes to the way we report Objective-C methods, as well as cosmetic changes and added parameters for a variety of Clang APIs. llvm-svn: 141437
* Restored the version of LLVM that we previouslySean Callanan2011-08-221-2/+2
| | | | | | | | | | | | | | rolled back, and the testcase that the rollback broke. The new LLVM has a new ARM disassembler, which may cause instability. Keeping the old one would force us into a contorted position vis-a-vis the LLVM sources we bring in, so we will address issues on the new one rather than keeping the old one around. llvm-svn: 138284
* Refined the rollback to LLVM, picking up a newerSean Callanan2011-08-191-2/+11
| | | | | | | | | | | | | revision and adding a patch that fixes an AsmParser crash on ARM. One feature that we unfortunately lost (for the moment!) is the ability to cast unknown code symbols to arbitrary function types and put the resulting function pointer in a result variable. This feature will be back, though. llvm-svn: 138036
* Because of disassembler crashes, I rolled backSean Callanan2011-08-181-7/+9
| | | | | | | | | | | | | LLVM to pull in the older ARM disassembler. I also modified our build scripts to support building LLVM from one SVN revision and Clang from another. These are temporary measures; as soon as we get some solid testing in with the new ARM disassembler, we plan to switch right back. llvm-svn: 137965
* Updated LLVM/Clang to to pick up fixes for aSean Callanan2011-08-111-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | problem in which the following cast: – expr (int (*)(const char*, ...))printf - caused a crash. This had several causes: - First, Clang did not support implicit casts of a function of unknown type to a function pointer. - Second, after this was fixed, the Clang AST importer did not support importing function pointer types produced by resolving these casts. These two problems are now resolved, and I have added a test case to verify that they work. I also did a little bit of build-system cleanup because we now use libEnhancedDisassembly.a instead of the .dylib. llvm-svn: 137338
OpenPOWER on IntegriCloud