diff --git a/config.example.toml b/config.example.toml
index f315b5539c6f..8d0958b79743 100644
--- a/config.example.toml
+++ b/config.example.toml
@@ -882,3 +882,9 @@ change-id = 115898
# Name of the AWS S3 bucket containing the document signatures file.
#document-signatures-s3-bucket = "ferrocene-document-signatures"
+
+# The following serves two purposes when set to true:
+# - Avoids "Unsigned draft" warning in Qualification docs, when they are not signed
+# - Avoids an error that occurs if signatures are present,
+# but you don't have access to the private signature files
+#ignore-document-signatures = false
diff --git a/ferrocene/doc/index/index.html b/ferrocene/doc/index/index.html
index e17594effb29..6b34b575be80 100644
--- a/ferrocene/doc/index/index.html
+++ b/ferrocene/doc/index/index.html
@@ -100,7 +100,7 @@
Document List
The reference list of documents used for the qualification dossier
diff --git a/ferrocene/doc/qualification-report/src/tests.rst b/ferrocene/doc/qualification-report/src/tests.rst
index 06353dfd2ed6..bcb4d53ea8f2 100644
--- a/ferrocene/doc/qualification-report/src/tests.rst
+++ b/ferrocene/doc/qualification-report/src/tests.rst
@@ -27,8 +27,8 @@ For this qualification, testing is restricted to the following environment:
.. note::
- For the Rust language, only the Rust standard as described in the
- Ferrocene :doc:`Language Specification document `
+ Only the Rust language,
+ as described in the :doc:`specification:index`,
is verified.
Bare metal testing
diff --git a/ferrocene/doc/safety-manual/src/environment.rst b/ferrocene/doc/safety-manual/src/environment.rst
index 3af8e222d142..5237be175afb 100644
--- a/ferrocene/doc/safety-manual/src/environment.rst
+++ b/ferrocene/doc/safety-manual/src/environment.rst
@@ -27,9 +27,11 @@ end-use code is outside the scope of the current Ferrocene qualification. It
is the end-user responsibility to qualify these libraries if they are used in
their code.
-.. Note::
- For the Rust language, only the Rust standard as described in the
- Ferrocene :doc:`Language Specification document `.
+.. note::
+
+ Only the Rust language,
+ as described in the :doc:`specification:index`,
+ is verified.
The qualification scope is limited to the set of supported compilation options
described in the :doc:`Tool Options `.
diff --git a/ferrocene/doc/safety-manual/src/options.rst b/ferrocene/doc/safety-manual/src/options.rst
index d5a7a47ae4fd..f5563c6eb8f3 100644
--- a/ferrocene/doc/safety-manual/src/options.rst
+++ b/ferrocene/doc/safety-manual/src/options.rst
@@ -39,6 +39,6 @@ defined and tested by the Ferrocene testsuite.
If the end user requires CLI options other than those identified in this
chapter, they must verify that the feature exists and is compatible with their
-target, that their safety context is compatible with the use of CLI option or
+target, that their safety context is compatible with the use of the CLI option or
feature, and develop appropriate verification activities and tests to ensure
the correct functionality of the generated code.
diff --git a/ferrocene/library/libc/.github/workflows/bors.yml b/ferrocene/library/libc/.github/workflows/bors.yml
index cc0bb667bdf2..e171f7e6789e 100644
--- a/ferrocene/library/libc/.github/workflows/bors.yml
+++ b/ferrocene/library/libc/.github/workflows/bors.yml
@@ -335,24 +335,6 @@ jobs:
- name: Build with check-cfg
run: LIBC_CI=1 LIBC_CHECK_CFG=1 cargo build -Z unstable-options -Z check-cfg=features,names,values,output
- docs:
- permissions:
- actions: write # to cancel workflows (rust-lang/simpleinfra/github-actions/cancel-outdated-builds)
- contents: read # to fetch code (actions/checkout)
-
- name: Generate documentation
- runs-on: ubuntu-22.04
- needs: docker_linux_tier2
- steps:
- - uses: rust-lang/simpleinfra/github-actions/cancel-outdated-builds@HEAD
- with:
- github_token: "${{ secrets.GITHUB_TOKEN }}"
- - uses: actions/checkout@v3
- - name: Setup Rust toolchain
- run: sh ./ci/install-rust.sh
- - name: Generate documentation
- run: LIBC_CI=1 sh ci/dox.sh
-
# These jobs doesn't actually test anything, but they're only used to tell
# bors the build completed, as there is no practical way to detect when a
# workflow is successful listening to webhooks only.
@@ -374,7 +356,6 @@ jobs:
build_channels_linux,
build_channels_macos,
build_channels_windows,
- docs,
]
steps:
@@ -396,7 +377,6 @@ jobs:
build_channels_linux,
build_channels_macos,
build_channels_windows,
- docs,
]
steps:
diff --git a/ferrocene/library/libc/.github/workflows/docs.yml b/ferrocene/library/libc/.github/workflows/docs.yml
deleted file mode 100644
index ff722bc96e74..000000000000
--- a/ferrocene/library/libc/.github/workflows/docs.yml
+++ /dev/null
@@ -1,37 +0,0 @@
-name: Upload documentation to GitHub Pages
-
-on:
- push:
- branches:
- - main
-
-# Sets permissions of `GITHUB_TOKEN` to allow deployment to GitHub Pages
-permissions:
- contents: read
- pages: write
- id-token: write
-
-jobs:
- deploy:
- environment:
- name: github-pages
- url: ${{ steps.deployment.outputs.page_url }}
- runs-on: ubuntu-22.04
- steps:
- - name: Checkout
- uses: actions/checkout@v3
- - name: Setup Rust toolchain
- run: TARGET=x86_64-unknown-linux-gnu sh ./ci/install-rust.sh
- - name: Generate documentation
- run: LIBC_CI=1 sh ci/dox.sh
- - name: Setup Pages
- uses: actions/configure-pages@v3
- - name: Fix permissions
- run: rm -f ./target/doc/.lock
- - name: Upload artifact
- uses: actions/upload-pages-artifact@v2
- with:
- path: 'target/doc'
- - name: Deploy to GitHub Pages
- id: deployment
- uses: actions/deploy-pages@v2
diff --git a/ferrocene/library/libc/README.md b/ferrocene/library/libc/README.md
index 43d706d0f2a6..29d2a4b6160f 100644
--- a/ferrocene/library/libc/README.md
+++ b/ferrocene/library/libc/README.md
@@ -60,7 +60,7 @@ newer Rust features are only available on newer Rust toolchains:
## Platform support
-[Platform-specific documentation (HEAD)][docs.head].
+You can see the platform(target)-specific docs on [docs.rs], select a platform you want to see.
See
[`ci/build.sh`](https://github.com/rust-lang/libc/blob/HEAD/ci/build.sh)
@@ -107,4 +107,3 @@ dual licensed as above, without any additional terms or conditions.
[Documentation]: https://docs.rs/libc/badge.svg
[docs.rs]: https://docs.rs/libc
[License]: https://img.shields.io/crates/l/libc.svg
-[docs.head]: https://rust-lang.github.io/libc/#platform-specific-documentation
diff --git a/ferrocene/library/libc/ci/dox.sh b/ferrocene/library/libc/ci/dox.sh
deleted file mode 100644
index 6dd1e4a2282c..000000000000
--- a/ferrocene/library/libc/ci/dox.sh
+++ /dev/null
@@ -1,82 +0,0 @@
-#!/usr/bin/env sh
-
-# Builds documentation for all target triples that we have a registered URL for
-# in liblibc. This scrapes the list of triples to document from `src/lib.rs`
-# which has a bunch of `html_root_url` directives we pick up.
-
-set -ex
-
-TARGET_DOC_DIR="target/doc"
-README="README.md"
-PLATFORM_SUPPORT="platform-support.md"
-
-rm -rf "$TARGET_DOC_DIR"
-mkdir -p "$TARGET_DOC_DIR"
-
-if ! rustc --version | grep -E "nightly" ; then
- echo "Building the documentation requires a nightly Rust toolchain"
- exit 1
-fi
-
-rustup component add rust-src
-
-# List all targets that do currently build successfully:
-# shellcheck disable=SC1003
-grep '[\d|\w|-]* \\' ci/build.sh > targets
-sed -i.bak 's/ \\//g' targets
-grep '^[_a-zA-Z0-9-]*$' targets | sort > tmp && mv tmp targets
-
-# Create a markdown list of supported platforms in $PLATFORM_SUPPORT
-rm $PLATFORM_SUPPORT || true
-
-printf '### Platform-specific documentation\n' >> $PLATFORM_SUPPORT
-
-while read -r target; do
- echo "documenting ${target}"
-
- case "${target}" in
- *apple*)
- # FIXME:
- # We can't build docs of apple targets from Linux yet.
- continue
- ;;
- *)
- ;;
- esac
-
- rustup target add "${target}" || true
-
- # Enable extra configuration flags:
- export RUSTDOCFLAGS="--cfg freebsd11"
-
- # If cargo doc fails, then try with unstable feature:
- if ! cargo doc --target "${target}" \
- --no-default-features --features const-extern-fn,extra_traits ; then
- cargo doc --target "${target}" \
- -Z build-std=core,alloc \
- --no-default-features --features const-extern-fn,extra_traits
- fi
-
- mkdir -p "${TARGET_DOC_DIR}/${target}"
- cp -r "target/${target}/doc" "${TARGET_DOC_DIR}/${target}"
-
- echo "* [${target}](${target}/doc/libc/index.html)" >> $PLATFORM_SUPPORT
-done < targets
-
-# Replace with the contents of $PLATFORM_SUPPORT
-cp $README $TARGET_DOC_DIR
-line=$(grep -n '' $README | cut -d ":" -f 1)
-
-{ head -n "$((line-1))" $README; cat $PLATFORM_SUPPORT; tail -n "+$((line+1))" $README; } > $TARGET_DOC_DIR/$README
-
-cp $TARGET_DOC_DIR/$README $TARGET_DOC_DIR/index.md
-
-RUSTDOCFLAGS="--enable-index-page --index-page=${TARGET_DOC_DIR}/index.md -Zunstable-options" cargo doc
-
-# Tweak style
-cp ci/rust.css $TARGET_DOC_DIR
-sed -ie "8i " $TARGET_DOC_DIR/index.html
-sed -ie "9i " $TARGET_DOC_DIR/index.html
-
-# Copy the licenses
-cp LICENSE-* $TARGET_DOC_DIR/
diff --git a/ferrocene/library/libc/src/lib.rs b/ferrocene/library/libc/src/lib.rs
index 538523bec619..04d046dcf0dd 100644
--- a/ferrocene/library/libc/src/lib.rs
+++ b/ferrocene/library/libc/src/lib.rs
@@ -1,8 +1,4 @@
//! libc - Raw FFI bindings to platforms' system libraries
-//!
-//! [Documentation for other platforms][pd].
-//!
-//! [pd]: https://rust-lang.github.io/libc/#platform-specific-documentation
#![crate_name = "libc"]
#![crate_type = "rlib"]
#![allow(
diff --git a/ferrocene/library/libc/src/teeos/mod.rs b/ferrocene/library/libc/src/teeos/mod.rs
index 13d8ce1b8ffd..cffe04197657 100644
--- a/ferrocene/library/libc/src/teeos/mod.rs
+++ b/ferrocene/library/libc/src/teeos/mod.rs
@@ -8,6 +8,8 @@
// only supported on Rust > 1.59, so we can directly reexport c_void from core.
pub use core::ffi::c_void;
+use Option;
+
pub type c_schar = i8;
pub type c_uchar = u8;