Building dart sdk from source

629 views
Skip to first unread message

Kevin Segaud

unread,
Aug 18, 2017, 12:27:14 PM8/18/17
to Dart Misc
Hello,

Yesterday i tried to build the dart-sdk for fedora 26 but i got an error.
Here are the step i have done : 

sudo dnf -y install git subversionmake gcc-c++

git clone https
://chromium.googlesource.com/chromium/tools/depot_tools.git
export PATH=$PATH:`pwd`/depot_tools

git clone
-b stable https://github.com/dart-lang/sdk.git
cd sdk
tools
/build.py --mode=release --arch=x64 create_sdk


and here is the error :

gn gen --check in out/ReleaseX64
Traceback (most recent call last):
 
File "/home/kleak/test/sdk/tools/gn.py", line 482, in <module>
 sys
.exit(Main(sys.argv))
 
File "/home/kleak/test/sdk/tools/gn.py", line 469, in Main
 results
= pool.map(RunCommand, commands, chunksize=1)
 
File "/usr/lib64/python2.7/multiprocessing/pool.py", line 251, in map
 
return self.map_async(func, iterable, chunksize).get()
 
File "/usr/lib64/python2.7/multiprocessing/pool.py", line 567, in get
 
raise self._value
OSError: [Errno 2] No such file or directory
Tried to run GN, but it failed. Try running it manually:
 $ python
/home/kleak/test/sdk/tools/gn.py -m release -a x64 --os host -v
Traceback (most recent call last):
 
File "tools/build.py", line 625, in <module>
 sys
.exit(Main())
 
File "tools/build.py", line 618, in Main
 mode
, arch) != 0:
 
File "tools/build.py", line 498, in BuildOneConfig
 args
= BuildNinjaCommand(options, target, target_os, mode, arch)
 
File "tools/build.py", line 473, in BuildNinjaCommand
 
if UseGoma(out_dir):
 
File "tools/build.py", line 431, in UseGoma
 
return 'use_goma = true' in open(args_gn, 'r').read()
IOError: [Errno 2] No such file or directory: 'out/ReleaseX64/args.gn'

I thinks the wiki on this part is little weak especially this part https://github.com/dart-lang/sdk/wiki/Building-Dart-on-CentOS,-Red-Hat,-Fedora-and-Amazon-Linux-AMI#get-the-dart-source-and-generate-makefiles  
If someone can tell me what i do wrong i can update the readme after i have something working :)

Thanks for the help

Jakob Roland Andersen

unread,
Aug 18, 2017, 2:20:33 PM8/18/17
to mi...@dartlang.org
Here's the wiki page that describes how to get the source and build: https://github.com/dart-lang/sdk/wiki/Building

You need to use gclient from the depot_tools to get the code and dependencies. 

Thanks,
Jakob. 

--
For other discussions, see https://groups.google.com/a/dartlang.org/
 
For HOWTO questions, visit http://stackoverflow.com/tags/dart
 
To file a bug report or feature request, go to http://www.dartbug.com/new
---
You received this message because you are subscribed to the Google Groups "Dart Misc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to misc+uns...@dartlang.org.

Kevin Segaud

unread,
Aug 21, 2017, 7:30:09 AM8/21/17
to Dart Misc
Thanks Jakob !

Is there a way to specify stable or dev instead of edge ?

Kevin Millikin

unread,
Aug 21, 2017, 7:56:02 AM8/21/17
to Dart Misc
Stable and dev channel releases should be tagged, so you should be able to do `git checkout 1.24.2` or `git checkout 1.25.0-dev.11.0` and then build the (current) stable or dev channel.

On Mon, Aug 21, 2017 at 1:30 PM, Kevin Segaud <segaud...@gmail.com> wrote:
Thanks Jakob !

Is there a way to specify stable or dev instead of edge ?

Reply all
Reply to author
Forward
0 new messages