<h3 dir="auto">Describe your issue.</h3>
<p dir="auto"><strong>Version used</strong> : <code class="notranslate">Using cached scipy-1.6.1.tar.gz (27.3 MB)</code></p>
<p dir="auto">I've attached the log file and the suspected issue - <a href="https://github.com/scipy/scipy/files/8765273/scipy-compile.log">scipy-compile.log</a></p>
<h3 dir="auto">Reproducing Code Example</h3>
<div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="pip install scipy
Pip version - pip 22.1.1 from /home/rishacha/.local/lib/python3.11/site-packages/pip (python 3.11)
Python version - Python 3.11.0b1
OS - elementaryOS

&gt;&gt;&gt; import sys, numpy; print(&quot;Numpy version: &quot;, numpy.__version__,&quot;\nSys version: &quot;, sys.version_info)
Numpy version:  1.22.3 "><pre class="notranslate"><span class="pl-s1">pip</span> <span class="pl-s1">install</span> <span class="pl-s1">scipy</span>
<span class="pl-v">Pip</span> <span class="pl-s1">version</span> <span class="pl-c1">-</span> <span class="pl-s1">pip</span> <span class="pl-c1">22.1</span><span class="pl-c1">.1</span> <span class="pl-k">from</span> <span class="pl-c1">/</span><span class="pl-s1">home</span><span class="pl-c1">/</span><span class="pl-s1">rishacha</span><span class="pl-c1">/</span>.<span class="pl-s1">local</span><span class="pl-c1">/</span><span class="pl-s1">lib</span><span class="pl-c1">/</span><span class="pl-s1">python3</span>.<span class="pl-c1">11</span><span class="pl-c1">/</span><span class="pl-s1">site</span><span class="pl-c1">-</span><span class="pl-s1">packages</span><span class="pl-c1">/</span><span class="pl-en">pip</span> (<span class="pl-s1">python</span> <span class="pl-c1">3.11</span>)
<span class="pl-v">Python</span> <span class="pl-s1">version</span> <span class="pl-c1">-</span> <span class="pl-v">Python</span> <span class="pl-c1">3.11</span><span class="pl-c1">.0</span><span class="pl-s1">b1</span>
<span class="pl-v">OS</span> <span class="pl-c1">-</span> <span class="pl-s1">elementaryOS</span>

<span class="pl-c1">&gt;&gt;</span><span class="pl-c1">&gt;</span> <span class="pl-k">import</span> <span class="pl-s1">sys</span>, <span class="pl-s1">numpy</span>; <span class="pl-en">print</span>(<span class="pl-s">"Numpy version: "</span>, <span class="pl-s1">numpy</span>.<span class="pl-s1">__version__</span>,<span class="pl-s">"<span class="pl-cce">\n</span>Sys version: "</span>, <span class="pl-s1">sys</span>.<span class="pl-s1">version_info</span>)
<span class="pl-v">Numpy</span> <span class="pl-s1">version</span>:  <span class="pl-c1">1.22</span>.<span class="pl-c1">3</span> </pre></div>
<p dir="auto">Sys version:  sys.version_info(major=3, minor=11, micro=0, releaselevel='beta', serial=1)</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="

### Error message

```shell
2022-05-24T23:43:03,313   scipy/cluster/_vq.c:196:12: fatal error: longintrepr.h: No such file or directory
2022-05-24T23:43:03,313     196 |   #include &quot;longintrepr.h&quot;
2022-05-24T23:43:03,313         |            ^~~~~~~~~~~~~~~
2022-05-24T23:43:03,313   compilation terminated."><pre class="notranslate"><code class="notranslate">

### Error message

```shell
2022-05-24T23:43:03,313   scipy/cluster/_vq.c:196:12: fatal error: longintrepr.h: No such file or directory
2022-05-24T23:43:03,313     196 |   #include "longintrepr.h"
2022-05-24T23:43:03,313         |            ^~~~~~~~~~~~~~~
2022-05-24T23:43:03,313   compilation terminated.
</code></pre></div>
<h3 dir="auto">SciPy/NumPy/Python version information</h3>
<blockquote>
<blockquote>
<blockquote>
<p dir="auto">import sys, numpy; print("Numpy version: ", numpy.<strong>version</strong>,"\nSys version: ", sys.version_info) Numpy version:  1.22.3  Sys version:  sys.version_info(major=3, minor=11, micro=0, releaselevel='beta', serial=1)</p>
</blockquote>
</blockquote>
</blockquote>
<p dir="auto">My issue is about ...</p>
<h4 dir="auto">Reproducing code example:</h4>

<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Sample code to reproduce the problem"><pre class="notranslate"><code class="notranslate">Sample code to reproduce the problem
</code></pre></div>
<h4 dir="auto">Error message:</h4>

<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Traceback (most recent call last):
  File &quot;&lt;stdin&gt;&quot;, line 1, in &lt;module&gt;
  ..."><pre class="notranslate"><code class="notranslate">Traceback (most recent call last):
  File "&lt;stdin&gt;", line 1, in &lt;module&gt;
  ...
</code></pre></div>
<h4 dir="auto">Scipy/Numpy/Python version information:</h4>