[Lldb-commits] [lldb] r249256 - cmake: ensure readline python module target is added before finishing swig.

Todd Fiala via lldb-commits lldb-commits at lists.llvm.org
Mon Oct 5 13:15:34 PDT 2015


Filed this bugzilla bug:
https://llvm.org/bugs/show_bug.cgi?id=25062

to capture.

On Mon, Oct 5, 2015 at 1:12 PM, Todd Fiala <todd.fiala at gmail.com> wrote:

> Oh I see what you mean.
>
> Yeah that would be easy enough to do.  I'll put it on a cleanup-priority
> list.  (Not promising I'll hit it very soon but I will do it).
>
> On Mon, Oct 5, 2015 at 1:08 PM, Zachary Turner <zturner at google.com> wrote:
>
>> So on the Xcode side, there is a script that runs called
>> `build-swig-wrapper-classes.sh` that converts the SWIG into python stuff.
>> On the Windows side, there's no such thing as shell scripts, so we wrote
>> python scripts instead.  It's called buildSwigWrapperClasses.py, in the
>> same folder ad the shell script.
>>
>> The command line syntax is different, but functionally they should be
>> equivalent.  To see what the syntax looks like for the python file, you
>> could probably just edit the CMakeLists.txt and print out the command line
>> during CMake generation time. Then change the shell script in the Xcode
>> project to use the python script instead, and finally delete the shell
>> script from the repo.
>>
>> On Mon, Oct 5, 2015 at 12:55 PM Todd Fiala <todd.fiala at gmail.com> wrote:
>>
>>> Oops, missed this.  I see how it can be gnarly finding things in
>>> lldb-commits!
>>>
>>>
>>>
>>> On Sat, Oct 3, 2015 at 7:25 PM, Zachary Turner <zturner at google.com>
>>> wrote:
>>>
>>>> You just reminded me.  Since you've been hitting a lot of this stuff
>>>> lately and doing a lot of great cleanup work, how do you feel about
>>>> integrating the swig python scripts into the Xcode build?
>>>>
>>>
>>> Can you tell me more about what you had in mind?  (I am actually way
>>> more familiar with how we do it on the cmake side than the Xcode side!)
>>>
>>>
>>>>   I've been meaning to do this for a long time but I don't have enough
>>>> Xcode knowledge.
>>>>
>>>
>>> I'm pretty sure I can do whatever we want to try to do here, as soon as
>>> I know what that is.  The only thing that might be interesting is we have a
>>> group of external folks using a cmake build on OS X and not using
>>> xcodebuild.  So whatever change you're thinking here needs to still work
>>> for a straight cmake approach (I think).
>>>
>>>
>>>>   Having parallel scripts for Xcode and CMake introduces an obvious
>>>> technical debt that we could get rid of if there was just one script.
>>>>
>>>> As far as I know it should be a drop-in replacement, and it supports
>>>> everything the shell scripts currently support.  It's been lingering long
>>>> enough that there's obviously no rush, but if you ever feel the urge to
>>>> look at it, I think it would be easy.
>>>>
>>>>
>>> Sure, tell me a bit more and I can look into getting this on my queue.
>>>
>>> -Todd
>>>
>>>
>>>
>>>> On Sat, Oct 3, 2015 at 6:30 PM Todd Fiala via lldb-commits <
>>>> lldb-commits at lists.llvm.org> wrote:
>>>>
>>>>> Author: tfiala
>>>>> Date: Sat Oct  3 20:28:51 2015
>>>>> New Revision: 249256
>>>>>
>>>>> URL: http://llvm.org/viewvc/llvm-project?rev=249256&view=rev
>>>>> Log:
>>>>> cmake: ensure readline python module target is added before finishing
>>>>> swig.
>>>>>
>>>>> When the readline target exists (only for non-Android Linux currently),
>>>>> ensure that target is made a dependency of the finish_swig
>>>>> python-wrap-up
>>>>> steps.  This ensures it is built when building the lldb target.
>>>>>
>>>>> Fixes:
>>>>> https://llvm.org/bugs/show_bug.cgi?id=25038
>>>>>
>>>>> Modified:
>>>>>     lldb/trunk/CMakeLists.txt
>>>>>
>>>>> Modified: lldb/trunk/CMakeLists.txt
>>>>> URL:
>>>>> http://llvm.org/viewvc/llvm-project/lldb/trunk/CMakeLists.txt?rev=249256&r1=249255&r2=249256&view=diff
>>>>>
>>>>> ==============================================================================
>>>>> --- lldb/trunk/CMakeLists.txt (original)
>>>>> +++ lldb/trunk/CMakeLists.txt Sat Oct  3 20:28:51 2015
>>>>> @@ -24,6 +24,12 @@ if (NOT LLDB_DISABLE_PYTHON)
>>>>>      # We depend on liblldb being built before we can do this step.
>>>>>      add_dependencies(finish_swig liblldb argdumper)
>>>>>
>>>>> +    # If we build the readline module, we depend on that happening
>>>>> +    # first.
>>>>> +    if (TARGET readline)
>>>>> +        add_dependencies(finish_swig readline)
>>>>> +    endif()
>>>>> +
>>>>>      # Ensure we do the python post-build step when building lldb.
>>>>>      add_dependencies(lldb finish_swig)
>>>>>
>>>>>
>>>>>
>>>>> _______________________________________________
>>>>> lldb-commits mailing list
>>>>> lldb-commits at lists.llvm.org
>>>>> http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
>>>>>
>>>>
>>>
>>>
>>> --
>>> -Todd
>>>
>>
>
>
> --
> -Todd
>



-- 
-Todd
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20151005/ef7842a5/attachment-0001.html>


More information about the lldb-commits mailing list