[rust-dev] Using CMake with Rust

Carter Schonwald carter.schonwald at gmail.com
Thu Jan 2 15:44:40 PST 2014


question: is there any reason why cmake integration / support couldn't be
mediated via some improvements to rustpkg?

I had a first look at the current rustpkg api yesterday, and i ran away
screaming about the the many angled stringy typed ones that inhabit the
gaps in configuration space.

I emphatically agree that there should be some flexiblity in build tooling
support, and any dogmatic approach "all in rust" or "use X" will fail for
some use case. Is there any reason why that couldn't be via making it easy
to use an external build system via some rustpkg api improvement?
(seriously!)




On Thu, Jan 2, 2014 at 3:42 PM, Joshua Rodgers <bytemr at gmail.com> wrote:

> As an active user of CMake for several C++ projects that I maintain I
> would be fully on board with first class CMake support by rust. I know a
> lot of people want rustpkg to be the primary tool, but I feel like it is
> better fit for small projects and libraries. Rustpkg is definitely useful
> for smaller projects and for libraries. What I'd like to see is something
> for managing project dependencies that can be used with any build system
> like CMake or rustpkg.
>
>
> On Thu, Jan 2, 2014 at 8:22 AM, Gaetan <gaetan at xeberon.net> wrote:
>
>> I used cmake for years and was quite happy with it, so a support of cmake
>> is welcomed. I recommend have it "officially" integrated into rust, along
>> with some other popular toolsets (scon, bare makefiles, visual studio,...).
>> Even if VS can derive from cmake. This is a strategic added value to have
>> it provided by the language.
>>
>> I also would like to add I find this complementary to rust-pkg. For
>> simple project, this latter might do the job, but for very complex
>> projects, a full featured build system might be used, so let's have it
>> seamlessly integrated into rust.
>>
>> -----
>> Gaetan
>>
>>
>>
>> 2014/1/2 SiegeLord <slabode at aim.com>
>>
>>> On 01/02/2014 12:05 AM, György Andrasek wrote:
>>>
>>>> The proper way to support a language in CMake is outlined in
>>>> `Modules/CMakeAddNewLanguage.txt`:
>>>>
>>>
>>> I was guided away from that method by this email: http://www.cmake.org/
>>> pipermail/cmake/2011-March/043444.html . My approach is amenable to
>>> generating files for alternative build systems, like ninja. If you are
>>> aware that that email is incorrect, I'm glad to be corrected. Independently
>>> of that email, I have looked into doing it that way, but I found that it
>>> just did not mesh with the Rust compilation model, and I saw no clear way
>>> to using the information given by 'rustc --dep-info' to inform the build
>>> system. Additionally, my macros allow an easy way of doing documentation
>>> generation, which that method doesn't clearly allow.
>>>
>>> I'll be glad to be corrected on all those points though.
>>>
>>> -SL
>>>
>>>
>>> _______________________________________________
>>> Rust-dev mailing list
>>> Rust-dev at mozilla.org
>>> https://mail.mozilla.org/listinfo/rust-dev
>>>
>>
>>
>> _______________________________________________
>> Rust-dev mailing list
>> Rust-dev at mozilla.org
>> https://mail.mozilla.org/listinfo/rust-dev
>>
>>
>
> _______________________________________________
> Rust-dev mailing list
> Rust-dev at mozilla.org
> https://mail.mozilla.org/listinfo/rust-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/rust-dev/attachments/20140102/93660679/attachment-0001.html>


More information about the Rust-dev mailing list