Hi Austin,
austin seipp <[email protected]> writes: > Hello, > > I currently have spent a little bit of time in the past day or two > trying to get the latest copy of LLDB compiling on Linux. I spent some time yesterday working on this. Hope to finish the work soon. [snip] > After having a built llvm+clang, and then attempting to build lldb, I > get into source/Breakpoints when this occurs: > > llvm[2]: Compiling CommandObjectCall.cpp for Debug+Asserts build > In file included from CommandObjectCall.h:17, > from CommandObjectCall.cpp:10: > > ... > > I am not so worried about the incorrect call to the CommandObjectCall > constructor, what perplexes me more is the errors for missing things > like 'eArgTypeType.' Just delete CommandObjectCall.h and CommandObjectCall.cpp. They have been unused in LLDB for some time. Better to delete them then hack the build system to ignore the files. [snip] > Is the current LLDB trunk build known to be broken, or are these > values expected to be defined somewhere else? Generated as part of the > build, perhaps (although that seems highly unlikely)? My guess is that the XCode builds simply ignore those files. > Any help would be appreciated; I'd like to get LLDB building easily on > linux so it can be ported to work fully, eventually. I am currently > hosting my changes in a git repository (horray for git-svn) to keep > track of the changes in a more granular fashion, and it is on my > github: > > https://github.com/thoughtpolice/lldb/commits/linux I will look at your tree. I have LLDB building on linux (but just building, there is even less "functionality" then there was before the Linux support got out of sync). At the bottom of this message is the current diffstat for the changes I have been working on. I need to cherry pick the changes that get the tree to "just" build on linux and send them to the list. After that all the other stuff to get the hundreds of warnigs cleaned up can go in. I will look into publishing my own git tree later today or tommorow. There really is not *that* much to do in order to get the tree to build under linux ;) > All development happens on this 'linux' branch for me. You can see the > changes I've made in the above commit listing. But I would recommend > nobody check it out using git yet - because git svn must rebase when > updating the repository to reflect the latest SVN changes (it rebases > your un-pushed changes on top of all the new incoming SVN changes,) > the history will be rewritten frequently and I will have to > continuously delete and re-push my branch to github, if people want to > see it publicly, and if I want to keep up with the latest LLDB HEAD > revision (or I'll have to date the branches or something, but that > would be a PITA too.) As a result, anybody who pulls from it will have > to frequently delete their branch that tracks my 'linux' branch and > re-pull it, since it will be rebased fairly frequently to keep up with > HEAD when it changes. This isn't ideal, but it's better than managing > the changes with multiple .patch files, and through github it is > easier to see what changes I have made, and get comments on what > should/should not be done. If anybody can give some better tips on how > to manage this, that would be great, because I'm a git user and not > really a subversion person. If you use master to track the svn repo I would recommend that you do not rebase your "linux" branch -- just update master using 'git svn rebase' which should always be a simple fast-forward and pull those changes into the "linux" branch using a merge commit. That way you have a proper history that others using git can pull from while staying up to date. Of course, you would need to manage any merge-conflicts, etc. Take care, > > Regards, > Austin -- steve commit c93f36c4a39292fd2eeee73d955c59f25a90241e Author: Stephen Wilson <[email protected]> Date: Tue Dec 14 00:04:28 2010 -0500 Do not convert function addresses to object addresses. Strictly speaking C++ does not permit a function address to be converted to an object address. In Host::GetLLDBPath, use the address of a local static integer as an argument to Host::GetModuleFileSpecForHostAddress instead of the address of the calling function. This eliminates a pedantic warning under GCC. source/Host/common/Host.cpp | 12 +++++++----- 1 files changed, 7 insertions(+), 5 deletions(-) commit c32a096e4df81e8b88845f1c8cfe5f1636b26a3d Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 23:58:48 2010 -0500 Avoid trigraph confusion. Use implicit string concatenation to delimit multiple question marks. source/Host/common/Host.cpp | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) commit 19c36948d024b56d4116f9218ce56e0b3264c8a0 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 23:23:53 2010 -0500 Override UserID::GetID in Process. This allows us to view the ID of a process as a lldb::pid_t instead of an lldb::user_id_t. As the former is signed while the latter is not, this change avoids several signed/unsigned comparison compilation warnings. include/lldb/Target/Process.h | 10 ++++++++++ 1 files changed, 10 insertions(+), 0 deletions(-) commit 8c4ea620b3e10efc08ac3d1eb814a99f80ce2cf0 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 23:21:56 2010 -0500 Use parens to silent warnings about using '&&' and '||' in the same expression. source/Expression/DWARFExpression.cpp | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) commit 042f5345a06b17328a62a2639ab32a79b95bddf6 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 23:20:11 2010 -0500 Use "unsigned int" for CommandObject argument indices. include/lldb/Interpreter/CommandObject.h | 4 ++-- source/Interpreter/CommandObject.cpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit 005fffb7398d0d28099ce2918efe5ad68f7a4ac8 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 23:13:55 2010 -0500 Make CommandInterpreter::GetOptionArgumentPosition return an unsigned result. include/lldb/Interpreter/CommandInterpreter.h | 2 +- source/Interpreter/CommandInterpreter.cpp | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) commit 24b72dc5496ca8f981c376f30953815ae42e388e Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 22:37:06 2010 -0500 Do not use the 'z' length modifier as it is glibc specific. source/Expression/ClangFunction.cpp | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) commit 92a50d840b927a5493a9cac08007275769f5d123 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 22:33:28 2010 -0500 Use the standard C format macros to when printing types such as uint64_t. Makefile | 3 +++ source/Expression/ClangPersistentVariables.cpp | 4 +++- 2 files changed, 6 insertions(+), 1 deletions(-) commit c46b0d9ecf50951c31a3ead0c9b4e12414d6ce4e Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 22:04:01 2010 -0500 Replace '\e' with octal equivalent. The escape sequence '\e' is a non-standard GNU extension which GCC warns about when compiling under -pedantic. source/Core/DataExtractor.cpp | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) commit 04191e661a45dfc728b9d82bf4d4ccae928d0101 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 22:02:37 2010 -0500 Use LLVM_ATTRIBUTE_UNUSED to inhibit warning about unused static functions. source/Core/Debugger.cpp | 4 +++- source/Expression/ClangExpressionParser.cpp | 7 +++++-- source/Expression/ClangUserExpression.cpp | 4 +++- 3 files changed, 11 insertions(+), 4 deletions(-) commit 1df35285cbdb90cc3b270d713475801fd2e9cc83 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 21:45:55 2010 -0500 Remove case over disjoint enumeration value. It does not appear to be possible for Value::m_value to be assigned a value outside the range of ValueType. As this case is redundant removal should have zero impact and we eliminate a compilation warning in the process. source/Core/Value.cpp | 5 ----- 1 files changed, 0 insertions(+), 5 deletions(-) commit 7108e84bf0d395f60be2dd608da87ec266025da7 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 20:54:12 2010 -0500 Remove commented out code. Due to escaped newlines GCC warns about a multi-line comment. Keeping a fragment of old code around does not seem to offer any advantage over eliminating a warning. source/Core/Debugger.cpp | 9 --------- 1 files changed, 0 insertions(+), 9 deletions(-) commit 72d3e6f46752d0ed0baac03370509d6b20597067 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 20:51:41 2010 -0500 Handle missing cases in switch statements. source/Core/Communication.cpp | 1 + source/Expression/DWARFExpression.cpp | 3 +++ source/Target/RegisterContext.cpp | 3 +++ 3 files changed, 7 insertions(+), 0 deletions(-) commit 703c53042dbcaad53722114c4be6c616fa24ab6f Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 20:41:27 2010 -0500 Use #include rather than the Swig %include directive. In order to use the %include directive Swig needs to be instructed as to the search path. However, Swig 1.3.40 cannot process stdint.h provided by glibc. This fix takes advantage of the fact that, by default, Swig does not process headers introduced via #include. scripts/lldb.swig | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) commit 861a239db8d165c1ba4f667ed754c13f9671e304 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 20:38:59 2010 -0500 Rearrange #include's and component initialization/termination to allow compilation on non-Apple platforms. Also, bring in Thread.h as the complete declaration of lldb_private::Thread is needed. source/lldb.cpp | 15 ++++++++------- 1 files changed, 8 insertions(+), 7 deletions(-) commit b1e208c776db428ffdaecce857b26bf09fb395f5 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 20:34:17 2010 -0500 Do not include libunwind.h from Thread.h. Currently the local libunwind library cannot be used unless except on Darwin. Fortunately, it does not appear to be necessary for this component to be exposed via Thread.h. include/lldb/Target/Thread.h | 1 - 1 files changed, 0 insertions(+), 1 deletions(-) commit 2a86c935c1d14ca452c9fa39cfcb4cfded4ded79 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 20:29:31 2010 -0500 Provide full qualification for #include's. include/lldb/Utility/ArchDefaultUnwindPlan.h | 2 +- include/lldb/Utility/ArchVolatileRegs.h | 2 +- include/lldb/Utility/UnwindAssemblyProfiler.h | 2 +- source/Expression/ClangPersistentVariables.cpp | 4 ++-- source/Utility/ArchDefaultUnwindPlan.cpp | 2 +- source/Utility/ArchVolatileRegs.cpp | 2 +- source/Utility/UnwindAssemblyProfiler.cpp | 2 +- 7 files changed, 8 insertions(+), 8 deletions(-) commit 44b98585c45731f11e3fbb04df055d4068902cd2 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 20:23:20 2010 -0500 Update lib/Makefile to use current LLVM and Clang components. lib/Makefile | 12 ++++++------ 1 files changed, 6 insertions(+), 6 deletions(-) commit c4af128af4bf5c70d3945feb0dceb15238e9309d Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 17:51:33 2010 -0500 Fix typo (presumably carried over from the MacOSX plugin). .../Process/Linux/RegisterContextLinux_x86_64.cpp | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) commit 0a883d29ec36be9a46b0466147c1397c38eb3b7a Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 17:50:08 2010 -0500 Replace old "CurrentThread" calls with equivalent "SelectedThread" calls. source/Plugins/Process/Linux/ProcessMonitor.cpp | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) commit 9230ee76b10ee166d73cabd1235aa396e2ba0d25 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 17:45:41 2010 -0500 Host::StopMonitoringChildProcess has been removed. Provide a substitute. source/Plugins/Process/Linux/ProcessMonitor.cpp | 19 ++++++++++++++++--- source/Plugins/Process/Linux/ProcessMonitor.h | 5 ++++- 2 files changed, 20 insertions(+), 4 deletions(-) commit 1bc215c94a0978992d1ce535f60d3bbde8322cf3 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 17:41:43 2010 -0500 Provide LinuxThread with an implementation of Thread::GetUnwinder. source/Plugins/Process/Linux/LinuxThread.cpp | 6 ++++++ source/Plugins/Process/Linux/LinuxThread.h | 3 +++ 2 files changed, 9 insertions(+), 0 deletions(-) commit 34fc6076dc1207815c8a002bb4fbdc625fe8310c Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 17:36:55 2010 -0500 Update ProcessLinux method signatures to be in line with LLDB's current API. source/Plugins/Process/Linux/ProcessLinux.cpp | 3 ++- source/Plugins/Process/Linux/ProcessLinux.h | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) commit e23522391613c7af477d8a87e47983c36117ba3e Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 17:33:45 2010 -0500 Do not load sections manually when launching a Linux process. This code was a temporary workaround due to the lack of a dynamic loader plugin for the Linux platform that has bit rotted over time. Instead of replacing this hack with another a proper plugin will be developed instead. source/Plugins/Process/Linux/ProcessLinux.cpp | 27 ------------------------- source/Plugins/Process/Linux/ProcessLinux.h | 3 -- 2 files changed, 0 insertions(+), 30 deletions(-) commit 4b3106d49082d75f080973137f8a18a5c42b89cc Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 17:26:53 2010 -0500 Remove LinuxThread::GetRawStopReason and implement Thread::GetPrivateStopReason. source/Plugins/Process/Linux/LinuxThread.cpp | 15 ++++++++------- source/Plugins/Process/Linux/LinuxThread.h | 6 +++--- 2 files changed, 11 insertions(+), 10 deletions(-) commit c888a0ba33da41c5d327e7a5996102bee5ebd42f Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 17:21:02 2010 -0500 Use default implementation of Thread::GetStackFrameCount and Thread::GetStackFrameAtIndex. source/Plugins/Process/Linux/LinuxThread.cpp | 21 +-------------------- source/Plugins/Process/Linux/LinuxThread.h | 6 ------ 2 files changed, 1 insertions(+), 26 deletions(-) commit 54c07cf4932fc361e2a50c7ef16c437d0851a57d Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 17:14:27 2010 -0500 StopInfo now lives in the lldb_private namespace. Qualify. source/Plugins/Process/Linux/LinuxThread.h | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) commit df746b7a69c3d30a49bf2a16e2a759ff86737c9d Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 16:42:11 2010 -0500 Fixup simple const issues. In particular, use const_cast instead of C-style casts to eliminate compilation warnings. source/Commands/CommandObjectSettings.cpp | 4 ++-- source/Interpreter/Args.cpp | 8 ++++---- source/Target/Process.cpp | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) commit 036380e38031405f0235427fa8ffdea5f764a3de Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 16:11:34 2010 -0500 Fix definitions of Host::LaunchInNewTerminal and Host::OpenFileInExternalEditor. Definitions did not agree with the corresponding declarations when compiling on non-Apple platforms. source/Host/common/Host.cpp | 5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) commit 3c18b5a91c7cd57ccc13726cb28bf76c8a923645 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 16:05:43 2010 -0500 Add missing argument when constructing FileSpec's on both Linux and FreeBSD. source/Host/common/Host.cpp | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) commit 55783ac008710303b3b8d981959b2aa138dc0ca8 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 14:55:30 2010 -0500 Only access sockaddr_un::sun_len on platforms where it is defined. Linux does not define sockaddr_un::sun_len. Ideally, this member should be additionally protected using a #define generated at configure time so as to support the wider BSD family. source/Core/ConnectionFileDescriptor.cpp | 5 +++++ 1 files changed, 5 insertions(+), 0 deletions(-) commit 56c103f0383aff0a63029f80fa1f49143e5fbf9a Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 14:05:31 2010 -0500 Eliminate "comparison between signed and unsigned integer" warnings. source/Commands/CommandObjectFrame.cpp | 4 +- source/Core/DataExtractor.cpp | 6 ++-- source/Core/Language.cpp | 2 +- source/Core/UserSettingsController.cpp | 54 ++++++++++++++-------------- source/Expression/DWARFExpression.cpp | 2 +- source/Interpreter/CommandInterpreter.cpp | 8 ++-- source/Target/Process.cpp | 4 +- source/Target/ThreadPlanStepUntil.cpp | 2 +- source/Target/ThreadSpec.cpp | 4 +- 9 files changed, 43 insertions(+), 43 deletions(-) commit c33a74c9b5e9a809d32c9dce3d2612230ebd6d83 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 14:00:47 2010 -0500 Remove CommandObjectCall. CommandObjectCall has been unused in LLDB for some time. Removing the source avoids the need to either "fix" unused code or introduce hacks into the Make-based build system. source/Commands/CommandObjectCall.cpp | 341 ----------------------------- source/Commands/CommandObjectCall.h | 82 ------- source/Interpreter/CommandInterpreter.cpp | 2 - 3 files changed, 0 insertions(+), 425 deletions(-) commit 4305eae2898133edecea9cb719890c20a906cfdf Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 13:16:29 2010 -0500 Add missing include for standard library function strdup. source/API/SBType.cpp | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) commit 87ce6d134e90da9b1a0e83333d33d68a530718fd Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 13:14:56 2010 -0500 Fix typo: transform label into qualification. source/API/SBDebugger.cpp | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) commit d691253086ea761487dd8d64d3d6eb16097eab94 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 13:13:52 2010 -0500 Drop type qualifiers on function return types. include/lldb/Interpreter/CommandObject.h | 2 +- source/Interpreter/CommandObject.cpp | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) commit 52d4b220df69e664423d069449c4134e7d5fc8d4 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 13:04:51 2010 -0500 Make SBBreakpoint::GetThreadIndex return the thread index instead of zero. source/API/SBBreakpoint.cpp | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) commit 63206edd0cc62e33fbfaedce49b1ba0ecf6e642f Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 12:50:55 2010 -0500 Fix potential NULL pointer dereference. source/API/SBBreakpoint.cpp | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) commit 04ceca194311b481cc6b5a2cdef4d49fb9bfe664 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 12:37:57 2010 -0500 Add missing includes for standard declaration of FILE. include/lldb/API/SBStream.h | 2 ++ source/API/SBCommandReturnObject.cpp | 2 ++ 2 files changed, 4 insertions(+), 0 deletions(-) commit d79abdcd73646204b801443258cf3921886dc27b Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 12:35:17 2010 -0500 Add missing header for declaration of lldb_private::Target. source/lldb.cpp | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) commit 1b2b434d5e1c62b13e67417d28d2a431af2ed3f0 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 12:31:33 2010 -0500 Use the lldb namespace. Eliminates many errors when compiling using GCC under Linux (references to lldb defined enumerations in particular). source/lldb.cpp | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) commit ff001dc192806149a8fac93a2598f700f82f9373 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 12:24:02 2010 -0500 Fix up member initialization order warnings. include/lldb/Symbol/UnwindPlan.h | 2 +- source/Expression/ASTStructExtractor.cpp | 4 ++-- source/Expression/ClangExpressionVariable.cpp | 4 ++-- source/Expression/ClangFunction.cpp | 4 ++-- source/Expression/ClangUserExpression.cpp | 4 ++-- source/Expression/IRDynamicChecks.cpp | 4 ++-- source/Target/StackFrame.cpp | 8 ++++---- source/Target/StackFrameList.cpp | 4 ++-- source/Target/ThreadPlanTestCondition.cpp | 2 +- source/Target/ThreadPlanTracer.cpp | 4 ++-- 10 files changed, 20 insertions(+), 20 deletions(-) commit 480a1576693f5c65bd6ebb6024b07c2252280541 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 12:18:55 2010 -0500 Add missing include for std::auto_ptr. include/lldb/Utility/SharingPtr.h | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) commit 0da53fe6853fae6d8fcc1f2942064de6de80d638 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 12:16:21 2010 -0500 Remove trailing commas at the end of enumerator lists. include/lldb/Target/ThreadPlanTracer.h | 2 +- include/lldb/lldb-enumerations.h | 6 +++--- source/Commands/CommandObjectBreakpoint.h | 2 +- source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.h | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) commit bd3faede38b1ab826e29df4976b7f3a6742b2183 Author: Stephen Wilson <[email protected]> Date: Mon Dec 13 12:11:40 2010 -0500 Ignore unknown pragmas. In particular, we are looking to ignore the "#pragma mark" construct which GCC warns about on platforms other than Darwin. This cleans up diagnostic output significantly. Makefile | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) _______________________________________________ lldb-dev mailing list [email protected] http://lists.cs.uiuc.edu/mailman/listinfo/lldb-dev
