Building OBS-Studio in Ubuntu 22.04 and getting libMBEDTLS -fPIC error.

ny2292000

New Member
Certainly! Here's a concise summary of what you've done so far for posting on the forum:

---

### Steps to Reproduce the Issue:

1. Cloned the OBS Studio repository recursively:
```bash
git clone --recursive https://github.com/obsproject/obs-studio.git
```

2. Checked out to an older release version (29.0):
```bash
cd ./obs-studio
git checkout origin/release/29.0
```

3. Created a build directory and configured the build with CMake:
```bash
mkdir build
cmake -S . -B build -G Ninja -DCEF_ROOT_DIR="../obs-build-dependencies/cef_binary_5060_linux64" -DENABLE_PIPEWIRE=OFF -DENABLE_AJA=0 -DENABLE_WEBRTC=0 -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DQT_VERSION=6
```

4. Attempted to build the project:
```bash
cmake --build build
```

### Error Encountered:

During the build process, I encountered a linker error related to `mbedtls`. The error suggests that it's trying to link a static version of `libmbedcrypto.a` which was not compiled with `-fPIC`, causing issues with creating a shared object.

### Installed libmbedtls Packages:

- libmbedtls-dev/jammy, version 2.28.0-1build1 (amd64) [installed]
- libmbedtls14/jammy, version 2.28.0-1build1 (amd64) [installed]

---
 

AaronD

Active Member
Was this supposed to be in response to a different thread? It reads that way, but you only have 1 post, and this is it.
 

Markosjal

Member
The ubuntu ppa works beautifully. I had issues with the flatpak not supporting alsa

sudo add-apt-repository ppa:obsproject/obs-studio
sudo apt update
sudo apt install ffmpeg obs-studio
 

Aaron Charles

New Member
ace@ace-networks:~$ git clone --recursive https://github.com/obsproject/obs-studio.git
Cloning into 'obs-studio'...
remote: Enumerating objects: 107099, done.
remote: Counting objects: 100% (36674/36674), done.
remote: Compressing objects: 100% (1846/1846), done.
error: RPC failed; curl 92 HTTP/2 stream 0 was not closed cleanly: CANCEL (err 8)
error: 2316 bytes of body are still expected
fetch-pack: unexpected disconnect while reading sideband packet
fatal: early EOF
fatal: fetch-pack: invalid index-pack output
 
Top