Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Linux Compiling #49

Draft
wants to merge 9 commits into
base: master
Choose a base branch
from
Draft

Linux Compiling #49

wants to merge 9 commits into from

Conversation

DotWith
Copy link
Contributor

@DotWith DotWith commented Aug 21, 2023

Allows for compiling without steam-runtime. Tested on Arch Linux.

Fixes #38

Task List

  • Add MP Support
  • Add SP Support
  • Add Linux workflows
  • Improve compiling documentation
  • Fix MP TOGL
  • Fix SP TOGL
  • Fix warnings

Code stolen from Momentum Mod and ilocalize

@Nbc66
Copy link
Owner

Nbc66 commented Aug 22, 2023

Fun fact we also fully support vs2022 so if you want you can add vs2019/2022 into the readme file

@DotWith
Copy link
Contributor Author

DotWith commented Aug 28, 2023

Linux on SP branch crashes after intro. As well I can't view asserts cause the steam-runtime is needed when running the game launcher (hl2_linux).

@Nbc66
Copy link
Owner

Nbc66 commented Sep 4, 2023

Did you switch sp to upcoming?

@Nbc66
Copy link
Owner

Nbc66 commented Sep 4, 2023

Also would be good if just port sp stuff to mp anyways since its more up to date

@DotWith
Copy link
Contributor Author

DotWith commented Sep 4, 2023

Yes, I'm on upcoming. Should I keep this in draft until that port is done?

@Nbc66
Copy link
Owner

Nbc66 commented Sep 5, 2023 via email

@DotWith
Copy link
Contributor Author

DotWith commented Sep 5, 2023

Alright

@Alienmario
Copy link

Alienmario commented Oct 29, 2023

I've finally gotten to test out a linux server on Ubuntu 22.04 using Base 2013 Dedicated Server. Compiling was fine (thanks to WSL), if you ignore the warnings. Besides installing the usual dependencies, I've ran into some minor setbacks, resolved below. I ran a cherrypicked version of this repo, so could very well be my fault.
Thank you!

failed to dlopen /mnt/volume-fsn1-1/pufferpanel/servers/fe4e423d/hl2mp/bin/server_srv.so error=bin/libstdc++.so.6: version `GLIBCXX_3.4.21' not found (required by /mnt/volume-fsn1-1/pufferpanel/servers/fe4e423d/hl2mp/bin/server_srv.so)
  
 > strings /mnt/volume-fsn1-1/pufferpanel/servers/fe4e423d/bin/libstdc++.so.6 | grep GLIBCX
GLIBCXX_3.4
GLIBCXX_3.4.1
GLIBCXX_3.4.2
GLIBCXX_3.4.3
GLIBCXX_3.4.4
GLIBCXX_3.4.5
GLIBCXX_3.4.6
GLIBCXX_3.4.7
GLIBCXX_3.4.8
GLIBCXX_3.4.9
GLIBCXX_3.4.10
GLIBCXX_3.4.11
GLIBCXX_3.4.12
GLIBCXX_3.4.13
GLIBCXX_3.4.14
GLIBCXX_3.4.15
GLIBCXX_3.4.16
GLIBCXX_3.4.17
GLIBCXX_3.4.18
GLIBCXX_3.4.19
GLIBCXX_DEBUG_MESSAGE_LENGTH

 > strings /usr/lib/x86_64-linux-gnu/libstdc++.so.6 | grep GLIBCXX
GLIBCXX_3.4
GLIBCXX_3.4.1
GLIBCXX_3.4.2
GLIBCXX_3.4.3
GLIBCXX_3.4.4
GLIBCXX_3.4.5
GLIBCXX_3.4.6
GLIBCXX_3.4.7
GLIBCXX_3.4.8
GLIBCXX_3.4.9
GLIBCXX_3.4.10
GLIBCXX_3.4.11
GLIBCXX_3.4.12
GLIBCXX_3.4.13
GLIBCXX_3.4.14
GLIBCXX_3.4.15
GLIBCXX_3.4.16
GLIBCXX_3.4.17
GLIBCXX_3.4.18
GLIBCXX_3.4.19
GLIBCXX_3.4.20
GLIBCXX_3.4.21
GLIBCXX_3.4.22
GLIBCXX_3.4.23
GLIBCXX_3.4.24
GLIBCXX_3.4.25
GLIBCXX_3.4.26
GLIBCXX_3.4.27
GLIBCXX_3.4.28
GLIBCXX_3.4.29
GLIBCXX_3.4.30
GLIBCXX_DEBUG_MESSAGE_LENGTH

 > cp /usr/lib/x86_64-linux-gnu/libstdc++.so.6 /mnt/volume-fsn1-1/pufferpanel/servers/fe4e423d/bin/libstdc++.so.6

Unable to load interface VSoundEmitter002 from soundemittersystem.so
 
 > cp soundemittersystem_srv.so soundemittersystem.so

AppFramework : Unable to load module scenefilecache.so!
 
 > cp scenefilecache_srv.so scenefilecache.so

Additional thoughts:

  • Both server_srv.so and server.so appear in the bin directory with equal filesize, is this normal?
  • I'm only able to maintain full compat with sourcemod by going from -O2 to -O1 (It would otherwise crash when output hooks are used and CBaseEntityOutput::FireOutput is called)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] Linux compiling with steam-runtime
3 participants