Merge branch 'master' into update_5_0
This commit is contained in:
commit
7fe5d71764
9 changed files with 159 additions and 34 deletions
|
@ -23,7 +23,7 @@ task:
|
|||
- cd raylib-c
|
||||
- mkdir build
|
||||
- cd build
|
||||
- cmake -DBUILD_EXAMPLES=off -DINCLUDE_EVERYTHING=on -DSUPPORT_FILEFORMAT_JPG=on -DWITH_PIC=on -DCMAKE_BUILD_TYPE=Release ..
|
||||
- cmake -DBUILD_EXAMPLES=OFF -DCUSTOMIZE_BUILD=ON -DSUPPORT_FILEFORMAT_JPG=ON -DSUPPORT_FILEFORMAT_FLAC=ON -DWITH_PIC=ON -DCMAKE_BUILD_TYPE=Release ..
|
||||
- make -j8
|
||||
- sudo make install
|
||||
build_script:
|
||||
|
|
8
.github/workflows/build.yml
vendored
8
.github/workflows/build.yml
vendored
|
@ -38,7 +38,7 @@ jobs:
|
|||
cd raylib-c
|
||||
mkdir build
|
||||
cd build
|
||||
cmake -DBUILD_EXAMPLES=off -DINCLUDE_EVERYTHING=on -DSUPPORT_FILEFORMAT_JPG=on -DWITH_PIC=on -DCMAKE_BUILD_TYPE=Release ..
|
||||
cmake -DBUILD_EXAMPLES=OFF -DCUSTOMIZE_BUILD=ON -DSUPPORT_FILEFORMAT_JPG=ON -DSUPPORT_FILEFORMAT_FLAC=ON -DWITH_PIC=ON -DCMAKE_BUILD_TYPE=Release ..
|
||||
make -j2
|
||||
sudo make install
|
||||
|
||||
|
@ -189,7 +189,7 @@ jobs:
|
|||
cd raylib-c
|
||||
mkdir build
|
||||
cd build
|
||||
cmake -DBUILD_EXAMPLES=off -DINCLUDE_EVERYTHING=on -DSUPPORT_FILEFORMAT_JPG=on -DWITH_PIC=on -DCMAKE_BUILD_TYPE=Release -DOpenGL_GL_PREFERENCE=GLVND ..
|
||||
cmake -DBUILD_EXAMPLES=OFF -DCUSTOMIZE_BUILD=ON -DSUPPORT_FILEFORMAT_JPG=ON -DSUPPORT_FILEFORMAT_FLAC=ON -DWITH_PIC=ON -DCMAKE_BUILD_TYPE=Release -DOpenGL_GL_PREFERENCE=GLVND ..
|
||||
make -j2
|
||||
sudo make install
|
||||
- name: Copy extras
|
||||
|
@ -273,7 +273,7 @@ jobs:
|
|||
cd raylib-c
|
||||
mkdir build
|
||||
cd build
|
||||
cmake -DBUILD_EXAMPLES=off -DINCLUDE_EVERYTHING=on -DSUPPORT_FILEFORMAT_JPG=on -DWITH_PIC=on -DCMAKE_BUILD_TYPE=Release ..
|
||||
cmake -DBUILD_EXAMPLES=OFF -DCUSTOMIZE_BUILD=ON -DSUPPORT_FILEFORMAT_JPG=ON -DSUPPORT_FILEFORMAT_FLAC=ON -DWITH_PIC=ON -DCMAKE_BUILD_TYPE=Release ..
|
||||
msbuild raylib.sln /target:raylib /property:Configuration=Release
|
||||
copy raylib\Release\raylib.lib ..\..
|
||||
cd ..\..
|
||||
|
@ -322,7 +322,7 @@ jobs:
|
|||
cd raylib-c
|
||||
mkdir build
|
||||
cd build
|
||||
cmake -DINCLUDE_EVERYTHING=on -DSUPPORT_FILEFORMAT_JPG=on -DWITH_PIC=on -DCMAKE_BUILD_TYPE=Release ..
|
||||
cmake -DBUILD_EXAMPLES=OFF -DCUSTOMIZE_BUILD=ON -DSUPPORT_FILEFORMAT_JPG=ON -DSUPPORT_FILEFORMAT_FLAC=ON -DWITH_PIC=ON -DCMAKE_BUILD_TYPE=Release ..
|
||||
make -j2
|
||||
sudo make install
|
||||
- name: Copy extras
|
||||
|
|
48
RPI.rst
48
RPI.rst
|
@ -3,6 +3,9 @@ Raspberry Pi
|
|||
|
||||
Please use Raspberry Pi OS Bullseye. Older OSes are not tested.
|
||||
|
||||
Binary wheel
|
||||
------------
|
||||
|
||||
We have published a binary wheel using Raylib in X11 mode. This *should* install and work on Bullseye
|
||||
with
|
||||
|
||||
|
@ -10,30 +13,59 @@ with
|
|||
|
||||
python3.9 -m pip install raylib==4.2.1.2
|
||||
|
||||
If it doesn't work, or we haven't published a binary wheel for the latest version,
|
||||
If it doesn't work, or you're not on Bullseye, or you want a newer version,
|
||||
or if you want to use Raylib in ``PLATFORM_DRM`` mode, you will need to compile your own raylib.
|
||||
For full instructins on this, see https://github.com/raysan5/raylib/wiki/Working-on-Raspberry-Pi . If you need help with this ask Raylib.
|
||||
For full instructions on this, see https://github.com/raysan5/raylib/wiki/Working-on-Raspberry-Pi . If you need help with this ask Raylib.
|
||||
|
||||
This 'worked for me':
|
||||
Compile Raylib from source DRM mode
|
||||
-----------------------------------
|
||||
|
||||
As far as I can tell, Raylib DRM is broken. It doesn't work on my Pi. However, if you want to compile it and
|
||||
give it a go, these are the commands:
|
||||
|
||||
::
|
||||
|
||||
git clone https://github.com/raysan5/raylib.git --branch 4.2.0 --single-branch
|
||||
git clone https://github.com/raysan5/raylib.git --branch 5.0 --single-branch
|
||||
cd raylib
|
||||
mkdir build
|
||||
rm rf build/*
|
||||
cd build
|
||||
cmake -DPLATFORM="DRM" -DINCLUDE_EVERYTHING=on -DSUPPORT_FILEFORMAT_JPG=on -DWITH_PIC=on -DCMAKE_BUILD_TYPE=Release ..
|
||||
cmake -DPLATFORM="DRM" -DBUILD_EXAMPLES=OFF -DCUSTOMIZE_BUILD=ON -DSUPPORT_FILEFORMAT_JPG=ON -DSUPPORT_FILEFORMAT_FLAC=ON -DWITH_PIC=ON -DCMAKE_BUILD_TYPE=Release ..
|
||||
make
|
||||
sudo make install
|
||||
|
||||
Then have pip compile the wheel:
|
||||
Then have pip compile and install the wheel with some extra linker flags:
|
||||
|
||||
::
|
||||
|
||||
sudo apt update
|
||||
sudo apt install python3-pip
|
||||
pip3 install setuptools
|
||||
pip3 install --no-cache-dir --no-binary raylib --upgrade --force-reinstall raylib==4.2.1.2
|
||||
LDFLAGS="-lgbm -ldrm -lEGL" pip3 install --no-cache-dir --no-binary raylib --upgrade --force-reinstall raylib==5.0.0.0
|
||||
|
||||
Compile Raylib from source X11 mode
|
||||
-----------------------------------
|
||||
|
||||
::
|
||||
|
||||
git clone https://github.com/raysan5/raylib.git --branch 5.0 --single-branch
|
||||
cd raylib
|
||||
mkdir build
|
||||
rm -rf build/*
|
||||
cd build
|
||||
cmake -DPLATFORM="Desktop" -DOPENGL_VERSION=2.1 -DBUILD_EXAMPLES=OFF -DCUSTOMIZE_BUILD=ON -DSUPPORT_FILEFORMAT_JPG=ON -DSUPPORT_FILEFORMAT_FLAC=ON -DWITH_PIC=ON -DCMAKE_BUILD_TYPE=Release ..
|
||||
make
|
||||
sudo make install
|
||||
|
||||
Then have pip compile and install the wheel:
|
||||
|
||||
::
|
||||
|
||||
sudo apt update
|
||||
sudo apt install python3-pip
|
||||
pip3 install setuptools
|
||||
pip3 install --no-cache-dir --no-binary raylib --upgrade --force-reinstall raylib==5.0.0.0
|
||||
|
||||
(or newer version)
|
||||
|
||||
.. attention::
|
||||
|
||||
|
|
|
@ -81,7 +81,7 @@ for name, attr in getmembers(rl):
|
|||
param_name = str(arg.cname).split("(", 1)[0] + "_callback_" + str(i)
|
||||
else:
|
||||
param_name = arg.cname.replace("struct", "").replace("char *", "str").replace("*",
|
||||
"_pointer").replace(" ", "")+"_"+str(i)
|
||||
"_pointer").replace(" ", "")+"_"+str(i)
|
||||
if 'params' in json_object:
|
||||
p = json_object['params']
|
||||
#print("param_name: ", param_name, "i", i, "params: ",p,file=sys.stderr)
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# Sphinx build info version 1
|
||||
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
|
||||
config: 8e8e2ae70cfdafe847109eb2350c2a24
|
||||
config: 3913c2f047571a901ddbfa6c10a1afeb
|
||||
tags: 645f666f9bcd5a90fca523b33c5a78b7
|
||||
|
|
|
@ -61,7 +61,12 @@
|
|||
<li class="toctree-l1"><a class="reference internal" href="raylib.html">C API</a></li>
|
||||
<li class="toctree-l1"><a class="reference internal" href="dynamic.html">Dynamic Bindings</a></li>
|
||||
<li class="toctree-l1"><a class="reference internal" href="BUILDING.html">Building from source</a></li>
|
||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">Raspberry Pi</a></li>
|
||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">Raspberry Pi</a><ul>
|
||||
<li class="toctree-l2"><a class="reference internal" href="#binary-wheel">Binary wheel</a></li>
|
||||
<li class="toctree-l2"><a class="reference internal" href="#compile-raylib-from-source-drm-mode">Compile Raylib from source DRM mode</a></li>
|
||||
<li class="toctree-l2"><a class="reference internal" href="#compile-raylib-from-source-x11-mode">Compile Raylib from source X11 mode</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
|
@ -91,36 +96,65 @@
|
|||
<section id="raspberry-pi">
|
||||
<h1>Raspberry Pi<a class="headerlink" href="#raspberry-pi" title="Link to this heading"></a></h1>
|
||||
<p>Please use Raspberry Pi OS Bullseye. Older OSes are not tested.</p>
|
||||
<section id="binary-wheel">
|
||||
<h2>Binary wheel<a class="headerlink" href="#binary-wheel" title="Link to this heading"></a></h2>
|
||||
<p>We have published a binary wheel using Raylib in X11 mode. This <em>should</em> install and work on Bullseye
|
||||
with</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">python3</span><span class="mf">.9</span> <span class="o">-</span><span class="n">m</span> <span class="n">pip</span> <span class="n">install</span> <span class="n">raylib</span><span class="o">==</span><span class="mf">4.2.1.2</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<p>If it doesn’t work, or we haven’t published a binary wheel for the latest version,
|
||||
<p>If it doesn’t work, or you’re not on Bullseye, or you want a newer version,
|
||||
or if you want to use Raylib in <code class="docutils literal notranslate"><span class="pre">PLATFORM_DRM</span></code> mode, you will need to compile your own raylib.
|
||||
For full instructins on this, see <a class="reference external" href="https://github.com/raysan5/raylib/wiki/Working-on-Raspberry-Pi">https://github.com/raysan5/raylib/wiki/Working-on-Raspberry-Pi</a> . If you need help with this ask Raylib.</p>
|
||||
<p>This ‘worked for me’:</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">git</span> <span class="n">clone</span> <span class="n">https</span><span class="p">:</span><span class="o">//</span><span class="n">github</span><span class="o">.</span><span class="n">com</span><span class="o">/</span><span class="n">raysan5</span><span class="o">/</span><span class="n">raylib</span><span class="o">.</span><span class="n">git</span> <span class="o">--</span><span class="n">branch</span> <span class="mf">4.2.0</span> <span class="o">--</span><span class="n">single</span><span class="o">-</span><span class="n">branch</span>
|
||||
For full instructions on this, see <a class="reference external" href="https://github.com/raysan5/raylib/wiki/Working-on-Raspberry-Pi">https://github.com/raysan5/raylib/wiki/Working-on-Raspberry-Pi</a> . If you need help with this ask Raylib.</p>
|
||||
</section>
|
||||
<section id="compile-raylib-from-source-drm-mode">
|
||||
<h2>Compile Raylib from source DRM mode<a class="headerlink" href="#compile-raylib-from-source-drm-mode" title="Link to this heading"></a></h2>
|
||||
<p>As far as I can tell, Raylib DRM is broken. It doesn’t work on my Pi. However, if you want to compile it and
|
||||
give it a go, these are the commands:</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">git</span> <span class="n">clone</span> <span class="n">https</span><span class="p">:</span><span class="o">//</span><span class="n">github</span><span class="o">.</span><span class="n">com</span><span class="o">/</span><span class="n">raysan5</span><span class="o">/</span><span class="n">raylib</span><span class="o">.</span><span class="n">git</span> <span class="o">--</span><span class="n">branch</span> <span class="mf">5.0</span> <span class="o">--</span><span class="n">single</span><span class="o">-</span><span class="n">branch</span>
|
||||
<span class="n">cd</span> <span class="n">raylib</span>
|
||||
<span class="n">mkdir</span> <span class="n">build</span>
|
||||
<span class="n">rm</span> <span class="n">rf</span> <span class="n">build</span><span class="o">/*</span>
|
||||
<span class="n">cd</span> <span class="n">build</span>
|
||||
<span class="n">cmake</span> <span class="o">-</span><span class="n">DPLATFORM</span><span class="o">=</span><span class="s2">"DRM"</span> <span class="o">-</span><span class="n">DINCLUDE_EVERYTHING</span><span class="o">=</span><span class="n">on</span> <span class="o">-</span><span class="n">DSUPPORT_FILEFORMAT_JPG</span><span class="o">=</span><span class="n">on</span> <span class="o">-</span><span class="n">DWITH_PIC</span><span class="o">=</span><span class="n">on</span> <span class="o">-</span><span class="n">DCMAKE_BUILD_TYPE</span><span class="o">=</span><span class="n">Release</span> <span class="o">..</span>
|
||||
<span class="n">cmake</span> <span class="o">-</span><span class="n">DPLATFORM</span><span class="o">=</span><span class="s2">"DRM"</span> <span class="o">-</span><span class="n">DBUILD_EXAMPLES</span><span class="o">=</span><span class="n">OFF</span> <span class="o">-</span><span class="n">DCUSTOMIZE_BUILD</span><span class="o">=</span><span class="n">ON</span> <span class="o">-</span><span class="n">DSUPPORT_FILEFORMAT_JPG</span><span class="o">=</span><span class="n">ON</span> <span class="o">-</span><span class="n">DSUPPORT_FILEFORMAT_FLAC</span><span class="o">=</span><span class="n">ON</span> <span class="o">-</span><span class="n">DWITH_PIC</span><span class="o">=</span><span class="n">ON</span> <span class="o">-</span><span class="n">DCMAKE_BUILD_TYPE</span><span class="o">=</span><span class="n">Release</span> <span class="o">..</span>
|
||||
<span class="n">make</span>
|
||||
<span class="n">sudo</span> <span class="n">make</span> <span class="n">install</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<p>Then have pip compile the wheel:</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">pip3</span> <span class="n">install</span> <span class="n">setuptools</span>
|
||||
<span class="n">pip3</span> <span class="n">install</span> <span class="o">--</span><span class="n">no</span><span class="o">-</span><span class="n">cache</span><span class="o">-</span><span class="nb">dir</span> <span class="o">--</span><span class="n">no</span><span class="o">-</span><span class="n">binary</span> <span class="n">raylib</span> <span class="o">--</span><span class="n">upgrade</span> <span class="o">--</span><span class="n">force</span><span class="o">-</span><span class="n">reinstall</span> <span class="n">raylib</span><span class="o">==</span><span class="mf">4.2.1.2</span>
|
||||
<p>Then have pip compile and install the wheel with some extra linker flags:</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">sudo</span> <span class="n">apt</span> <span class="n">update</span>
|
||||
<span class="n">sudo</span> <span class="n">apt</span> <span class="n">install</span> <span class="n">python3</span><span class="o">-</span><span class="n">pip</span>
|
||||
<span class="n">pip3</span> <span class="n">install</span> <span class="n">setuptools</span>
|
||||
<span class="n">LDFLAGS</span><span class="o">=</span><span class="s2">"-lgbm -ldrm -lEGL"</span> <span class="n">pip3</span> <span class="n">install</span> <span class="o">--</span><span class="n">no</span><span class="o">-</span><span class="n">cache</span><span class="o">-</span><span class="nb">dir</span> <span class="o">--</span><span class="n">no</span><span class="o">-</span><span class="n">binary</span> <span class="n">raylib</span> <span class="o">--</span><span class="n">upgrade</span> <span class="o">--</span><span class="n">force</span><span class="o">-</span><span class="n">reinstall</span> <span class="n">raylib</span><span class="o">==</span><span class="mf">5.0.0.0</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
</section>
|
||||
<section id="compile-raylib-from-source-x11-mode">
|
||||
<h2>Compile Raylib from source X11 mode<a class="headerlink" href="#compile-raylib-from-source-x11-mode" title="Link to this heading"></a></h2>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">git</span> <span class="n">clone</span> <span class="n">https</span><span class="p">:</span><span class="o">//</span><span class="n">github</span><span class="o">.</span><span class="n">com</span><span class="o">/</span><span class="n">raysan5</span><span class="o">/</span><span class="n">raylib</span><span class="o">.</span><span class="n">git</span> <span class="o">--</span><span class="n">branch</span> <span class="mf">5.0</span> <span class="o">--</span><span class="n">single</span><span class="o">-</span><span class="n">branch</span>
|
||||
<span class="n">cd</span> <span class="n">raylib</span>
|
||||
<span class="n">mkdir</span> <span class="n">build</span>
|
||||
<span class="n">rm</span> <span class="o">-</span><span class="n">rf</span> <span class="n">build</span><span class="o">/*</span>
|
||||
<span class="n">cd</span> <span class="n">build</span>
|
||||
<span class="n">cmake</span> <span class="o">-</span><span class="n">DPLATFORM</span><span class="o">=</span><span class="s2">"Desktop"</span> <span class="o">-</span><span class="n">DOPENGL_VERSION</span><span class="o">=</span><span class="mf">2.1</span> <span class="o">-</span><span class="n">DBUILD_EXAMPLES</span><span class="o">=</span><span class="n">OFF</span> <span class="o">-</span><span class="n">DCUSTOMIZE_BUILD</span><span class="o">=</span><span class="n">ON</span> <span class="o">-</span><span class="n">DSUPPORT_FILEFORMAT_JPG</span><span class="o">=</span><span class="n">ON</span> <span class="o">-</span><span class="n">DSUPPORT_FILEFORMAT_FLAC</span><span class="o">=</span><span class="n">ON</span> <span class="o">-</span><span class="n">DWITH_PIC</span><span class="o">=</span><span class="n">ON</span> <span class="o">-</span><span class="n">DCMAKE_BUILD_TYPE</span><span class="o">=</span><span class="n">Release</span> <span class="o">..</span>
|
||||
<span class="n">make</span>
|
||||
<span class="n">sudo</span> <span class="n">make</span> <span class="n">install</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<p>Then have pip compile and install the wheel:</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">sudo</span> <span class="n">apt</span> <span class="n">update</span>
|
||||
<span class="n">sudo</span> <span class="n">apt</span> <span class="n">install</span> <span class="n">python3</span><span class="o">-</span><span class="n">pip</span>
|
||||
<span class="n">pip3</span> <span class="n">install</span> <span class="n">setuptools</span>
|
||||
<span class="n">pip3</span> <span class="n">install</span> <span class="o">--</span><span class="n">no</span><span class="o">-</span><span class="n">cache</span><span class="o">-</span><span class="nb">dir</span> <span class="o">--</span><span class="n">no</span><span class="o">-</span><span class="n">binary</span> <span class="n">raylib</span> <span class="o">--</span><span class="n">upgrade</span> <span class="o">--</span><span class="n">force</span><span class="o">-</span><span class="n">reinstall</span> <span class="n">raylib</span><span class="o">==</span><span class="mf">5.0.0.0</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<p>(or newer version)</p>
|
||||
<div class="admonition attention">
|
||||
<p class="admonition-title">Attention</p>
|
||||
<p>The Broadcom proprietary Open GL ES 2.0 drivers (installed by Raspbian into <code class="docutils literal notranslate"><span class="pre">/opt/vc</span></code> and compiled in Raylib
|
||||
with <code class="docutils literal notranslate"><span class="pre">PLATFORM_RPI</span></code>) do not work with Bullseye and have not been tested with the bindings. They will probably
|
||||
require additional linker arguments to be added to <code class="docutils literal notranslate"><span class="pre">build.py</span></code>. Suggest you use <code class="docutils literal notranslate"><span class="pre">PLATFORM_DRM</span></code> instead.</p>
|
||||
</div>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
|
||||
|
|
|
@ -3,6 +3,9 @@ Raspberry Pi
|
|||
|
||||
Please use Raspberry Pi OS Bullseye. Older OSes are not tested.
|
||||
|
||||
Binary wheel
|
||||
------------
|
||||
|
||||
We have published a binary wheel using Raylib in X11 mode. This *should* install and work on Bullseye
|
||||
with
|
||||
|
||||
|
@ -10,30 +13,59 @@ with
|
|||
|
||||
python3.9 -m pip install raylib==4.2.1.2
|
||||
|
||||
If it doesn't work, or we haven't published a binary wheel for the latest version,
|
||||
If it doesn't work, or you're not on Bullseye, or you want a newer version,
|
||||
or if you want to use Raylib in ``PLATFORM_DRM`` mode, you will need to compile your own raylib.
|
||||
For full instructins on this, see https://github.com/raysan5/raylib/wiki/Working-on-Raspberry-Pi . If you need help with this ask Raylib.
|
||||
For full instructions on this, see https://github.com/raysan5/raylib/wiki/Working-on-Raspberry-Pi . If you need help with this ask Raylib.
|
||||
|
||||
This 'worked for me':
|
||||
Compile Raylib from source DRM mode
|
||||
-----------------------------------
|
||||
|
||||
As far as I can tell, Raylib DRM is broken. It doesn't work on my Pi. However, if you want to compile it and
|
||||
give it a go, these are the commands:
|
||||
|
||||
::
|
||||
|
||||
git clone https://github.com/raysan5/raylib.git --branch 4.2.0 --single-branch
|
||||
git clone https://github.com/raysan5/raylib.git --branch 5.0 --single-branch
|
||||
cd raylib
|
||||
mkdir build
|
||||
rm rf build/*
|
||||
cd build
|
||||
cmake -DPLATFORM="DRM" -DINCLUDE_EVERYTHING=on -DSUPPORT_FILEFORMAT_JPG=on -DWITH_PIC=on -DCMAKE_BUILD_TYPE=Release ..
|
||||
cmake -DPLATFORM="DRM" -DBUILD_EXAMPLES=OFF -DCUSTOMIZE_BUILD=ON -DSUPPORT_FILEFORMAT_JPG=ON -DSUPPORT_FILEFORMAT_FLAC=ON -DWITH_PIC=ON -DCMAKE_BUILD_TYPE=Release ..
|
||||
make
|
||||
sudo make install
|
||||
|
||||
Then have pip compile the wheel:
|
||||
Then have pip compile and install the wheel with some extra linker flags:
|
||||
|
||||
::
|
||||
|
||||
sudo apt update
|
||||
sudo apt install python3-pip
|
||||
pip3 install setuptools
|
||||
pip3 install --no-cache-dir --no-binary raylib --upgrade --force-reinstall raylib==4.2.1.2
|
||||
LDFLAGS="-lgbm -ldrm -lEGL" pip3 install --no-cache-dir --no-binary raylib --upgrade --force-reinstall raylib==5.0.0.0
|
||||
|
||||
Compile Raylib from source X11 mode
|
||||
-----------------------------------
|
||||
|
||||
::
|
||||
|
||||
git clone https://github.com/raysan5/raylib.git --branch 5.0 --single-branch
|
||||
cd raylib
|
||||
mkdir build
|
||||
rm -rf build/*
|
||||
cd build
|
||||
cmake -DPLATFORM="Desktop" -DOPENGL_VERSION=2.1 -DBUILD_EXAMPLES=OFF -DCUSTOMIZE_BUILD=ON -DSUPPORT_FILEFORMAT_JPG=ON -DSUPPORT_FILEFORMAT_FLAC=ON -DWITH_PIC=ON -DCMAKE_BUILD_TYPE=Release ..
|
||||
make
|
||||
sudo make install
|
||||
|
||||
Then have pip compile and install the wheel:
|
||||
|
||||
::
|
||||
|
||||
sudo apt update
|
||||
sudo apt install python3-pip
|
||||
pip3 install setuptools
|
||||
pip3 install --no-cache-dir --no-binary raylib --upgrade --force-reinstall raylib==5.0.0.0
|
||||
|
||||
(or newer version)
|
||||
|
||||
.. attention::
|
||||
|
||||
|
|
File diff suppressed because one or more lines are too long
27
make_docs.sh
27
make_docs.sh
|
@ -1,6 +1,29 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
|
||||
echo "building and installing raylib"
|
||||
cd raylib-c
|
||||
mkdir build
|
||||
cd build
|
||||
cmake -DBUILD_EXAMPLES=OFF -DCUSTOMIZE_BUILD=ON -DSUPPORT_FILEFORMAT_JPG=ON -DSUPPORT_FILEFORMAT_FLAC=ON -DWITH_PIC=ON -DCMAKE_BUILD_TYPE=Release ..
|
||||
make -j2
|
||||
sudo make install
|
||||
cd ../..
|
||||
|
||||
echo "installing raylib headers to /usr/local/include"
|
||||
|
||||
sudo cp ./raylib-c/src/raylib.h /usr/local/include/
|
||||
sudo cp ./raylib-c/src/rlgl.h /usr/local/include/
|
||||
sudo cp ./raylib-c/src/raymath.h /usr/local/include/
|
||||
sudo cp ./raygui/src/raygui.h /usr/local/include/
|
||||
sudo cp ./physac/src/physac.h /usr/local/include/
|
||||
|
||||
echo "building raylib_parser"
|
||||
|
||||
gcc raylib-c/parser/raylib_parser.c
|
||||
|
||||
echo "running parser"
|
||||
|
||||
./a.out -i raygui/src/raygui.h -d RAYGUIAPI -o raygui.json -f JSON
|
||||
./a.out -i physac/src/physac.h -d PHYSACDEF -o physac.json -f JSON
|
||||
./a.out -i raylib-c/src/raylib.h -o raylib.json -f JSON
|
||||
|
@ -9,6 +32,9 @@ gcc raylib-c/parser/raylib_parser.c
|
|||
./a.out -i raylib-c/src/external/glfw/include/GLFW/glfw3.h -d GLFWAPI -o glfw3.json -f JSON
|
||||
sed -i "s|\/\*.*,$|,|g" glfw3.json
|
||||
|
||||
|
||||
echo "building raylib_python_cffi"
|
||||
|
||||
python3 raylib/build.py
|
||||
|
||||
python3 create_enums.py > raylib/enums.py
|
||||
|
@ -20,6 +46,7 @@ pip3 install sphinx-autoapi myst_parser sphinx_rtd_theme
|
|||
python3 create_stub_pyray.py > pyray/__init__.pyi
|
||||
python3 create_enums.py >> pyray/__init__.pyi
|
||||
cat raylib/colors.py >> pyray/__init__.pyi
|
||||
|
||||
python3 create_stub_static.py >raylib/__init__.pyi
|
||||
cat raylib/colors.py >> raylib/__init__.pyi
|
||||
rm -r docs
|
||||
|
|
Reference in a new issue