glfs/general/prog/cbindgen.xml
Xi Ruoyao 45ab6c70c2
more SVN prop clean up
Remove "$LastChanged$" everywhere, and also some unused $Date$
2021-04-20 19:12:02 +08:00

160 lines
4.3 KiB
XML

<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
<!ENTITY % general-entities SYSTEM "../../general.ent">
%general-entities;
<!ENTITY cbindgen-download-http "https://github.com/eqrion/cbindgen/archive/v&cbindgen-version;/cbindgen-&cbindgen-version;.tar.gz">
<!ENTITY cbindgen-download-ftp " ">
<!ENTITY cbindgen-md5sum "9eb3e5c1c3adda2a8f1e3eee8d9700e3">
<!ENTITY cbindgen-size "188 KB">
<!ENTITY cbindgen-buildsize "123 MB (add 533 MB for tests)">
<!ENTITY cbindgen-time "0.6 SBU (add 0.4 SBU for tests), both on a 4-core machine">
]>
<sect1 id="cbindgen" xreflabel="Cbindgen-&cbindgen-version;">
<?dbhtml filename="cbindgen.html"?>
<sect1info>
<date>$Date$</date>
</sect1info>
<title>Cbindgen-&cbindgen-version;</title>
<indexterm zone="cbindgen">
<primary sortas="a-cbindgen">cbindgen</primary>
</indexterm>
<sect2 role="package">
<title>Introduction to Cbindgen</title>
<para>
<application>Cbindgen</application> can be used to generate C bindings for
<application>Rust</application> code.
</para>
&lfs101_checked;
<bridgehead renderas="sect3">Package Information</bridgehead>
<itemizedlist spacing="compact">
<listitem>
<para>
Download (HTTP): <ulink url="&cbindgen-download-http;"/>
</para>
</listitem>
<listitem>
<para>
Download (FTP): <ulink url="&cbindgen-download-ftp;"/>
</para>
</listitem>
<listitem>
<para>
Download MD5 sum: &cbindgen-md5sum;
</para>
</listitem>
<listitem>
<para>
Download size: &cbindgen-size;
</para>
</listitem>
<listitem>
<para>
Estimated disk space required: &cbindgen-buildsize;
</para>
</listitem>
<listitem>
<para>
Estimated build time: &cbindgen-time;
</para>
</listitem>
</itemizedlist>
<bridgehead renderas="sect3">cbindgen Dependencies</bridgehead>
<bridgehead renderas="sect4">Required</bridgehead>
<para role="required">
<xref linkend="rust"/>
</para>
<para condition="html" role="usernotes">
User Notes: <ulink url="&blfs-wiki;/cbindgen"/>
</para>
</sect2>
<sect2 role="installation">
<title>Installation of cbindgen</title>
<note>
<para>
As with most <application>Rust</application> packages, this needs a
network connection to check the current versions of the required cargo
crates, and to download them if they are not already present.
</para>
</note>
<para>
Install <application>cbindgen</application> by running the following
commands:
</para>
<screen><userinput>cargo build --release</userinput></screen>
<para>
<!-- 0.16.0 log shows 2 suites where both tests pass, in the third
3 of 6 fail. The suite names are impenetrable. -->
To test the results, issue: <command>cargo test</command>.
Three tests in the final suite are known to fail.
</para>
<para>
Now, as the <systemitem class="username">root</systemitem> user:
</para>
<screen role="root"><userinput>install -Dm755 target/release/cbindgen /usr/bin/</userinput></screen>
</sect2>
<sect2 role="content">
<title>Contents</title>
<segmentedlist>
<segtitle>Installed Program</segtitle>
<segtitle>Installed Library</segtitle>
<segtitle>Installed Directory</segtitle>
<seglistitem>
<seg>
cbindgen
</seg>
<seg>
none
</seg>
<seg>
none
</seg>
</seglistitem>
</segmentedlist>
<variablelist>
<bridgehead renderas="sect3">Short Descriptions</bridgehead>
<?dbfo list-presentation="list"?>
<?dbhtml list-presentation="table"?>
<varlistentry id="cbindgen-prog">
<term><command>cbindgen</command></term>
<listitem>
<para>
generates C bindings for <application>Rust</application> code
</para>
<indexterm zone="cbindgen cbindgen-prog">
<primary sortas="b-cbindgen">cbindgen</primary>
</indexterm>
</listitem>
</varlistentry>
</variablelist>
</sect2>
</sect1>