Changeset a7b1bddc
- Timestamp:
- 04/14/2018 01:41:40 AM (6 years ago)
- Branches:
- 10.0, 10.1, 11.0, 11.1, 11.2, 11.3, 12.0, 12.1, 8.3, 8.4, 9.0, 9.1, basic, bdubbs/svn, elogind, kea, ken/TL2024, ken/inkscape-core-mods, ken/tuningfonts, lazarus, lxqt, perl-modules, plabs/newcss, plabs/python-mods, python3.11, qt5new, rahul/power-profiles-daemon, renodr/vulkan-addition, trunk, upgradedb, xry111/intltool, xry111/llvm18, xry111/soup3, xry111/test-20220226, xry111/xf86-video-removal
- Children:
- 798c542
- Parents:
- f5a3b39
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
general/prog/rust.xml
rf5a3b39 ra7b1bddc 7 7 <!ENTITY rust-download-http "https://static.rust-lang.org/dist/rustc-&rust-version;-src.tar.gz"> 8 8 <!ENTITY rust-download-ftp " "> 9 <!ENTITY rust-md5sum " 7272ddba14f512e6d2612ef60460bed8">10 <!ENTITY rust-size " 53MB">11 <!ENTITY rust-buildsize " 4.1 GB (437 MB installed), (add 1.2GB for tests) including 226MB of ~/.cargo files for both the builder and root (from the install)">12 <!ENTITY rust-time " 48 SBU (add 12 SBU for tests, both with 4 processors)">9 <!ENTITY rust-md5sum "d8d4d30c8d0b905f978bee3fdd618db5"> 10 <!ENTITY rust-size "95 MB"> 11 <!ENTITY rust-buildsize "5.1 GB (440 MB installed) including 379MB of ~/.cargo files for the user building this and 440MB of files in the DESTDIR (add 1.2GB if running the tests)"> 12 <!ENTITY rust-time "33 SBU (add 17 SBU for tests, both with 4 processors)"> 13 13 ]> 14 14 … … 37 37 <para> 38 38 As with many other programming languages, rustc (the rust compiler) 39 needs a binary from which to bootstrap. It will download a stage0 binary ,40 and several cargo files (these are actually .tar.gz source archives) at39 needs a binary from which to bootstrap. It will download a stage0 binary 40 and many cargo crates (these are actually .tar.gz source archives) at 41 41 the start of the build, so you cannot compile it without an internet 42 42 connection. … … 59 59 of build times. Some of this might be due to variations in downloading 60 60 the required cargo files if they are not already present, but this does 61 not seem to adequately explain the variations. Also, both the builder 62 and the user running the install will need to download the cargo crates 63 if they are not already present in <filename>~/.cargo</filename>. 61 not seem to adequately explain the variations. 64 62 </para> 65 63 <para> 66 If you use a DESTDIR method to install, you will only need to download 67 the crates once, for the build, saving about one-third of the build and 68 install time (but using extra space for the install). Similarly if you 69 were to build as root, or if your user is allowed to run <command>sudo 70 ./x.py install</command> - but those methods are dangerous. 64 Unusually, a DESTDIR method is being used to install this package. This 65 is because running the install as root not only downloads all of the 66 cargo files again (to <filename>/root/.cargo</filename>), it then spends 67 a very long time recompiling. Using a DESTDIR method saves 30 SBU on the 68 4-core machine where this was tested, at the cost of an extra 60MB of 69 disk space for the extra files. 71 70 </para> 72 71 </note> … … 114 113 <xref linkend="curl"/>, 115 114 <xref linkend="cmake"/>, 116 <!-- if changing this to use python3, also add python2 as a required 117 dependency for firefox, because at the moment it picks that up from here --> 115 <!-- Although this appears to build with python3, there are sometimes strange 116 script errors in the compilation (i.e. it exits after the build, without 117 any obvious errors and with a good status. Also ,it ships with a configure 118 script which invokes python2.7 to create config.toml, and some of the files 119 in the package use python2.7. --> 118 120 <xref linkend="python2"/> 121 </para> 122 123 <bridgehead renderas="sect4">Recommended</bridgehead> 124 <para role="recommended"> 125 <package>clang</package> from <xref linkend="llvm"/> 119 126 </para> 120 127 … … 151 158 targets = "X86" 152 159 160 # When using system llvm prefer shared libraries 161 link-shared = true 162 153 163 [build] 154 164 # install cargo as well as rust … … 162 172 channel = "stable" 163 173 rpath = false 174 175 # get reasonably clean output from the test harness 176 quiet-tests = true 177 178 # BLFS does not install the FileCheck executable from llvm, 179 # so disable codegen tests 180 codegen-tests = false 181 182 [target.x86_64-unknown-linux-gnu] 183 # delete this *section* if you are not using system llvm. 184 # NB the output of llvm-config (i.e. help options) may be 185 # dumped to the screen when config.toml is parsed. 186 llvm-config = "/usr/bin/llvm-config" 187 164 188 EOF</userinput></screen> 165 189 … … 170 194 171 195 <screen><userinput>./x.py build</userinput></screen> 196 197 <para> 198 The build will report it failed to compile <filename>miri</filename> 199 because of multiple potential crates for `log`, but that should be followed 200 by a message that the build completed successfully. 201 </para> 202 203 <caution> 204 <para> 205 On AMD Ryzen processors (family 17h), the non-optimized version of libstd 206 which is compiled at the start of the tests contains two opcodes which are 207 not implemented on this CPU family. These will be logged in the 208 <phrase revision="sysv">system log</phrase> 209 <phrase revision="systemd">systemd journal</phrase> 210 and will be followed a few minutes later by segmentation faults. Despite 211 that, the tests continue to run, apparently normally. But the system may 212 reboot before the tests have completed. The normal optimized libraries 213 run without this problem. 214 </para> 215 <para> 216 A mitigation is to install gdb 217 <!-- systemd apparently handles this with systemd-coredump --> 218 <phrase revision="sysv">and to run the tests with 'ulimit -C disabled'</phrase> 219 but this does not always prevent the system rebooting. 220 </para> 221 </caution> 172 222 173 223 <para> … … 175 225 <command>./x.py test --verbose --no-fail-fast >../rustc-testlog</command>: 176 226 as with the build, that will use all available CPUs. This runs many suites 177 of tests (in an apparently random order), three may fail: 178 compile-fail/issue-37131.rs and run-make/target-without-atomics both try to 179 compile for the thumbv6m-none-eabi target, but the BLFS build does not cater for 180 that, and all 105 tests in debuginfo-gdb will fail if 181 <application>gdb</application> has not been installed. Several other tests in 182 run-make can also fail. With <application>glibc-2.27</application> the stack 183 guard page has been moved to just beyond the stack, instead of within it. That 184 causes three run-pass tests (out-of-stack.rs, stack-probes-lto.rs, 185 stack-probes.rs) to fail. 227 of tests (in an apparently random order), at least one will fail: 228 compile-fail/issue-37131.rs tries to 229 compile for the thumbv6m-none-eabi target but the BLFS build does not cater for 230 that, and many tests in debuginfo-gdb will fail if 231 <application>gdb</application> has not been installed. A few other tests might 232 fail. 186 233 </para> 187 234 … … 194 241 195 242 <para> 196 That should report 1 4854 tests. Similarly, the total tests which failed can243 That should report 13224 tests. Similarly, the total tests which failed can 197 244 be found by running: 198 245 </para> … … 207 254 208 255 <para> 209 Now, as the <systemitem class="username">root</systemitem> user: 210 </para> 211 212 <screen role="root"><userinput>./x.py install</userinput></screen> 256 Still as your normal user, do a DESTDIR install: 257 </para> 258 259 <screen><userinput>mkdir -v /sources/RUST && 260 DESTDIR=/sources/RUST ./x.py install</userinput></screen> 261 262 <para> 263 Now, as the <systemitem class="username">root</systemitem> user 264 install the files from the DESTDIR: 265 </para> 266 267 <screen role="root"><userinput>chown -R root:root /sources/RUST && 268 cp -a /sources/RUST/* /</userinput></screen> 269 213 270 </sect2> 214 271 … … 218 275 <para> 219 276 <command>targets = "X86"</command>: this avoids building all the available 220 linux cross-compilers (Aarch64, MIPS, PowerPC, SystemZ, etc). 277 linux cross-compilers (Aarch64, MIPS, PowerPC, SystemZ, etc). Unfortunately, 278 rust insists on installing source files for these below 279 <filename class="directory">/usr/lib/rustlib/src</filename>. 221 280 </para> 222 281 … … 240 299 241 300 <para> 301 <command>[target.x86_64-unknown-linux-gnu]</command>: the syntax of 302 <filename>config.toml</filename> requires an <literal>llvm-config</literal> 303 entry for each target for which system-llvm is to be used. Change the target 304 to <literal>[target.i686-unknown-linux-gnu]</literal> if you are building 305 on 32-bit x86. This whole section may be omitted if you wish to build 306 against the shipped llvm, or do not have clang, but the resulting build will 307 be larger and take a little longer. 308 </para> 309 310 <para> 242 311 <command>--verbose</command>: this switch can sometimes provide more 243 312 information about a test which fails. … … 250 319 251 320 <para> 252 <option>PYTHON=/usr/bin/python3 ... tee buildlog</option>: Because rust 253 can use <application>Python3</application> which was installed in LFS, 254 this command tells it to use that instead of the deprecated 255 <application>Python2</application>. For the moment this should be regarded 256 as experimental and problems may be encountered. Because 257 <application>rust</application> will use all CPUs, if an error happened the 258 message may have scrolled out of the terminal's buffer. Logging makes it 259 possible to find out what was reported. 321 <command>mkdir -v /sources/RUST</command>: this is not strictly necessary, 322 but it confirms that your regular user can write there, and that there is 323 not an existing directory of this name left over from a previous install. 324 By convention, BLFS builds in <filename class="directory">/sources</filename> 325 but you can change this to another location where you can write (and 326 similarly change the commands used by 327 <systemitem class="username">root</systemitem>). Note that DESTDIR installs 328 need an absolute path, passing e.g. ../RUST will not work. 329 </para> 330 331 <para> 332 <command>chown -R root:root /sources/RUST</command>: the DESTDIR install 333 was run by a regular user, who owns the files. For security, change their 334 owner before doing a simple copy to install them. 260 335 </para> 261 336 … … 272 347 <seglistitem> 273 348 <seg> 274 cargo , rls, rust-gdb, rust-lldb, rustc, rustdoc.349 cargo-fmt, cargo, rls, rust-gdb, rust-lldb, rustc, rustdoc, rustfmt. 275 350 </seg> 276 351 <seg> … … 291 366 <?dbhtml list-presentation="table"?> 292 367 368 <varlistentry id="cargo-fmt"> 369 <term><command>cargo-fmt</command></term> 370 <listitem> 371 <para> 372 formats all bin and lib files of the current crate using 373 rustfmt. 374 </para> 375 <indexterm zone="rust cargo-fmt"> 376 <primary sortas="b-cargo-fmt">cargo-fmt</primary> 377 </indexterm> 378 </listitem> 379 </varlistentry> 380 293 381 <varlistentry id="cargo"> 294 382 <term><command>cargo</command></term> … … 321 409 <listitem> 322 410 <para> 323 is a Python wrapper script for gdb. 411 is a wrapper script for gdb, pulling in Python 412 pretty-printing modules installed in <filename 413 class="directory">/usr/lib/rustlib/etc</filename>. 324 414 </para> 325 415 <indexterm zone="rust rust-gdb"> … … 333 423 <listitem> 334 424 <para> 335 is a Python wrapper script for LLDB (the LLVM debugger). 425 is a wrapper script for LLDB (the LLVM debugger) 426 pulling in the Python pretty-printing modules. 336 427 </para> 337 428 <indexterm zone="rust rust-lldb"> … … 361 452 <indexterm zone="rust rustdoc"> 362 453 <primary sortas="b-rustdoc">rustdoc</primary> 454 </indexterm> 455 </listitem> 456 </varlistentry> 457 458 <varlistentry id="rustfmt"> 459 <term><command>rustfmt</command></term> 460 <listitem> 461 <para> 462 formats rust code. 463 </para> 464 <indexterm zone="rust rustfmt"> 465 <primary sortas="b-rustfmt">rustfmt</primary> 363 466 </indexterm> 364 467 </listitem> -
introduction/welcome/changelog.xml
rf5a3b39 ra7b1bddc 46 46 <itemizedlist> 47 47 <listitem> 48 <para>[ken] - Update to rustc-1.25.0 (will be needed when 49 firefox-60 is used). Fixes 50 <ulink url="&blfs-ticket-root;10624">#10624</ulink>.</para> 51 </listitem> 52 <listitem> 48 53 <para>[bdubbs] - Update to geoclue-2.4.8. Fixes 49 54 <ulink url="&blfs-ticket-root;10659">#10659</ulink>.</para> -
packages.ent
rf5a3b39 ra7b1bddc 333 333 <!ENTITY ruby-patch-version "1"> 334 334 <!ENTITY ruby-version "&ruby-minor-version;.&ruby-patch-version;"> 335 <!ENTITY rust-version "1.2 2.1">335 <!ENTITY rust-version "1.25.0"> 336 336 <!ENTITY scons-version "3.0.0"> 337 337 <!ENTITY slang-version "2.3.2">
Note:
See TracChangeset
for help on using the changeset viewer.