336 Commits
Author SHA1 Message Date
ahkok 6137c52bab Update README.md 2019-06-10 13:55:47 -07:00
ahkok 524810bbd2 Merge pull request #1 from sunnyflunk/beta
Allow steam to load private libpangocairo
2019-06-10 13:18:21 -07:00
Peter O'Connor d7006fdb74 Allow steam to load private libpangocairo
The latest steam beta now includes `libpangocairo-1.0.so.0` as a private
library. Currently an issue arises where it loads this file from the
distribution, but is incompatible with the privately loaded libpango due to
the lack of `pango_renderer_get_alpha` symbol.
2019-05-16 15:46:29 +10:00
Ikey Doherty 211ac7613c Any day now ...
Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-03-20 17:54:38 +00:00
Ikey Doherty 5352b5deab Update README.md as I was off sick
Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-02-06 10:41:26 +00:00
Ikey Doherty 54bd49281c Bump version to 0.7.3
Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-15 12:00:18 +00:00
Ikey Doherty 8b09218039 Update README.md for the curious on reddit
Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-15 11:58:33 +00:00
Ikey Doherty 89e7b7cfbb redirect: Avoid use of uninitialised LsiRedirectOperation
While admittedly there is no case of us using any invalid LsiRedirectOperation,
there exists the future possibility for invalid inserts into the op table
when we encounter an unhandled op type.

Knock it on the head and bail early, as appropriate.

Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-08 10:53:02 +00:00
Ikey Doherty ffe7825f62 Properly set preload libs in conf
Weird janky escaping is left-over from our time as an
autotools project and should've been fixed long ago as
it was obvious the compiler warnings were legit.

Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-08 10:49:55 +00:00
Ikey Doherty 0f24683688 meson: Start a cleanup of the build files
Additionally, add an output report to show at build time what we're
configured to do, ala autotools.

Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-08 10:28:44 +00:00
Ikey Doherty abcb5feeaf TEST_LIST: Add Oxygen Not Included as working perfectly
Hey, it came in a bundle deal with Don't Starve.

Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-07 12:21:06 +00:00
Ikey Doherty 6963c34892 intercept: Cleanup now new clang-format is less of a PITA
Old clang-format 3.8 broke the styling when using ifdefs, let's get
it fixed up now.

Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-07 11:50:46 +00:00
Ikey Doherty 8d9aac19f6 TEST_LIST: Document fact that Don't Starve works now
Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-07 11:39:19 +00:00
Ikey Doherty c4ded16115 intercept: Only blacklist SDL overrides on 64-bit native
Instead of the potential ugly route of whitelisting (which still might be
needed in future) we'll allow the SDL2 core library to be overriden only
on 32-bit builds of Steam games.

This has the interesting side-effect of enabling Don't Starve to work
correctly, as it ships a custom patched (incompatible ABI) version of
SDL2 to change the mouse event handling.

If it turns out random 32-bit games break by using their own old and
unmodified builds of SDL2, we'll implement whitelisting. For now, this
change should suffice.

Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-07 11:07:15 +00:00
Ikey Doherty 6bc12dde6e Update TEST_LIST for Don't Starve weirdness
Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-06 13:05:20 +00:00
Ikey Doherty 8968b69788 TEST_LIST: Document weirdness with Don't Starve's SDL library
Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-04 20:50:31 +00:00
Ikey Doherty 6a5fff703c TEST_LIST: Don't Starve requires curl-gnutls, working on it atm.
Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-04 12:10:29 +00:00
Ikey Doherty 11e9ff2137 Add a couple of games to the test list
Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-02 14:41:53 +00:00
Ikey Doherty 05343c140f Add an initial testing list to help with next releases
Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-02 14:35:10 +00:00
Ikey Doherty c03d5cdff8 mkgobuildy: Clean up and reorganise
Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-02 13:41:27 +00:00
Ikey Doherty 4c68fcc7d7 Update copyright ranges to be correct
Previous copyright assignment was to myself but the range doesn't account
for the project WIPs and lifetime, so retroactively fit them to the right
year range (project duration). Now set ongoing copyright for future and
current changes.

Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-01 14:28:43 +00:00
Ikey Doherty 09c84f0866 libnica: Sync with upstream master
Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-01 14:22:18 +00:00
Ikey Doherty fc9ae2e9c2 shim: Use setarch instead of relying on linux32 link
On some distributions, `linux32` command is not readily available in the
default install. However, `setarch` is commonly available as part of the
`util-linux` packaging, so let's invoke `setarch` directly now without
relying on links.

Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-01 14:16:51 +00:00
Ikey Doherty 9624bde1b9 mkgobuildy: Gracefully handle missing linux32 availability
Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2019-01-01 14:04:34 +00:00
Ikey Doherty a951a49910 frontend: Apply update-format.sh
Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2018-12-21 14:22:48 +00:00
Ikey Doherty fc88ee1496 Improve formatting in README
Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2018-12-21 13:53:56 +00:00
Ikey Doherty ae48c61932 Update README.md for this fork
Signed-off-by: Ikey Doherty <ikey.doherty@intel.com>
2018-12-20 17:08:23 +00:00
Ikey Doherty fb56eca35d Merge pull request #66 from davidpocina/startup-wm-class
Add StartupWMClass to lsi-steam.desktop
2018-05-20 16:38:25 +01:00
David Pocina 1c3a39ebfa Add StartupWMClass to lsi-steam.desktop 2018-05-20 16:13:52 +01:00
Ikey Doherty 62cf7443ac intercept: Support new sonames in Feral's Tomb Raider port
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2018-04-20 08:47:14 +01:00
Ikey Doherty 46c423d065 shim: Remove legacy (non GLVND) path support for snapd runtime
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2018-01-29 18:28:07 +00:00
Ikey Doherty c34938a43a Fix incorrect snap name (fixes issue #50)
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2018-01-04 21:06:30 +00:00
Ikey Doherty 62bd3dffb7 redirect: We might return NULL here.
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-24 18:33:22 +00:00
Ikey Doherty 5c809fdc07 redirect: Add new override on getpwuid
This is required for some Aspyr ports which will form their own fixed
paths to directories based on getpwuid() as opposed to using the environment
`HOME` variable.

With this we force the home directory to be consistent under snapd and
alleviate any issues with denials based on home directory lookups.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-24 18:29:17 +00:00
Ikey Doherty e7eae9d577 shim: When in snapd mode, chdir to SNAP_USER_COMMON
This will alleviate some weird apparmor confinement denials when trying
to access the wrong directory.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-24 18:10:35 +00:00
Ikey Doherty a1c2235120 Add new snapd pulseaudio script workaround
This is as yet untested, but the basic idea is that when games call out
to `system("pulseaudio --check > /dev/null 2>&1")` we'll put our script
in their way and unconditionally return 0. This is for games using libfmod,
which will die when trying to execute pulseaudio right now.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-24 15:12:43 +00:00
Ikey Doherty 5b59075ec0 Revert "intercept: Allow disabling (build-time) the udev redirection"
This reverts commit c640f2f215.

Turns out this is due to a very weird situation where Arch has their
libudev.so.0 as an incompatible API which all current games expect to
be of libudev.so.1 ABI, and isn't something LSI should be fixing, the
distro should.
2017-12-23 21:30:54 +00:00
Ikey Doherty c640f2f215 intercept: Allow disabling (build-time) the udev redirection
Arch Linux uses a funky udev shim package which is incompatible with
our udev workaround, so allow them to disable it and use their shim
instead (as some packages are apparently **built** against the shim.)

For all other distros which are binary-built in ABI lockstep with udev
proper, keep it enabled.

This fixes #46.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-23 19:52:37 +00:00
Ikey Doherty b80f79c8d0 Resync po
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-20 16:32:17 +00:00
Ikey Doherty 851f354f9f Promote v0.7.2
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-19 15:36:35 +00:00
Ikey Doherty 10d3be6a38 redirect: Split all Unity code out to fix linking problems
This should fix our linking issues that appeared once we opted to include
the `fcntl.h` header, which adds `#define`s for the exact symbols that
we are trying to override.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-19 15:35:48 +00:00
Ikey Doherty c8a45b7303 Promote 0.7.1
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-19 14:22:20 +00:00
Ikey Doherty 1b932e94fa redirect: Demote debug to info
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-19 14:21:59 +00:00
Ikey Doherty 003c462a77 Bump version to 0.7
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-19 13:55:26 +00:00
Ikey Doherty 7880b98f87 Remove old test.sh - not needed
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-19 13:54:04 +00:00
Ikey Doherty a91a00f1f5 Sync po
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-19 13:53:32 +00:00
Ikey Doherty 5998318a20 po: Sync po for unity string
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-19 12:48:32 +00:00
Ikey Doherty 1a725088af po: Sync translations
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-19 12:47:35 +00:00
Ikey Doherty f185b54c4d Add new LSI Settings screenshot
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-19 12:47:20 +00:00
Ikey Doherty 368e6ca7c7 Document the new sexies
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-19 12:45:14 +00:00
Ikey Doherty f12643039a common: Return realpath'd config dir where possible
This ensures we only use a sane realpath and collapse the slashes where
we can to allow trivial string matching.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-19 12:23:20 +00:00
Ikey Doherty 7cfdd41c7c redirect: Reduce error to info
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-18 18:55:16 +00:00
Ikey Doherty 889a4a7b7b Allow disabling Unity hack by the lsi-settings UI
By default we will keep this enabled now.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-18 18:54:46 +00:00
Ikey Doherty 4f810bfe97 redirect: Add workaround for the Unity Black Screen Of Nope
If we detect access to a unity3D configuration file, we'll enter the
unity3d workaround mode. Through this mode we'll abstract the real
"prefs" file away into `/dev/shm` so that Unity games do not directly
access that file again.

If no original prefs file exists, we'll write a new prefs file with the
absolute minimum requirement, i.e. disabling of fullscreen mode by default.
If one DOES exist, we'll copy all of the prefs file **except** for the
fullscreen option, and again, disabling it.

Upon library exit, again, we'll duplicate the unity config to the real
target file from the shm file, with the rewritten fullscreen option.

The net effect is that we create a circle of consumption that forcibly
disables unity games of a particular age (using `prefs` file) to not
start in fullscreen mode, which almost always means one of two things:

 - Missing UI text elements
 - Unity3D clamps resolution to 0x0

Many ports aren't going to see updates to their Unity build for a long time,
or indeed, ever. Instead we work around this in LSI and sit in between the
game and the configuration file.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-18 18:26:09 +00:00
Ikey Doherty 97e5813e4c intercept: Allow html5app_steam to load widevine
This should permit the encrypted playback to work correctly once more.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-12-15 18:35:52 +00:00
Ikey Doherty 0faa29aecd intercept: Handle /steamapps paths for #41
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-24 17:47:55 +00:00
Ikey Doherty 383b6492b5 shim: Fix vdpau for potential issues with not breaking the path
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-24 06:06:21 +00:00
Ikey Doherty f8b583bc0b intercept: Handle override of libudev.so.0 -> libudev.so.1
This should help with issue #38 but will need validation.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-15 14:34:37 +00:00
Ikey Doherty 9975bd5780 data: Don't set $SNAP, let lsi-exec work that stuff out
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-15 00:27:06 +00:00
Ikey Doherty 00ee48ee22 data: If we're using snap mode, configure frontend to use lsi-exec
This will ensure that the settings UI will always work, which will
somewhat perversely use lsi-exec through the config that it sets to
launch itself to set the config of lsi-exec..

This will allow us to actually expose lsi-settings as a usable thing
within the snap, where it is currently omitted. If we're not using snapd
mode, we'll just keep the file how it used to look.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-15 00:15:05 +00:00
Ikey Doherty 16a0750ed2 Revert "data: If we're using snap mode, configure frontend to use lsi-exec"
This reverts commit 657a911004.
2017-11-14 23:55:02 +00:00
Ikey Doherty 947654d9d3 shim: Read config AFTER setting up the environment
Under snapd we forcibly change XDG_CONFIG_HOME away from the "norm", and
read before the variable is set. Thus, the config written by lsi-settings
is correct, but under snapd the wrong file would be read all the time.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-14 23:16:09 +00:00
Ikey Doherty c59949cf0e frontend: Fix copy/paste and actually update liblsi-intercept config
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-14 22:58:31 +00:00
Ikey Doherty 657a911004 data: If we're using snap mode, configure frontend to use lsi-exec
This will ensure that the settings UI will always work, which will
somewhat perversely use lsi-exec through the config that it sets to
launch itself to set the config of lsi-exec..

This will allow us to actually expose lsi-settings as a usable thing
within the snap, where it is currently omitted. If we're not using snapd
mode, we'll just keep the file how it used to look.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-14 22:44:55 +00:00
Ikey Doherty 1d339cab05 shim: Drop derpy errno based checks
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-14 22:23:33 +00:00
Ikey Doherty a518fc6720 shim: Use a less derpy error dialog.
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-14 22:09:50 +00:00
Ikey Doherty 03758879ab shim: Allow lsi-exec to use the system path (execvp) instead
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-14 22:07:10 +00:00
Ikey Doherty 7131fd9771 shim: Add a new lsi-exec binary
This binary will allow us to run any command using the full LSI environment
and fully set it up as we would for Steam, greatly simplifying the testing
of the snap (and even for non-steam games!)

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-14 22:03:44 +00:00
Ikey Doherty 5013e0d747 shim: Split majority of the code into shim.c
This helps separate the main launch entry from the bulk of the bootstrap
code, and will also allow us to build a new lsi-exec tool that will just
execute whatever you tell it to, with the full shim setup routine.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-14 21:53:18 +00:00
Ikey Doherty 05bd0e0dac common: Fix broken ikey mind - correctly build Steam path
Thanks to @TingPing for bailing me out of my own insanity.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-14 21:17:47 +00:00
Ikey Doherty aa1b7374db common: Respect XDG specification for directories
If `XDG_{DATA,CONFIG}_HOME` variables are set in the environment, use
those to ensure portability and integration with the platform. This ensures
we always use the right locations for accessing config files and the Steam
root.

This fixes #34.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-14 21:13:27 +00:00
Ikey Doherty 82130bfbe8 shim: Use SNAP_USER_COMMON for our home tree
LSI enables Steam, which will invariably have massive games on disk.
We do NOT want this large data being moved around between upgrades,
and need this data to be "sticky" and unversioned.

To alleviate le huge pains of upgrades, start using this directory before
we go into production. This will mean only one last switch of the games
tree.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-14 05:58:19 +00:00
Ikey Doherty d73b7e7381 shim: Support Ubuntu ICD files
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-14 04:43:53 +00:00
Ikey Doherty 9f57d0ebf0 intercept: Fix one of the Ubuntu crashes
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-14 03:58:41 +00:00
Ikey Doherty f8d12b9800 intercept: Fix compiler warnings
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-14 01:32:04 +00:00
Ikey Doherty b3a562f4f9 intercept: Remove old snapd paths
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-14 01:31:26 +00:00
Ikey Doherty 94e5d09eba intercept: When in Steam mode, try to find host libraries ourselves
This gives help when LD_LIBRARY_PATH is a bit busted, as the "normal"
operational mode gets more help than we currently give to games.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-14 01:30:37 +00:00
Ikey Doherty 04e32cd5c5 intercept: Attempt using existing code-paths for all snapd libgl work
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-14 00:24:16 +00:00
Ikey Doherty cd5a1e6f97 intercept: Clamp down that intercept properly
Again for #38

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-13 18:45:59 +00:00
Ikey Doherty 287781356c intercept: Help Fedora by redirecting bzip2 automatically
Fedora doesn't seem to have `libbbz2.so.1` so let's intercept requests for
this guy and send them to the proper `libbz2.so.1.0.6`.

This fixes #38.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-13 18:44:32 +00:00
Ikey Doherty 80603598af Only use the new "gl32" location from now on, drop old guy
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-13 03:46:24 +00:00
Ikey Doherty e81f379882 shim: Make the vdpau code handle biarch, multiarch, and host
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-13 03:03:56 +00:00
Ikey Doherty 8d7b56f68c shim: Get ready for the new Vulkan snapd changes
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-13 02:14:54 +00:00
Ikey Doherty 87fab0c747 shim: Prepare for gl32 snapd paths
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-13 01:35:46 +00:00
Ikey Doherty 208585eebc shim: Fix broken shim_export_ld_dir, export VDPAU_DRIVER_PATH
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-13 01:33:47 +00:00
Ikey Doherty 01237d30c6 shim: Take a far more robust approach to LD_LIBRARY_PATH
This ensures we correctly set up `LD_LIBRARY_PATH` with required extra
directories inside the snap environment - only if they actually exist.
This allows us to expand that search path to ensure that tls and vdpau
bits are available on multiarch systems, and things continue to tick
over as normal on biarch systems.

This is part of tackling issue #35.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-13 00:07:17 +00:00
Ikey Doherty 4b6ec38bbf intercept: Don't match non-cuda files
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-12 11:06:20 +00:00
Ikey Doherty 70fb1de048 Mark vulkan work done, add 2 more TODO items
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-11 23:31:11 +00:00
Ikey Doherty 393d335af4 shim: Add initial support for Vulkan under snapd
This will require modifications to snapd, but at the moment we'll attempt
to look for vulkan icd (`10*.json`) passed from the hostfs from their
proprietary NVIDIA driver within the GL shared directory.

If we find these files, we'll insert the `VK_ICD_FILENAMES` variable into
the environment, taking care to preserve the original glob order by doing
this part in reverse.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-11 22:26:52 +00:00
Ikey Doherty 02ccceae42 intercept: Fix swiftshader
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-11 05:39:04 +00:00
Ikey Doherty 2462f93f39 intercept: Never deal with /var/lib/snapd in DRI requests
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-11 05:05:13 +00:00
Ikey Doherty b34e3f928d shim: When Solus d-bus is used, silence endless D-BUS warnings.
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-11 04:37:09 +00:00
Ikey Doherty 9da279eeda intercept: Redirect all curl.so.3 to curl.so.4
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-11 00:19:32 +00:00
Ikey Doherty 8effde3adf Whoops.
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-10 23:27:06 +00:00
Ikey Doherty c7882a9ac7 shim: Ensure XDG_RUNTIME_DIR always exists
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-10 23:16:42 +00:00
Ikey Doherty 3e15d71936 shim: Make sure the user directories are set up under snapd
This fixes up the `XDG_*` variables and locations to be correct and
present when running under snapd.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-10 23:14:48 +00:00
Ikey Doherty 8d50a4f289 shim: Add some more bootstrap variables
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-10 23:07:39 +00:00
Ikey Doherty 589dda31a5 shim: Add new simplified variable management code
This will allow us to extend the number of bootstrap variables we need
to set up for snapd, and actually makes the existing code much simpler
to follow when dealing with existing environmental variables.

With this change we also introduce initial bootstrap for setting the PATH,
as it's incorrect on entering the snap.

This is part of the ongoing issue #30.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-10 23:00:17 +00:00
Ikey Doherty c2ba77b5ab Revert "intercept: Add initial test workaround for libpdf.so"
This reverts commit aa485def04.
We'll look elsewhere until this is solved..
2017-11-10 07:21:00 +00:00
Ikey Doherty aa485def04 intercept: Add initial test workaround for libpdf.so
We're seeing some games ship libpdf.so as a directory in their bin
directory with the real library in the lib directory, so this workaround
will hopefully alleviate the crash on start.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-10 07:11:08 +00:00
Ikey Doherty 6d2791b475 po: Sync lots of lovely translations :D
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-10 04:19:21 +00:00
Ikey Doherty 492d7d02f9 intercept: Add initial test fixes for open source drivers on snapd
This will forcibly perform redirects for "missing" DRI libraries to
help open source drivers actually work. This is as yet untested.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-10 03:46:56 +00:00
Ikey Doherty 8efc9a6b76 intercept: Use very explicit SDL blacklisting approach
This solves #31 by ensuring we only blacklist known library names that
we intend to override, and prevent ourselves from matching completely
moody names like "libSDL2_locale" by accident.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-10 02:23:00 +00:00
Ikey Doherty 00d0889280 TODO: Mark the snapd vars support as done
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-10 01:47:41 +00:00
Ikey Doherty 608907b6d0 shim: Fix uber-derp
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-10 01:33:31 +00:00
Ikey Doherty 68e3df8d1a shim: Ensure we fully set up the snapd environment
This saves us from having to rely on ugly shell scripts to bootstrap our
environment, as we're the primary entry point. We don't directly depend
on any redirected libraries, and can take care of the hand-over ourselves.

This is part of the ongoing work for issue #30.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-10 01:21:21 +00:00
Ikey Doherty a358864785 lsi: When ~/.config doesn't exist, create it
This helps with problems under snapd build which fails to correctly store
settings on exit, due to a missing directory.

This is part of the ongoing work for issue #30.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-10 01:15:29 +00:00
Ikey Doherty 60664c4c6b shim: Teach shim how to use $SNAP/ prefix for the "real steam"
This is part of issue #30

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-10 01:13:22 +00:00
Ikey Doherty e27d80156f shim: Teach shim how to set LD_AUDIT/LD_PRELOAD when built as a snap
This is part of issue #30.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-10 01:10:38 +00:00
Ikey Doherty 6dbc333ea0 Add big thingy about snap TODO in README
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-09 23:54:58 +00:00
Ikey Doherty 0e10afd27d intercept: Teach new snapd code how to handle NVIDIA issues
This performs the necessary internal redirections for biarch NVIDIA
libraries, as the primary directories do not contain the libraries.
Solus libraries will typically be resolved through "secure execution mode",
which is due to our security builds (full relro, etc.)

This change allows LSI to safely redirect NVIDIA linking requests for the
Steam client, using the hostfs libGL libraries dynamically.

This supports the ongoing work for issue #30.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-09 22:45:48 +00:00
Ikey Doherty 8d93b6b0ca intercept: Add support for snapd libGL redirection
Under a snapd environment, the dynamic linker gets very confused about
where libGL really is, and this causes 32-bit driver usage under LSI
to completely fall flat.

When snapd support is enabled, we'll check for specific path matches and
attempt to override the input request with the intended bi-arch replacement.
This doesn't yet support multiarch, but that will be added in time.

This is part of the ongoing issue #30.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-09 22:00:21 +00:00
Ikey Doherty 103ab0a673 intercept: Let's add some debugs to find out what is going on in snapd
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-09 19:23:19 +00:00
Ikey Doherty 5ed71d781e intercept: When built for snapd, do not override snapd private libs
Certain elements of snapd actually require the (ab)use of snapd to operate,
such as making the NVIDIA proprietary drivers available to the guest snap.
In this instance, if we happen to encounter a library from these search
paths we must unconditionally allow it to be loaded, so that we do not
break libGL resolution.

This adds initial support for issue #30.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-09 19:09:58 +00:00
Ikey Doherty 3eeb731224 intercept: Blacklist vendoring libmpg123/libz/libfreetype
Discovered while validating 'Overlord II', these libraries should be
provided by the LSI integrator, especially at such a low level in the
stack (and mpg123 being security sensitive.)

Additionally these files are relative to the CWD so got missed by the
previous "./" grouping, thus we'll conditionally replace these guys
with the host libraries per the blacklist only.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-08 01:40:46 +00:00
Ikey Doherty ce3cab3270 intercept: Rewrite libopenal-soft.so.1 -> libopenal.so.1
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-08 01:06:17 +00:00
Ikey Doherty 53fec0a8b6 Bump version to 0.6
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-07 18:48:49 +00:00
Ikey Doherty 41c117918c Stop GitHub eating my damned asterisks
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-07 18:31:50 +00:00
Ikey Doherty 88792a27ea Add the disclaimer asterisk everywhere
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-07 18:31:19 +00:00
Ikey Doherty 24c26aeab7 Remove remnants of RST from the .MD
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-07 18:30:09 +00:00
Ikey Doherty ed0153c825 Document liblsi-redirect
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-07 18:28:30 +00:00
Ikey Doherty 7d5ff6a5d4 Not a common issue anymore..
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-07 18:21:09 +00:00
Ikey Doherty b1852cb803 TECHNICAL: Dedupe
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-07 18:20:47 +00:00
Ikey Doherty c524679428 TECHNICAL: Document the new LibreSSL build options
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-07 18:20:18 +00:00
Ikey Doherty 2388f6f693 Slight README cleanup
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-07 18:14:12 +00:00
Ikey Doherty 8cdb63fd7e Split READMEs to provide a human README page (fixes #24)
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-07 18:12:26 +00:00
Ikey Doherty 8591b35a8e Move README to TECHNICAL, as, well, it's not human is it.
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-07 18:03:21 +00:00
Ikey Doherty 950897ab0d po: Sync loads of translations, thank you guys!
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-07 17:49:59 +00:00
Ikey Doherty 45b5652109 intercept: Double space in log triggered me
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-07 17:32:07 +00:00
Ikey Doherty 329f8de9aa intercept: Don't override to the same name (i.e. spam with Vulkan)
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-07 17:31:40 +00:00
Ikey Doherty b001cbf750 intercept: Add support for overriding the use of vendored LibreSSL
This new functionality is about controlling the usage of older LibreSSL
builds within Linux ports. The versions being overriden at the moment
actually come from 2015, hence having this directly in LSI.

Effectively we'll "solve" the issue of not being able to have both
LibreSSL and OpenSSL at the same time, by adding a shim mode. With this
mode we're able to provide new names for the LibreSSL libraries, so that
they can be provided explicitly for LSI usage.

For Solus we've opted to package this up as "libressl-shim", and suffixed
all of the libraries with "-libressl". This can be controlled within the
meson options for best results. For distributions already using LibreSSL
as their native SSL implementation, the `native` option will ensure that
the host libSSL (libressl) is used providing that it has the required
1.0.0 ABI compatibility symlinks.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-07 17:27:12 +00:00
Ikey Doherty ec78c17316 Sync once more to do a test build in Solus
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 20:02:13 +00:00
Ikey Doherty 20db0cad18 Sync po!
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 20:00:21 +00:00
Ikey Doherty 446152e8ad po: Sync German :)
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 19:47:48 +00:00
Ikey Doherty 65805e2d0a common: Fix childish list merge
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 19:46:25 +00:00
Ikey Doherty 32326af2b3 Sync initial translations
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 19:29:39 +00:00
Ikey Doherty 8c304bcd16 po: Rebuild pot
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 19:28:58 +00:00
Ikey Doherty 893100c174 frontend: Make things build again with translations
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 19:28:35 +00:00
Ikey Doherty 709f5cd1c2 Start working translation capability in
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 19:23:49 +00:00
Ikey Doherty 8f531f3be8 Add config for Transifex
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 19:20:25 +00:00
Ikey Doherty e1e4c11b8d Initial meson for po
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 19:16:59 +00:00
Ikey Doherty 347b41f990 frontend: Use proper GTK_CHECK_VERSION macro
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 18:56:47 +00:00
Ikey Doherty e7b2d6f70e frontend: Fix words!
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 18:54:25 +00:00
Ikey Doherty 5732bc2fca frontend: Make sure emul32 stuff works as advertised
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 18:48:13 +00:00
Ikey Doherty 514a7fabb1 frontend: Nuke all the old ugly code
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 18:35:18 +00:00
Ikey Doherty 44a195274b frontend: Write out our settings when the window is closed
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 18:33:46 +00:00
Ikey Doherty 212d938e25 frontend: Update UI sensitivity based on native setting
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 18:27:13 +00:00
Ikey Doherty db4c33fce1 frontend: Read our settings out to the UI controls
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 18:20:38 +00:00
Ikey Doherty 3355bb7cff frontend: Fix the UI spacing and words and such
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 18:17:38 +00:00
Ikey Doherty 3b40061748 frontend: Fix borky sizing
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 18:13:36 +00:00
Ikey Doherty 1edead3929 frontend: Add place-holder for redirect options
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 18:11:30 +00:00
Ikey Doherty da439aa484 frontend: Add new magic function to update row sensitivity in GtkGrid
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 18:08:21 +00:00
Ikey Doherty 991e12d6cd Prettify UI, dynamically use CSD where appropriate
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 18:02:57 +00:00
Ikey Doherty 87bf493350 frontend: Populate bulk of the UI
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 17:44:45 +00:00
Ikey Doherty 22c9805c16 frontend: Start fleshing out new Window-based UI
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 17:33:45 +00:00
Ikey Doherty 84a4dd59a9 frontend: Start skeleton for a proper GObject derived LsiSettingsWindow
We can't properly track state within a big ugly main() function, so let's
start breaking it up into a proper object.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 17:22:06 +00:00
Ikey Doherty 8684a992b0 frontend: Be more flexible
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 16:50:06 +00:00
Ikey Doherty 4303b14f45 frontend: Step 1 in de-fuglying the UI
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 16:44:19 +00:00
Ikey Doherty 7456c9c26a frontend: Stop forcing ugly dark theme for now
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-05 16:20:25 +00:00
Ikey Doherty 0a84ba7fc4 intercept: Allow Steam to use private libx264
Turns out Steam has a vendored x264 library to allow streaming, but right
now we're not whitelisting it. Fix that for issue #25.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-04 18:07:04 +00:00
Ikey Doherty 981fe43071 shim: Respect existing LD_PRELOAD variables
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-11-02 03:21:02 +00:00
Ikey Doherty 63aba59c27 intercept: Add workaround for games loading invalid ".dll.so"
Some games are attempting (and failing) to load .dll.so and should be loading
the ".dll" directly (i.e. Mono games)

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-24 14:37:30 +01:00
Ikey Doherty 3485ab87eb intercept: Redirect broken x86 dlopen() on 64-bit
This was found while testing Project Highrise, which somehow loads the
plugins from /x86/ and not /x86_64/. To combat that, whilst in 64-bit
intercept mode we'll redirect to the relative ../x86_64 directory if
it also has the same .so file present.

This allows Mono to properly "preload" things once more (such as screen
selector, Steam API, etc.).

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-24 01:12:59 +01:00
Ikey Doherty e2325befba redirect: Make it easier to define new bindings
We add some new helpers to make it simpler to define a vtable and
populate it with some symbol binding helper functions.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-24 00:36:39 +01:00
Ikey Doherty a89de2bb58 redirect: Add new workaround for Project Highrise
In the current build of Project Highrise, after the first start of the
game settings are stored. Once that leading structure exists, the game
is now able to see files/directories that weren't there on the first run.

The issue however is that instead of loading "prefs/prefs.txt" on Linux,
the game is loading "prefs" directory with fopen64() as if it were a file,
and then attempting to map it. Malloc bombs out and the game instantly
dies.

This is very likely down to an invalid escaping/path join in the game that
could trivially be fixed, however we'll carry this workaround for now until
such point as a new build is out.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-23 23:40:30 +01:00
Ikey Doherty ede4e130f4 Use explicit version scripts to control symbol visibility
Unfortunately Nica is now very noisy and infects our symbol visibility,
so we'll now control exactly what symbols are exported in our .so's.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-23 20:33:56 +01:00
Ikey Doherty d4eb0ca042 Fix gitmodules so we can git build LSI in ypkg
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-23 20:10:31 +01:00
Ikey Doherty bfb703be68 intercept: Only blacklist common glews (TEMPORARY)
This will permit Super Hexagon to launch, which has a vendored libglew
in tree (1.6 ABI). This is only being allowed on a temporary basis for
two reasons:

 * C ABI and not C++
 * We don't ship this guy in Solus, and don't plan to.

Once LSI is available as a snap, we'll add a super strict mode and then
provide all the GLEW libraries in the image.

This fixes #21.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-23 20:05:21 +01:00
Ikey Doherty d0708a2332 redirect: Unbreak Ark profile
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-23 19:38:19 +01:00
Ikey Doherty a7c59cacef profiles: When running Ark, set up the log ID for debugging
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-23 19:06:27 +01:00
Ikey Doherty 799c4b1e48 redirect: Use fine-grained absolute process name matching
This ensures we only target the games we care about, and don't accidentally
match something using the same binary name.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-23 19:01:16 +01:00
Ikey Doherty ada9b92f53 common: Add new lsi_get_process_name for absolute path
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-23 18:56:23 +01:00
Ikey Doherty 60c3ddc6e9 Rename lsi_get_process_name for clarity
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-23 18:53:48 +01:00
Ikey Doherty c3a071e2a0 redirect: Split hard-coded Ark into separate generation function
This allows us to make profile initialisation more generic, and potentially
support more workarounds in future. For now our entry point will walk the
generator table until a profile is supported.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-23 18:51:14 +01:00
Ikey Doherty 4001ffc814 common: Make William happy (and memory alignment)
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-23 03:29:09 +01:00
Ikey Doherty e3a4640c04 redirect: Reduce spam, don't redirect to non-existent files
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-23 03:08:02 +01:00
Ikey Doherty bddeda6ef3 redirect; Fix process matching again
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-23 03:07:19 +01:00
Ikey Doherty 71322156e3 Leak less!
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-23 03:06:38 +01:00
Ikey Doherty c5bb4ca040 Build redirect paths for all known Steam Paths
This will ensure that if Steam is located on another disk, we're still
able to locate the LibraryFolders stanza in `libraryfolders.vdf` and
add all applicable rules given the realpath()'d resolved paths.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-23 03:02:30 +01:00
Ikey Doherty a2502c1ec7 common: Add the initial VDF parser
This is a node-tree based parser for the Valve Data Format. Currently
it is provided so that we can parse the Steam Client's library configuration
to determine exactly what directories consitute the "installation" for the
user.

At present, this is a "parse or bail" implementation, and doesn't really
do much in the way of pretty printing errors. It's also not geared for
writing VDF files, though if people request it, I'll happily add that.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-23 02:25:06 +01:00
Ikey Doherty 2b2e73b572 redirect: Spam output!
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 03:27:22 +01:00
Ikey Doherty a98ebc3607 profile: realpath all the things!
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 03:26:21 +01:00
Ikey Doherty 78fcdf6247 redirect: Clean up that multiline jankiness
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 03:23:29 +01:00
Ikey Doherty 516823ae3c redirect: Fix broken list behaviour
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 03:13:47 +01:00
Ikey Doherty f2352546d4 redirect: Ensure we deal with absolute paths only
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 03:13:36 +01:00
Ikey Doherty b87210a253 redirect: Walk op table until we have a replacement path
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 03:01:44 +01:00
Ikey Doherty 2d6ab6d497 redirect: Flesh out the basic Ark: Survival Evolved profile
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 02:55:43 +01:00
Ikey Doherty ffdc14c109 redirect: Add API for creating and freeing chained LsiRedirects
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 02:47:49 +01:00
Ikey Doherty e45340973a Fix logging, start fleshing out redirect profile API
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 02:39:47 +01:00
Ikey Doherty 1f73dd3e0b intercept: Prettify output again
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 01:15:18 +01:00
Ikey Doherty fb50dca553 redirect: Set up an initial Ark Survival Evolved profile
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 01:13:55 +01:00
Ikey Doherty edf3176c70 common: Fix derpy log
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 01:13:45 +01:00
Ikey Doherty e73d384726 redirect: Make sure op_table is pointered vfunc table
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 01:04:27 +01:00
Ikey Doherty 30152b9604 redirect: Begin working on new Profile bits
The Profile will allow us to construct reusable/extendable rules
to handle various game issues.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 01:02:18 +01:00
Ikey Doherty a83b1c24b2 Switch all "pretty printing" over to common/log
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 00:50:34 +01:00
Ikey Doherty 0f33bb1fbd redirect: Start using log functions
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 00:39:24 +01:00
Ikey Doherty 88550aeffc common: Add basic (janky) logging system
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 00:37:32 +01:00
Ikey Doherty fe83d34984 redirect: Clean up init, don't use fprintf when OOM
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 00:25:43 +01:00
Ikey Doherty 9b4187ed27 common: Fix symbol visibility once more
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 00:19:52 +01:00
Ikey Doherty b40eba8ad9 Further deduplication (get_process_name, file_exists)
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 00:18:55 +01:00
Ikey Doherty 1179763531 redirect: Don't dupe lsi_file_exists
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 00:16:16 +01:00
Ikey Doherty 627c7639cf Stop building nica lots, build it once inside lsi_common
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 00:14:38 +01:00
Ikey Doherty 290260c09e Move common.h into common library
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 00:12:04 +01:00
Ikey Doherty a691985541 Dedupe, implement support for getting steam directory
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 00:10:49 +01:00
Ikey Doherty 1811ff5225 lsi: Dedupe into common
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 00:03:51 +01:00
Ikey Doherty a932486826 Start splitting out a new common library
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-22 00:02:18 +01:00
Ikey Doherty 3c69b6dc05 Switch to C11 so we get unnamed structs/unions
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 20:25:25 +01:00
Ikey Doherty c8f0cecb15 redirect: Start designing the generic ops table
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 20:24:57 +01:00
Ikey Doherty 3b01919148 shim: Set LD_PRELOAD for libredirect if enabled
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 19:46:25 +01:00
Ikey Doherty 474aca0b69 lsi: Teach config how to handle toggle on libredirect
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 19:46:13 +01:00
Ikey Doherty fa81893d41 Be a little bit less verbose
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 19:19:27 +01:00
Ikey Doherty f958b8ac3f redirect: Cheeky initial hack to see if we can replace paths
This is a very ugly hack right now but we'll prettify it and make
it all more generic, but right now it'll hotswap the depthblur
in Ark for the one coming from "TheCenter" mod.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 19:18:30 +01:00
Ikey Doherty 971d0c280e redirect: Temporarily teach it about ShooterGame for debugging
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 19:02:58 +01:00
Ikey Doherty 4f6166bdce redirect: Add basic code path for "if lsi_override"
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 18:44:09 +01:00
Ikey Doherty be98e146ed redirect: Differentiate between table + lsi redirect init
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 18:42:22 +01:00
Ikey Doherty 5c131f6b28 redirect: Fix open args for variadic functions
Also mark stuff as fatal because at this point we've override `open` ..

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 18:31:24 +01:00
Ikey Doherty 8768730414 redirect: Add our initial dlsym/dlopen dance to grab real open
Instead of relying on RTLD_NEXT we'll do the correct thing and open a
reference to libc.so.6 and load the `open` function from there, as our
linking order might be janky, causing lookups for `open` to actually fail.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 18:13:27 +01:00
Ikey Doherty 68fe3c1c11 redirect: Comments pls
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 17:58:33 +01:00
Ikey Doherty dc85a14bfb redirect: Increase chance of shutdown handler via volatile atexit
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 17:56:34 +01:00
Ikey Doherty c646ee516e redirect: Fix copy/paste issue
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 17:52:52 +01:00
Ikey Doherty bb29a04078 redirect: Add the usual get_process_name dance
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 17:52:35 +01:00
Ikey Doherty 0eb0d09119 Remove destructor for now, virtually zero chance of it ever running
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 17:49:28 +01:00
Ikey Doherty 5810e63576 Force debugoptimized as we stripped CFLAGS from Solus environment
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 17:16:43 +01:00
Ikey Doherty 01faa3754d redirect: Start skeleton for new liblsi-redirect
We're left in the awkward position that there are some games that **still**
misbehave on Linux, and generally do Dumb Things. So to get around the fact
that some vendors basically stopped caring about us, we'll create a special
`LD_PRELOAD` library that is responsible for redirecting syscalls to basically
monkeypatch broken behaviour completely.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-21 17:15:29 +01:00
Ikey Doherty b4e512b708 intercept: Allow loading CPU based swiftshader libGLESv2.so
This fixes issue #17 by whitelisting the library once more for the main
collection of binaries in the Steam client.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-19 04:37:13 +01:00
Ikey Doherty 95613a45f8 intercept: Add soname rewrite rules for remaining SDLs
This further helps with getting Outlast to work properly.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-15 20:44:38 +01:00
Ikey Doherty 312b7a888a Just group the security ones.
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-15 20:39:28 +01:00
Ikey Doherty 071304d8bd Point blame to right place in comment
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-15 20:39:06 +01:00
Ikey Doherty 36e6cf5455 intercept: Prevent HyperLightDrifer loading 5 year old SSL library.
This will resolve issue #19.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-15 20:29:19 +01:00
Ikey Doherty 26dc2503d2 intercept: Add rewrite soname rule for SDL2 TTF
This should help with issue #18 but will need testing

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-15 19:38:51 +01:00
Ikey Doherty 1d81c2094f intercept: Teach liblsi-intercept to rewrite dlopen requests for XNA
We currently have a layered block and rewrite system that prevents games
from using vendored SDL, openal, core libs, etc. However the Mono games such
as Stardew Valley will locally load paths using dlopen(), which we've been
blacklisting.

When we now detect a dlopen() to the vendored paths, we'll attempt to rewrite
those to meet the system paths which then forces the dlopen() to resolve to
the system SDL, openAL, etc.

This resolves issue #16.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-15 18:23:18 +01:00
Ikey Doherty fe063b1624 intercept: Blacklist games from replacing security-sensitive libcurl
As seen in DiRT Rally, the Feral Interactive port is replacing libcurl.so.4,
which is a security sensitive library, known to update against CVEs with
frightening frequency.

Protect our users, and ensure system libcurl is used.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-13 15:48:31 +01:00
Ikey Doherty fa41b2c572 intercept: Only emit soname change when LSI_DEBUG is set
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-13 15:43:27 +01:00
Ikey Doherty feae99a359 intercept: Teach libintercept to transmute sonames for Feral Interactive games
Internally libintercept has a number of magic tricks to prevent games from
replacing the system SDL libraries with vendored ones. However, during testing
with DiRT Rally, it was discovered that Feral Interactive have altered the
sonames of their libraries and linked to those, ensuring they never match
the system versions.

This however will lead to a mixed SDL2 stack for those disabling the Steam
runtime, and in turn forces older builds of SDL to be used. To combat this,
we intercept soname requests during early linking based on a simple pattern,
and if they don't match the expected target name, we'll rewrite the request
in place to force the linker to look for the real soname.

In combination with the existing lsi_blacklist_vendor function, this ensures
that a game looking for `libSDL2-2.0.5.so` will correctly load the system's
own `libSDL2-2.0.so.0`.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-13 15:30:00 +01:00
Ikey Doherty 34fe25a533 Rename the LICENSE file as GitHub is a bit slow on that front.
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-13 03:02:54 +01:00
Ikey Doherty 6349652740 intercept: Clamp down on libGL{,ES}, libGLU*, and libGLEW offenders
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-13 02:48:52 +01:00
Ikey Doherty 665caee634 Document the effects of LD_AUDIT with unpatched glibc versions
This goes some way to satisfy the concerns of issue #15 so that everyone
knows where they stand, how to mitigate this **now**, and what we intend
to do about this in future.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-12 16:16:10 +01:00
Ikey Doherty be3023263f Bump version to 0.5 for release
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-12 02:56:27 +01:00
Ikey Doherty 27e5cd0ae0 intercept: Ensure openAL isn't replaced with broken vendor libraries
We often see cases where the vendored openAL library is incapable of HRTF
due to some old or broken openAL version/build, so let's stop games doing
that with the vendor_offender mode.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-12 02:53:50 +01:00
Ikey Doherty 79fece840c intercept: Actually really blacklist it. Like seriously
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-12 02:46:05 +01:00
Ikey Doherty 478a0f1810 intercept: Hit Black Mesa with a really, really big hammer.
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-12 02:27:34 +01:00
Ikey Doherty 2cf5db42b3 intercept: Use private file exists function to strip nica API from exposed ABI
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-12 02:20:38 +01:00
Ikey Doherty 191ea02946 intercept: Remove much in the way of symbol visibility issues
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-12 02:19:46 +01:00
Ikey Doherty 03dd537574 intercept: Prevent "Black Mesa" from using vendored libstdc++/libSDL
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-12 02:06:35 +01:00
Ikey Doherty 8ded405801 intercept: Decouple hardcoding from the Steam logic
This allows us to match process names to work modes, so that we'll take one
path for Steam, and allow another path completely for "vendor offenders".

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-12 01:57:45 +01:00
Ikey Doherty 35b3f132fd intercept: Use globally defined tables to make it easier to extend
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-12 01:47:54 +01:00
Ikey Doherty 4b718a4bc7 shim: Always respect steam-binary option
This resolves issue #13, but requires the packagers are explicit in setting
the steam path.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-11 21:01:01 +01:00
Ikey Doherty 5ceacb27fb Post-update mkrelease script
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-11 16:26:55 +01:00
Ikey Doherty d1b7a86867 Bump version to 0.4.1
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-11 16:19:59 +01:00
Ikey Doherty 0c252321e3 Document config properly for use-libintercept
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-11 16:18:06 +01:00
Ikey Doherty b9d677dee1 Let the fine folks know where they can get LSI
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-11 16:02:33 +01:00
Ikey Doherty 86fbf11040 Merge pull request #12 from alunux/master
Use `value` instead `default` keyword in with-shim build option
2017-10-11 14:30:42 +01:00
La Ode Muh. Fadlun Akbar ec67c801ad meson_options: Use value instead default keyword in with-shim option 2017-10-11 17:45:01 +07:00
Ikey Doherty 0a02c111a0 Can't go to bed with that looking me in the face.
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-11 02:57:58 +01:00
Ikey Doherty 48a9bac406 Fix up RST remnants, add some more debugging info
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-11 02:47:37 +01:00
Ikey Doherty 8de8962099 Improve README formatting
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-11 02:42:40 +01:00
Ikey Doherty de9380dc8d Make the README somewhat useful.
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-11 02:40:46 +01:00
Ikey Doherty 9bd423fb34 intercept: Dedupe the list
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-11 01:58:20 +01:00
Ikey Doherty 75d2e9cc45 Restore option for controlling libcxx abi for LD_PRELOAD, fixes steam runtime
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-11 01:28:48 +01:00
Ikey Doherty 7d0acc9891 Add script to magically make a tarball, bump version to 0.4
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-11 00:32:29 +01:00
Ikey Doherty 7bae532d85 Update README with details about the intercept library
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-11 00:23:16 +01:00
Ikey Doherty 4f332c9acf Update mkgobuildy to install directly to the system
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-11 00:16:54 +01:00
Ikey Doherty f2dddd9f88 intercept: Catch the last of the SDL offenders like steamwebhelper
This now ensures steamwebhelper is also using our SDL as it was previously
loading from a relative location. This actually fixes issues on my local
system whereby the steam trailer videos couldn't full screen properly,
now using our own SDL, they can.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-11 00:15:52 +01:00
Ikey Doherty 94d5c6d939 intercept: Pretty print stuff
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 23:38:12 +01:00
Ikey Doherty f4564e2ab8 intercept: Be spammy only on demand, and provide relevant information
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 23:33:11 +01:00
Ikey Doherty 8d85cb3bed Fix storage of the use-libintercept setting
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 23:28:40 +01:00
Ikey Doherty fb2e84cb97 frontend: Teach UI how to control the libintercept setting
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 23:23:48 +01:00
Ikey Doherty e1f2783d11 shim: Allow disabling libintercept from config
Note libintercept requires that we use the native runtime, otherwise very
bad things will happen. ™

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 23:18:11 +01:00
Ikey Doherty 13afbe69c3 lsi: Teach configuration about libintercept toggle
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 23:17:29 +01:00
Ikey Doherty b458346f5a Fix invalid date range for copyright assignment
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 23:12:53 +01:00
Ikey Doherty bf4fcfe533 Fix another trace of autotools
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 23:11:39 +01:00
Ikey Doherty b7ba890433 Start updating README for meson
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 23:10:47 +01:00
Ikey Doherty faa0c3a154 Nuke ancient TODO that knows not of which it speaks
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 23:06:32 +01:00
Ikey Doherty 99e54dd74b Drastically simplify gitignore..
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 23:05:58 +01:00
Ikey Doherty 5d18366a17 Nuke old autotools cruft
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 23:05:30 +01:00
Ikey Doherty 6154f2373c Allow installing .desktop files once more
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 23:03:51 +01:00
Ikey Doherty fe80861f66 frontend: Fix linking once more
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 23:00:12 +01:00
Ikey Doherty 38ec05ce98 Move lsi into new subdir to be reused as static lib
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 22:59:33 +01:00
Ikey Doherty d983f8ebdf Add currently failing build for frontend
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 22:54:51 +01:00
Ikey Doherty 4d3abc5e37 Enable GTK frontend, don't build Shim for 32-bit
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 22:52:45 +01:00
Ikey Doherty 47e50b789f shim: Only set LD_AUDIT if we were built with libintercept enabled
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 22:51:40 +01:00
Ikey Doherty 9905a2bc81 intercept: Allow controlling build of this library
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 22:50:28 +01:00
Ikey Doherty 11e1d8ae5f shim: Build lsi-steam or not at all, depending on meson options
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 22:46:19 +01:00
Ikey Doherty 00e78f705e Only build frontend and look for GTK if its requested
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 22:44:02 +01:00
Ikey Doherty 54c685bb1a Set things up to be configured via meson options
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 22:42:07 +01:00
Ikey Doherty a61e22d677 shim: When using native runtime, load liblsi-intercept in LD_AUDIT
liblsi-intercept has a simple job of stopping Steam from trying to
replace all of the system libraries in a mish-mash approach. Even when
we have STEAM_RUNTIME=0, and even with the advent of the new "prefer host
libraries" system, the internal replacements and pinning system actually
break massively.

To counteract this issue, we use our own rtld-audit implementation when
launching the real Steam, which will severely restrict which libraries the
main Steam binaries are actually allowed to load. This is on a whitelist
basis and ensures that the host libraries will be used where appropriate,
i.e. SDL, X11, etc. This prevents compatibility issues as well as the random
crashes we're now seeing with Steam beta.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 22:31:25 +01:00
Ikey Doherty 93b0f82279 Hack stuff up so we can build shim again
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 22:27:54 +01:00
Ikey Doherty d870577a55 intercept: Add missing modelines
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 22:07:15 +01:00
Ikey Doherty fd252e265d Move common helpers to common.h to fix compilation warnings
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 22:07:02 +01:00
Ikey Doherty 3684dfe11e intercept: More unused code
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 22:04:22 +01:00
Ikey Doherty d5b31dbf54 intercept: That guy is unused
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 22:03:43 +01:00
Ikey Doherty f6dcc30d33 shim: Ensure we disable GTK_MODULES (thanks @cybre!)
Same reason as XMODIFIERS - it'll stop Steam starting up properly

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 21:56:11 +01:00
Ikey Doherty 7a2670f3e1 intercept: Completely clamp down on Steam, allow only Steam's own libs
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 21:54:59 +01:00
Ikey Doherty 61d9296a6c Let's pretend that one didnt happen
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 21:07:36 +01:00
Ikey Doherty f2bbe963b6 Clean up script so LD_AUDIT is a thing again
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 20:52:12 +01:00
Ikey Doherty 4547d8582a One more test to ensure this isnt environment related
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 20:50:50 +01:00
Ikey Doherty 1db376fa38 Turns out fatal is bad always because Steam is bad. Also, preload again
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 20:45:36 +01:00
Ikey Doherty 0bf704fc79 We like segfaults
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 20:44:08 +01:00
Ikey Doherty cf023ffb6a Ensure XMODIFIERS go bye bye
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 20:42:53 +01:00
Ikey Doherty 4b36347ade Remove unused define
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 20:41:51 +01:00
Ikey Doherty d3469e3eb0 intercept: Add quick hack which *should* work
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 20:37:19 +01:00
Ikey Doherty 29081c492d Make build script a bit more robust..
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 20:32:52 +01:00
Ikey Doherty ac76372b84 Add helper script so we can easily test liblsi-intercept
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 20:31:26 +01:00
Ikey Doherty 6b107f33b5 Ensure we can build everything now.
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 20:29:13 +01:00
Ikey Doherty ba8ae8f384 Add mkgobuildy to handle dual builds..
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 20:26:33 +01:00
Ikey Doherty d77ad58934 Remove intercept-emul32 because meson is weak a.f.
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 20:24:47 +01:00
Ikey Doherty 2aae934271 Ensure we can build 32-bit and 64-bit libraries together
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 20:16:11 +01:00
Ikey Doherty 12d5268252 Split emul32 into new dir
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 20:07:59 +01:00
Ikey Doherty 15253b97df Fail massively. But progress.
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 20:06:02 +01:00
Ikey Doherty 8dd27f6f24 intercept: Actually compile..
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 20:02:28 +01:00
Ikey Doherty f21559ee78 Make config.h work again
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 20:01:47 +01:00
Ikey Doherty 5b17fe9447 Start teaching intercept how to build (not complete.)
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 19:56:37 +01:00
Ikey Doherty 9ca7ffdd85 Get two nicas building, native and emul32
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 19:52:06 +01:00
Ikey Doherty 3b552ec17d Begin meson conversion.. Not yet building anything
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 19:46:00 +01:00
Ikey Doherty a3226a293c intercept: Build a static override table
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 19:15:21 +01:00
Ikey Doherty 9c40a9d106 intercept: Account for more processes
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 19:13:06 +01:00
Ikey Doherty 49d68c52a7 intercept: Teach intercept how to override libSDL2
This doesn't actually work properly yet as we need to build dual libraries
for 32-bit and 64-bit to ensure LD_AUDIT is non-fatal.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 19:09:30 +01:00
Ikey Doherty d20c230067 Begin basic libintercept design
This is the very start of our adventure into rtld-audit, and effectively
we'll have liblsi-intercept loaded by LD_AUDIT via our Steam LSI shim, and
when we find an interesting process, we'll match that process name and
activate ourselves.

In future, we'll want to blacklist Steam from being able to load duplicated
libraries on the system, i.e. libSDL, to resolve a number of crashes.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 18:17:14 +01:00
Ikey Doherty bd4707f3ca Fix nica submodule URI
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-10 14:53:26 +01:00
Ikey Doherty 1a70578cb1 shim: Work around Steam client's SDL regression with XMODIFIERS
The version of SDL shipping with Valve's Steam Client has a regression
that fails to correctly `SDL_InitSubSystem` whenever `XMODIFIERS` is set,
talking to dbus objects with no set address.

Relevant issue: ValveSoftware/steam-for-linux#501

This change will ensure that SDL can initialise correctly on startup,
and no longer make users suffer crashes.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2017-10-09 20:03:08 +01:00
Ikey Doherty 7995688ea2 Convert README to MD, and explain what LSI is, underp formatting
This resolves issue #6

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2016-12-27 08:00:49 +00:00
Ikey Doherty e3360b7ddc Bump v3
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2016-12-09 00:16:46 +00:00
Ikey Doherty 1700f2616c Ensure we report that lsi-steam.desktop borrows translations
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2016-12-09 00:15:50 +00:00
Ikey Doherty 6f8e905569 Update README for --disable-replace-steam, remove excess in text
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2016-12-09 00:09:50 +00:00
Ikey Doherty 7c0ff5031e data: Incorporate actions from primary steam.desktop
Steam no longer writes a custom .desktop in into the local user directory,
so if the user is using a desktop that supports pinning a .desktop file,
it will be this one.

Thus, we enable the same actions, but going through the proxy of LSI.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2016-12-08 23:56:58 +00:00
Ikey Doherty dd5237e648 shim: Launch vanilla /usr/bin/steam when replacement is disabled
When we're not built for distro integration, we'll now call out to
/usr/bin/steam with the LSI modifications in place, so that we don't
enter into an infinite recursion.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2016-12-08 23:54:20 +00:00
Ikey Doherty 2282296045 Add an option to disable replacement of the Steam binary
LSI was initially created for Solus inclusion, and the best approach
determined was to replace /usr/bin/steam with our own stand in shim,
so that it was fully integrated.

Doing so enables one to run steam from anywhere and it would correctly
appear in the path, with no issues. However, this made LSI suitable
only for distribution integration, such as the very tight integration
seen in Solus.

With this change, the binary name will change to lsi-steam, and an
additional .desktop file to launch the shim will be installed. The
user must then use the LSI specific .desktop file to launch Steam,
at which point they'll be going through the LSI shim system and
reaping the benefits, without having to modify any packages.

More changes are yet to come, which will configure lsi-steam to call
the "real" steam in exec rather than the masked libdir variant.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2016-12-08 23:45:02 +00:00
Ikey Doherty ba48264207 update_format: Exclude nica from modification
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2016-12-08 22:28:07 +00:00
Ikey Doherty bddc0f29b1 Hook libnica into autotools and use this version now
TODO: Make coverage of libnica more intelligent so that we can drop
the extra conditional.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2016-12-08 22:16:20 +00:00
Ikey Doherty 196a039746 Include libnica as a git submodule
This ensures we only need to maintain the library in one place, greatly
reducing the complexity of integration and updating of the library.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2016-12-08 22:13:33 +00:00
Ikey Doherty 4ff98e225a Remove our local forked copy of libnica
This will pave the way for embedding libnica as a submodule and building
against the static library, removing any requirements for having the shared
library present.

As it seems nica fits better currently as a utility library, that's not
such a bad thing.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2016-12-08 22:12:11 +00:00
Ikey Doherty e49a7873fe Preload libxcb now with latest Steam runtime
It explicitly checks for xcb_poll_for_reply64, which must be preloaded before
libx11 to ensure it's properly resolved.

Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2016-10-12 04:40:31 +01:00
Ikey Doherty 6659905102 Merge pull request #4 from philipzae/patch-1
correct link to solus website
2016-07-25 22:03:38 +01:00
Yousuf 'Jay' Philips 16702d0d8f correct link to solus website 2016-07-25 23:44:14 +04:00
Ikey Doherty 00d8831720 nica: Sync with upstream commit a8b1f1ee423f386d1ff676d4173ebd83a64656de
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2016-06-15 13:01:23 +01:00
Ikey Doherty 451ffe7680 nica: Sync with upstream
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
2016-06-11 18:47:54 +01:00
107 changed files with 8787 additions and 1820 deletions
Binary file not shown.

After

Width:  |  Height:  |  Size: 104 KiB

+2 -18
View File
@@ -1,18 +1,2 @@
Makefile
Makefile.in
aclocal.m4
autom4te.cache/
build-aux/
config.*
configure
libtool
stamp-h1
m4/*.m4
.deps
.dirstamp
*.o
*.lo
*.la
.libs
/steam
/lsi-settings
/buildroot/
/build/
+3
View File
@@ -0,0 +1,3 @@
[submodule "src/libnica"]
path = src/libnica
url = https://github.com/intel/libnica.git
+8
View File
@@ -0,0 +1,8 @@
[main]
host = https://www.transifex.com
[linux-steam-integration.linux-steam-integrationpot]
file_filter = po/<lang>.po
source_lang = en
type = PO
View File
-82
View File
@@ -1,82 +0,0 @@
EXTRA_DIST = \
LICENSE.LGPL2.1 \
README.rst \
data/lsi-settings.desktop
AM_CFLAGS = \
-fstack-protector -Wall -pedantic \
-Wstrict-prototypes -Wundef -fno-common \
-Werror-implicit-function-declaration \
-Wformat -Wformat-security -Werror=format-security \
-Wno-conversion -Wunused-variable -Wunreachable-code \
-Wall -W -D_FORTIFY_SOURCE=2 -std=c99
AM_CPPFLAGS = \
-I $(top_srcdir)/src \
-I $(top_srcdir)/src/shim \
-I $(top_srcdir)/src/nica \
-DSYSTEMCONFDIR=\"$(sysconfdir)\" \
-DVENDORDIR=\"$(datadir)/defaults/linux-steam-integration\"
noinst_LTLIBRARIES = \
libnica.la \
liblsi.la
bin_PROGRAMS = \
steam
if HAVE_FRONTEND
bin_PROGRAMS += lsi-settings
lsi_settings_SOURCES = \
src/frontend/main.c
lsi_settings_CFLAGS = \
$(GTK_CFLAGS) \
$(AM_CFLAGS) \
-DGDK_VERSION_MAX_ALLOWED=GDK_VERSION_3_4 \
-DGDK_VERSION_MIN_REQUIRED=GDK_VERSION_3_4
lsi_settings_LDADD = \
liblsi.la \
$(GTK_LIBS)
desktopdir = $(datadir)/applications
desktop_DATA = \
data/lsi-settings.desktop
endif
# Convenience library to prevent external linking with currently unstable ABI
libnica_la_SOURCES = \
src/nica/hashmap.h \
src/nica/hashmap.c \
src/nica/inifile.h \
src/nica/inifile.c \
src/nica/util.h
libnica_la_CFLAGS = \
$(AM_CFLAGS)
# Convenience library for shared LSI functions
liblsi_la_SOURCES = \
src/shim/lsi.h \
src/shim/lsi.c
liblsi_la_CFLAGS = \
$(AM_CFLAGS)
liblsi_la_LIBADD = \
libnica.la
steam_SOURCES = \
src/shim/shim.c
steam_LDADD = \
libnica.la \
liblsi.la
steam_CFLAGS = \
$(AM_CFLAGS)
+91
View File
@@ -0,0 +1,91 @@
linux-steam-integration
-----------------------
Linux Steam* Integration is a helper system to make the Steam Client and Steam
games run better on Linux. In a nutshell, LSI automatically applies various workarounds
to get games working, and fixes long standing bugs in both games and the client.
![screenshot](https://raw.githubusercontent.com/clearlinux/linux-steam-integration/master/.github/LSI_Settings.png)
In many cases this will involve controlling which libraries are allowed to be used
at any given time, and these libraries may be overriden for any of the following
reasons:
- Security
- Compatibility
- Performance
This project, and by extension the platforms it runs on, are not officially endorsed by, or affiliated with, Steam, or its parent company, Valve*.
This fork of linux-steam-integration is now being maintained separately from the original project, to suit the cadence and requirements of the
Clear Linux* Project for Intel Architecture.
This project will retain backwards compatibility with the original project at the time of forking to alleviate maintainer concerns, whilst focusing
on improvements to match a wider audience than the original project, and ensuring native runtimes continue to work unimpeded.
### Linking compatibility
With LSI, you don't need to worry any more about manually mangling your Steam installation
just to make the open source drivers work, or manually creating links and installing
unsupported libraries. LSI is designed to take care of all of this for you.
Many library names are redirected through the main "intercept" module, which ensures
games will (where appropriate) use the updated system libraries. Additionally the
module can override how games and the Steam client are allowed to make use of
vendored libraries. This will help with many launch failures involving outdated
libraries, or indeed the infamous `libstdc++.so.6` vendoring which breaks open
source graphics drivers on systems compiled with the new GCC C++ ABI.
### Apply path based hotfixes to games
The redirect module contains some profiles to allow us to dynamically fix some
issues that would otherwise require new builds of the games to see those issues
resolved.
- Project Highrise: Ensure we don't `mmap` a directory as a file (fixes invalid prefs path)
- ARK Survival Evolved: Use the correct shader asset from TheCenter DLC to fix broken water surfaces.
### Unity3D Black Screen Of Nope
Older builds of Unity3D had (long since fixed) issues with launching to a black
screen when defaulting to full screen mode. This is commonly addressed by launching the
games with `-screen-fullscreen 0`, and is due to an invalid internal condition clamping
the renderer size to 0x0 after setting the fullscreen (borderless) window size.
Note - updating these games to newer versions of Unity will fix this bug on Linux, however
LSI currently ships a workaround. This workaround will abstract access to the configuration
file in `$XDG_CONFIG_HOME/.config/unity3d/*/prefs` through the Linux `/dev/shm` system,
and will provide initial game configuration whilst also masking the harmful fullscreen
setting.
Net result - all Unity3D games using this pref path (the older generation) will start
in windowed mode always. They can be fullscreened from inside the game, and this will
help with making sure games **actually launch**.
### Notes
Note that LSI will not modify your Steam installation, and instead makes use of two
modules, `liblsi-redirect.so` and `liblsi-intercept.so`, to dynamically apply all of the
workarounds at runtime, which in turn is set up by the main LSI `shim` binary.
For a more in depth view of what LSI is, and how to integrate it into your distribution,
please check the [technical README document](https://github.com/clearlinux/linux-steam-integration/blob/master/TECHNICAL.md).
## License
Copyright © 2016-2018 Ikey Doherty
Copyright © 2018-2019 Intel Corporation
linux-steam-integration is available under the terms of the `LGPL-2.1` license.
See the accompanying `LICENSE.LGPL2.1` file for more details
`data/lsi-steam.desktop`:
This file borrows translations from the official `steam.desktop` launcher.
These are copyright of Valve*.
`* Some names may be claimed as the property of others.`
-148
View File
@@ -1,148 +0,0 @@
linux-steam-integration
-----------------------
A helper shim to enable better Steam* integration on Linux systems.
This is part of an effort by Solus to enhance Steam for everyone.
This project, and by extension Solus, is not officially endorsed by, or
affiliated with, Steam*, or its parent company, Valve*.
Linux Steam Integration (LSI) is a `Solus Project <https://github.com/solus-project/linux-steam-integration/issues/2>`_
.. image:: https://build.solus-project.com/logo.png
:align: center
:alt: LSI is a Solus Project
Integrating LSI
===============
To correctly integrate LSI, your Steam package will require modification.
LSI must provide the /usr/bin/steam binary, so your Steam package must
move the main launcher to a shadow location.
**Configuring LSI build**
There are a number of configure options you should be aware of when integrating
LSI correctly. The prominent ones are explained here.
``--with-real-steam-binary=$NAME``
Set the absolute path for the shadowed Steam binary.
LSI will execv Steam after it has initialised the environment.
Note that execv, not execvp, is used, to mask programs that may be
in the ``$PATH``, hence requiring an absolute path.
The default value for this option is::
/usr/lib/steam/steam
``--with-preload-libs=$LIBS``
A colon separated list of libraries that are required to launch Steam
when using its own runtime. LSI enables users to switch back to the Steam
runtime, and in this instance we manage the LD_PRELOAD environmental variable.
Ensure this is correct, and escape $LIB for correct Linux usage.
The default value for this option is::
/usr/\$LIB/libX11.so.6:/usr/\$LIB/libstdc++.so.6
``--enable-frontend``
A small UI application is shipped to enable configuration of LSI, which presents
a simple GTK3 Dialog to the user. It is not enabled by default, it is up
to the integrator to decide if they wish to employ lsi-settings, or implement
an alternative.
The lsi-settings application will only ever write new configurations to the
**user** settings file, and requires no special permissions.
The default value for this option is::
disabled
**How LSI Works**
LSI provides a /usr/bin/steam binary to be used in place of the existing Steam script,
which will then correctly set up the environment before swapping the process for the
Steam process.
Configuration options can be placed in an INI-style configuration file in a series
of locations, which are ordered by priority in a cascade::
~/.config/linux-steam-integration.conf
/etc/linux-steam-integration.conf
/usr/share/defaults/linux-steam-integration/linux-steam-integration.conf
The user configuration takes immediate priority. Secondly we have the system-wide
configuration for affecting all accounts, and lastly the vendor configuration,
which may be provided by the integrator.
Currently this INI file supports two options. The root section in this INI file
must be ``[Steam]``.
``use-native-runtime = $boolean``
If set to a true boolean value, (yes/true/on), the host OS's native runtime
will be used instead of the Steam provided runtime. If this is set to
a false boolean value (no/false/off), then the startup will be modified
to export the relevant ``LD_PRELOAD`` and ``STEAM_RUNTIME`` settings.
The default value of this variable is ``true``.
``force-32bit = $boolean``
If set to a true boolean value (yes/true/on), the shadowed Steam binary will
be run via the ``linux32`` command. This will force the ``steam`` process
and all children to believe they are running on a 32-bit system. This
may be useful for 64-bit games that are buggy only on 64-bit.
If this is set to a false boolean value (no/false/off), then the
shadowed Steam binary will be directly executed. Note that on 32-bit
OSs this setting is ignored.
The default value of this variable is ``false``.
Common issues
=============
**Missing tray icon for Steam client using native OS runtime**
Ensure you have the 32-bit version of libappindicator installed. This
is required for the tray icon. libappindicator falls back to a standard
X11 tray icon in the absence of desktop appindicator support.
Related issue: `Steam tray icon missing #2 <https://github.com/solus-project/linux-steam-integration/issues/2>`_
License
-------
``src/nica``::
Partial import of libnica, Copyright © Intel Corporation.
Used within the shim component to ensure it is leak free
and as lightweight as possible, due to needing to exec the
main Steam* launcher.
libnica is available under the terms of the `LGPL-2.1` license.
``src/shim src/frontend``::
Copyright © 2016 Ikey Doherty
linux-steam-integration is available under the terms of the `LGPL-2.1`
See `LICENSE.LGPL2.1 <LICENSE.LGPL2.1>`_ for more details
* Some names may be claimed as the property of others.
+276
View File
@@ -0,0 +1,276 @@
linux-steam-integration
-----------------------
Linux Steam Integration is a software package aimed squarely at Linux distribution developers.
It is designed to offer a far better Steam* experience than the stock client, doing away with old
integration issues and crashes.
### Native Libraries
LSI enforces the use of host-native libraries, both in the Steam Client (via `lsi-intercept`) and
games themselves. This ensures Steam integrates properly, games run with the latest libraries
and users get the best performance.
Currently the officially provided Steam runtime is based on very old Ubuntu 12.04 packages,
and has some cherry-picked updates (SDL, for example). This causes lots of integration issues
on most newer distributions, such as broken client behaviour with full screen videos, outright
crashes on startup, mismatched C++ ABI, missing sound, ugly menus, broken font rendering,
poor performance, etc.
In a nut shell, LSI will force most of Steam over to using native libraries. The intercept
system is new as of 0.4, and will be extended in future to allow improving certain games
on a process-name whitelisting basis.
### Configurable
You can easily toggle the use of the native runtime or the runtime provided with the official
Steam package distribution. LSI doesn't butcher any files, so your local Steam directory does
not need to be repaired or reinstalled. Just run `lsi-settings` and restart Steam.
Currently you can control whether the native runtime is used, force 32-bit mode for some troublesome
ports, and control whether the intercept library is enabled (which will undo the various library
mangling tricks of the Steam distribution to force the usage of the system libs via rtld-audit)
### Portable
You can (and should) stick this into any distro. Hit us up if you need help integrating, or need some
portability changes made. We won't bite.
### Going beyond LSI
LSI solves a great many issues, however there is then still a responsibility for the integrating distribution
to provide basic ABI compatibility, as well as being functionally comparable to the "stock" runtime.
Our future plans will basically involve creating a project based around LSI and a specially produced,
optimised Steam runtime, usable on all Linux distributions.
If you want to be part of that effort - and help bring a modern, optimised gaming experience to your Linux
users, please get in contact. Let's do this once, and do it right.
## Integrating LSI
To correctly integrate LSI, your Steam package will require modification. LSI must provide the `/usr/bin/steam binary`, so your Steam package must move the main launcher to a shadow location.
For users who do not have access to LSI in their distribution, because it has not been integrated yet, please configure with `-Dwith-shim=co-exist` to preserve your existing Steam integrity. Then use the "LSI Steam" shortcut in your menu to launch Steam via LSI.
**Configuring LSI build**
There are a number of meson configure options you should be aware of when integrating LSI correctly. The prominent ones are explained here.
`-Dwith-shim= none | co-exist | replacement`
Control behaviour of the shim build. `none` will disable building the main
shim, required for actually launching Steam in the first place.
`co-exist` will ensure this does not conflict with the `/usr/bin/steam`
path, providing a new `lsi-steam` binary and desktop file.
`replacement` will provide a drop-in replacement `/usr/bin/steam` binary
shim responsible for bootstrapping Steam via LSI. This will require you
to mask the original steam binary to a new location.
The default value for this option is:
`replacement`
`-Dwith-steam-binary=$PATH`
Set the absolute path for the shadowed Steam binary.
LSI will execv Steam after it has initialised the environment.
Note that execv, not execvp, is used, to mask programs that may be
in the `$PATH`, hence requiring an absolute path.
The default value for this option is:
`/usr/lib/steam/steam`
This option is only applicable for distribution integrators, when
Steam replacement is enabled.
`-Dwith-preload-libs=$LIBS`
A colon separated list of libraries that are required to launch Steam
when using its own runtime. LSI enables users to switch back to the Steam
runtime, and in this instance we manage the LD_PRELOAD environmental variable.
Ensure this is correct, and escape $LIB for correct Linux usage.
The default value for this option is:
`/usr/\$LIB/libX11.so.6:/usr/\$LIB/libstdc++.so.6`
`-Dwith-new-libcxx-abi=$boolean`
Enable this if your distribution uses a recent libstdc++ build, from
GCC 6 or higher.
`-Dwith-frontend=$boolean`
A small UI application is shipped to enable configuration of LSI, which presents
a simple GTK3 Dialog to the user. It is not enabled by default, it is up
to the integrator to decide if they wish to employ lsi-settings, or implement
an alternative.
The lsi-settings application will only ever write new configurations to the
**user** settings file, and requires no special permissions.
The default value for this option is:
`false`
`-Dwith-libressl-mode= none | native | shim`
Control how LSI's `liblsi-intercept.so` handles LibreSSL.
The intercept module can be configured to enhance security of Linux ports
by ensuring they use up to date LibreSSL builds.
When set to `native`, it is assumed the distro is employing LibreSSL as the
default libSSL ABI (i.e. `libssl.so.1.0.0`)
When set to `shim`, LSI will redirect name requests for the `libssl` and
`libcrypto` libraries to a uniquely named LibreSSL build of libraries,
allowing libressl + openssl to co-exist on disk.
The default value for this option is:
`none`
`-Dwith-libressl-suffix=$suffix`
This option is only used when `-Dwith-libressl-mode=shim`, and sets the
suffix for the libraries that LSI will attempt to use when transforming
requests for LibreSSL libraries.
This will transform `libssl.so.$VERSION` to `libssl-$suffix.so`, i.e.
`libssl.so.37` would become `libssl-libressl.so`. This allows distros
to provide up to date `libressl` and `openssl` builds in parallel to
improve the security of games relying on LibreSSL.
The default value for this option is:
`-libressl`
## How LSI Works
LSI provides a /usr/bin/steam binary to be used in place of the existing Steam script, which will then correctly set up the environment before swapping the process for the Steam process.
When using a full build of LSI, the bootstrap shim will force a correct environment, removing any issues that can cause various older SDL versions to kill Steam. Additionally it will then
force `STEAM_RUNTIME=0` if this is set in the config (default behaviour).
When using the native runtime, and the `intercept` library is enabled, the LSI shim will also set up `LD_AUDIT` to use `liblsi-intercept.so`. This library will intercept all dynamic linking operations
for the main Steam binaries and override their behaviour, allowing Steam to only load a handful of vendored libraries (`libav` fork) as well as its own private libraries. It is then forced to use
system libraries for everything else. This means the Steam client, web helper, etc, will use the native SDL, X11, fixing many bugs with video playback, font rendering and such.
As of the `0.6` release of LSI, we now also support a `redirect` module. When enabled, the LSI shim will set `LD_PRELOAD` to use `liblsi-redirect.so`, which will conditionally enable it's own
internal logic based on the game being played. This module currently overrides the `open()` and `fopen64()` system calls to apply dynamic bug fixes to games, and may be expanded in future to
provide more fixes.
Currently the `redirect` module supports:
- ARK: Survival Evolved* (Use fixed shader asset from `TheCenter` DLC to fix invalid water appearance)
- Project Highrise* (Fix crash where the game attempts to use a directory as a config file `prefs.txt`)
If you are packaging LSI for a distribution, please ensure you provide both a 32-bit and 64-bit build of the intercept library so that the entirety of Steam's library (`.so`) mechanism is tightly
controlled by LSI. See the scripts in the root directory of this repository for examples of how to do this.
Configuration options can be placed in an INI-style configuration file in a series of locations, which are ordered by priority in a cascade:
~/.config/linux-steam-integration.conf
/etc/linux-steam-integration.conf
/usr/share/defaults/linux-steam-integration/linux-steam-integration.conf
The user configuration takes immediate priority. Secondly we have the system-wide configuration for affecting all accounts, and lastly the vendor configuration, which may be provided by the integrator.
Currently this INI file supports three options. The root section in this INI file must be `[Steam]`.
`use-native-runtime = $boolean`
If set to a true boolean value, (yes/true/on), the host OS's native runtime
will be used instead of the Steam provided runtime. If this is set to
a false boolean value (no/false/off), then the startup will be modified
to export the relevant `LD_PRELOAD` and `STEAM_RUNTIME` settings.
The default value of this variable is `true`.
`force-32bit = $boolean`
If set to a true boolean value (yes/true/on), the shadowed Steam binary will
be run via the `setarch linux32` command. This will force the `steam` process
and all children to believe they are running on a 32-bit system. This
may be useful for 64-bit games that are buggy only on 64-bit.
If this is set to a false boolean value (no/false/off), then the
shadowed Steam binary will be directly executed. Note that on 32-bit
OSs this setting is ignored.
The default value of this variable is `false`.
`use-libintercept = $boolean`
If set to a true boolean value (yes/true/on), the `liblsi-intercept.so`
library will be utilised to control dynamic linking within the Steam client
and associated processes.
Note this requires `use-native-runtime` to be set.
The default value of this variable is `true`.
`use-libredirect = $boolean`
If set to a true boolean value (yes/true/on), the `liblsi-redirect.so`
library will be utilised to apply "hot" workarounds to certain games to
fix various runtime issues.
Note this requires `use-native-runtime` to be set.
The default value of this variable is `true`.
`use-unity-hack = $boolean`
If set to a true boolean value (yes/true/on), the `liblsi-redirect.so`
library will apply a preference workaround to Unity3D based games and
abstract access to their configuration files. This is used to force
Unity3D games to always start in windowed mode, and to ensure that
they're unable to make use of the stored fullscreen setting.
## Common issues
Virtually all issues will come down to having the right dependencies. LSI puts an emphasis on
host-first libraries, so make sure all the correct libraries are available for both 32-bit and
64-bit.
Steam has both 32-bit and 64-bit processes/libraries, having the full dependency set for both
the client and common games/engines is a must.
### Steam fails to launch with libintercept/native-runtime
Make sure you enable full debugging when first assigning dependencies to your runtime package:
```bash
$ LSI_DEBUG=1 steam
# If you use co-exist option:
$ LSI_DEBUG=1 lsi-steam
```
### liblsi-intercept regressing performance
There exists a bug in `glibc` which incorrectly configures profiling for all PLT calls when using `LD_AUDIT` (rtld-audit)
even if the audit library doesn't implement `la_pltenter` or `la_pltexit`. This leads to a performance hit on every
runtime call via PLT.
The issue was first reported to this project by @amonakov [here](https://github.com/solus-project/linux-steam-integration/issues/15).
The upstream glibc issue is reported on the upstream glibc [bugzilla](https://sourceware.org/bugzilla/show_bug.cgi?id=15533).
A patch to resolve the issue was submitted by @amonakov [here](https://sourceware.org/ml/libc-alpha/2013-05/msg00888.html).
If you are noticing performance regressions, you can:
- As a user: Disable `liblsi-intercept` via `lsi-settings`. This will hurt compatibility.
- As a packager: Disable `liblsi-intercept` via build flags. This will hurt compatibility.
- As a distribution integrator: Add weight to upstream issue and import patch into your distribution.
This will retain LSI compatibility magic and mitigate performance issues.
As an example, Solus has already [integrated the patch](https://dev.getsol.us/R927:afa5b639e8a9b62618457a304d1e6fb42a9f2066).
`* Some names may be claimed as the property of others.`
+19
View File
@@ -0,0 +1,19 @@
Initial test list for next release of LSI
- DOTA 2
- Don't Starve Together
- Requires curl-gnutls (integrating into CLR now)
- Vendored SDL is patched in non upstreamable fashion
https://forums.kleientertainment.com/forums/topic/30218-crash-on-linux-steam-without-error/?page=0&tab=comments#comment-386249
We'll need to allow certain games to vendor SDL now.
Fixed in https://github.com/clearlinux/linux-steam-integration/commit/c4ded161159d2d6faa5a1dba45af8426738632b7
- Oxygen Not Included (working perfectly)
- Cities:Skylines
- Various Source titles (L4D2, Portal, etc)
- Various Feral titles (2018/2019 kits)
- Stardew Valley
- Rocket League
+1 release:
- Proton compat
-20
View File
@@ -1,20 +0,0 @@
LSI is still in its infancy, currently only at a 0.1 release. The time to
release was dramatic due to an absolute requirement for non-broken Steam
to accompany the Solus 1.2 release
Going forward, there are more items that need implementing to start shaving
more rough edges off of Linux gaming.
Immediate LSI worklist:
- [x] Add configurable shim to replace /usr/bin/steam, relying on shadowed launcher
- [x] Add super-basic UI to configure said shim
- [x] Shove out a 0.1 for Solus 1.2
- [ ] Replace existing /usr/bin/steam entirely and decouple the tight runtime logic
that is currently enforced.
- [ ] Remove requirement for steam.sh $bindir/steam entirely - allowing parallel clients.
LSI becomes more self contained and no longer needs to prop up Steam, but replaces
much of the support tools.
- [ ] Replace the existing Steam "run.sh" style launch facilities
- [ ] Get to a point that current ubuntu12_32 runtime is no longer required or
wanted.
-14
View File
@@ -1,14 +0,0 @@
#!/bin/sh
set -e
autoreconf --force --install --symlink --warnings=all
args="\
--sysconfdir=/etc \
--localstatedir=/var \
--prefix=/usr \
--enable-silent-rules"
./configure CFLAGS="-g -O1 $CFLAGS" $args "$@"
make clean
-103
View File
@@ -1,103 +0,0 @@
AC_INIT([linux-steam-integration], 0.2, [ikey@solus-project.com], [linux-steam-integration], [https://github.com/solus-project/linux-steam-integration/issues])
AC_CONFIG_AUX_DIR([build-aux])
AM_INIT_AUTOMAKE([-Wno-portability no-dist-gzip dist-xz foreign subdir-objects])
AC_PROG_CC
AC_PROG_CXX
AC_PROG_CC_STDC
LT_PREREQ(2.2)
AC_CONFIG_HEADERS([config.h])
AC_PREFIX_DEFAULT(/usr/local)
AM_SILENT_RULES([yes])
LT_INIT([disable-static])
AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_FILES([Makefile])
# Check if we're using the new C++ ABI, which will require LD_PRELOAD magic
AC_LANG_PUSH([C++])
AC_MSG_CHECKING(['_GLIBCXX_USE_CXX11_ABI' value])
AC_COMPUTE_INT([LSI_NEW_CXX_ABI], [_GLIBCXX_USE_CXX11_ABI], [[#include <string>]], [LSI_NEW_CXX_ABI=0])
AC_MSG_RESULT([$LSI_NEW_CXX_ABI])
AC_LANG_POP([C++])
if test x$LSI_NEW_CXX_ABI = "x1"; then
use_new_abi="yes"
AC_DEFINE([LSI_USE_NEW_ABI], [1], [Using new C++ ABI])
else
use_new_abi="no"
fi
# Source: https://mail.gnome.org/archives/commits-list/2012-September/msg01730.html
# adl_RECURSIVE_EVAL(VALUE, RESULT)
# =================================
# Interpolate the VALUE in loop until it doesn't change,
# and set the result to $RESULT.
# WARNING: It's easy to get an infinite loop with some unsane input.
# For example ${datadir} becomes ${datarootdir}, and then ${prefix}/share, and
# finally ${prefix} is replaced by the prefix.
AC_DEFUN([adl_RECURSIVE_EVAL],
[_lcl_receval="$1"
$2=`(test "x$prefix" = xNONE && prefix="$ac_default_prefix"
test "x$exec_prefix" = xNONE && exec_prefix="${prefix}"
_lcl_receval_old=''
while test "[$]_lcl_receval_old" != "[$]_lcl_receval"; do
_lcl_receval_old="[$]_lcl_receval"
eval _lcl_receval="\"[$]_lcl_receval\""
done
echo "[$]_lcl_receval")`])
# Shadow location of real Steam
AC_ARG_WITH([real-steam-binary], AS_HELP_STRING([--with-real-steam-binary],
[the real Steam binary to use]), [steambin=${withval}],
[steambin="$libdir/steam/steam"])
adl_RECURSIVE_EVAL(["$steambin"], [STEAMBIN])
AC_SUBST(STEAMBIN)
AC_DEFINE_UNQUOTED(STEAM_BINARY, "$STEAMBIN",
[The location of the real Steam binary])
# The LD_PRELOAD list required to integrate gracefully with the official Steam Runtime
AC_ARG_WITH([preload-libs], AS_HELP_STRING([--with-preload-libs],
[the preload libs to use with Steams own runtime]), [preloadlibs="${withval}"],
[preloadlibs="/usr/\$LIB/libX11.so.6:/usr/\$LIB/libstdc++.so.6"])
AC_DEFINE_UNQUOTED([LSI_PRELOAD_LIBS], "$preloadlibs",
[Libraries to preload with Steams runtime])
m4_define([gtk_required_version], [3.4.0])
# Check if frontend is requested
have_frontend="no"
AC_ARG_ENABLE(frontend, AS_HELP_STRING([--enable-frontend], [enable GTK frontend]))
if test "x$enable_frontend" = "xyes" ; then
PKG_CHECK_MODULES([GTK], [gtk+-3.0 >= gtk_required_version])
AC_DEFINE([HAVE_FRONTEND], [1], [Enabled GTK+ frontend])
have_frontend="yes"
fi
AM_CONDITIONAL([HAVE_FRONTEND], [test x$have_frontend = "xyes"])
AC_OUTPUT
AC_MSG_RESULT([
linux-steam-integration $VERSION
========
prefix: ${prefix}
libdir: ${libdir}
sysconfdir: ${sysconfdir}
exec_prefix: ${exec_prefix}
bindir: ${bindir}
datarootdir: ${datarootdir}
New C++ ABI: ${use_new_abi}
Real Steam binary: ${STEAMBIN}
GTK+ Frontend: ${have_frontend}
preload-libs: ${preloadlibs}
compiler: ${CC}
cflags: ${CFLAGS}
ldflags: ${LDFLAGS}
])
@@ -1,7 +1,7 @@
[Desktop Entry]
Name=Linux Steam Integration
Comment=Application for managing Steam integration settings
Exec=lsi-settings
Exec=@LSI_SETTINGS@
Icon=steam
Terminal=false
Type=Application
+108
View File
@@ -0,0 +1,108 @@
[Desktop Entry]
Name=LSI Steam
Comment=Launch Steam via LSI
Exec=/usr/bin/lsi-steam %U
Icon=steam
Terminal=false
Type=Application
Categories=Network;FileTransfer;Game;
MimeType=x-scheme-handler/steam;
Actions=Store;Community;Library;Servers;Screenshots;News;Settings;BigPicture;Friends;
StartupWMClass=Steam
[Desktop Action Store]
Name=Store
Name[de]=Shop
Name[es]=Tienda
Name[fr]=Magasin
Name[it]=Negozio
Name[pt]=Loja
Name[ru]=Магазин
Name[zh_CN]=商店
Name[zh_TW]=商店
Exec=lsi-steam steam://store
[Desktop Action Community]
Name=Community
Name[es]=Comunidad
Name[fr]=Communauté
Name[it]=Comunità
Name[pt]=Comunidade
Name[ru]=Сообщество
Name[zh_CN]=社区
Name[zh_TW]=社群
Exec=lsi-steam steam://url/SteamIDControlPage
[Desktop Action Library]
Name=Library
Name[de]=Bibliothek
Name[es]=Biblioteca
Name[fr]=Bibliothèque
Name[it]=Libreria
Name[pt]=Biblioteca
Name[ru]=Библиотека
Name[zh_CN]=
Name[zh_TW]=遊戲庫
Exec=lsi-steam steam://open/games
[Desktop Action Servers]
Name=Servers
Name[de]=Server
Name[es]=Servidores
Name[fr]=Serveurs
Name[it]=Server
Name[pt]=Servidores
Name[ru]=Серверы
Name[zh_CN]=服务器
Name[zh_TW]=伺服器
Exec=lsi-steam steam://open/servers
[Desktop Action Screenshots]
Name=Screenshots
Name[es]=Capturas
Name[fr]=Captures d'écran
Name[it]=Screenshot
Name[ru]=Скриншоты
Name[zh_CN]=截图
Name[zh_TW]=螢幕擷圖
Exec=lsi-steam steam://open/screenshots
[Desktop Action News]
Name=News
Name[de]=Neuigkeiten
Name[es]=Noticias
Name[fr]=Actualités
Name[it]=Notizie
Name[pt]=Notícias
Name[ru]=Новости
Name[zh_CN]=新闻
Name[zh_TW]=新聞
Exec=lsi-steam steam://open/news
[Desktop Action Settings]
Name=Settings
Name[de]=Einstellungen
Name[es]=Parámetros
Name[fr]=Paramètres
Name[it]=Impostazioni
Name[pt]=Configurações
Name[ru]=Настройки
Name[zh_CN]=设置
Name[zh_TW]=設定
Exec=lsi-steam steam://open/settings
[Desktop Action BigPicture]
Name=Big Picture
Exec=lsi-steam steam://open/bigpicture
[Desktop Action Friends]
Name=Friends
Name[de]=Freunde
Name[es]=Amigos
Name[fr]=Amis
Name[it]=Amici
Name[pt]=Amigos
Name[ru]=Друзья
Name[zh_CN]=好友
Name[zh_TW]=好友
Exec=lsi-steam steam://open/friends
+25
View File
@@ -0,0 +1,25 @@
path_appsdir = join_paths(path_datadir, 'applications')
# If frontend is enabled, install lsi-settings.desktop
if with_frontend == true
data_conf = configuration_data()
if with_snap_support == true
data_conf.set('LSI_SETTINGS', 'linux-steam-integration.exec linux-steam-integration.settings')
else
data_conf.set('LSI_SETTINGS', 'lsi-settings')
endif
configure_file(
input: 'lsi-settings.desktop.in',
output: 'lsi-settings.desktop',
configuration: data_conf,
install_dir: path_appsdir,
)
endif
# If we need to co-exist, install alternative .desktop file (not conflicting with Steam)
if shim_behaviour == 'co-exist'
install_data(
'lsi-steam.desktop',
install_dir: path_appsdir,
)
endif
-1
View File
@@ -1 +0,0 @@
+172
View File
@@ -0,0 +1,172 @@
project(
'linux-steam-integration',
['c'],
version: '0.7.3',
license: [
'LGPL-2.1',
],
default_options: [
'c_std=c11',
],
)
am_cflags = [
'-fstack-protector',
'-pedantic',
'-Wstrict-prototypes',
'-Wundef',
'-fno-common',
'-Werror-implicit-function-declaration',
'-Wformat',
'-Wformat-security',
'-Werror=format-security',
'-Wno-conversion',
'-Wunused-variable',
'-Wunreachable-code',
'-Wall',
'-W',
'-D_FORTIFY_SOURCE=2',
]
add_global_arguments(am_cflags, language: 'c')
dep_gtk3 = dependency('gtk+-3.0', version: '>= 3.4.0')
# Grab all our main paths
path_prefix = get_option('prefix')
path_bindir = join_paths(path_prefix, get_option('bindir'))
path_datadir = join_paths(path_prefix, get_option('datadir'))
path_vendordir = join_paths(path_datadir, 'defaults', meson.project_name())
path_sysconfdir = join_paths(path_prefix, get_option('sysconfdir'))
path_localedir = join_paths(path_prefix, get_option('localedir'))
# Set up our basic configuration
cdata = configuration_data()
cdata.set_quoted('PACKAGE_NAME', meson.project_name())
cdata.set_quoted('SYSTEMCONFDIR', path_sysconfdir)
cdata.set_quoted('VENDORDIR', path_vendordir)
cdata.set_quoted('LOCALEDIR', path_localedir)
cdata.set_quoted('GETTEXT_PACKAGE', meson.project_name())
# Configurables
with_preload_libs = get_option('with-preload-libs')
cdata.set_quoted('LSI_PRELOAD_LIBS', with_preload_libs)
cdata.set_quoted('STEAM_BINARY', get_option('with-steam-binary'))
# Future reports
shim_system_report = []
intercept_module_report = []
redirect_module_report = []
# Control the shim behaviour
shim_behaviour = get_option('with-shim')
shim_enabled = false
if shim_behaviour == 'replacement'
cdata.set('REPLACE_STEAM', '1')
endif
if shim_behaviour != 'none'
shim_enabled = true
endif
shim_system_report += ' behaviour: @0@'.format(shim_behaviour)
shim_system_report += ' preload libraries: @0@'.format(with_preload_libs)
# Do we have liblsi-intercept?
with_libintercept = get_option('with-libintercept')
if with_libintercept == true
cdata.set('HAVE_LIBINTERCEPT', '1')
endif
# Do we have liblsi-redirect?
with_libredirect = get_option('with-libredirect')
if with_libredirect == true
cdata.set('HAVE_LIBREDIRECT', '1')
endif
# Do we have the frontend?
with_frontend = get_option('with-frontend')
# Using the new libc++ ABI? Important for mesa drivers
with_new_libcxx_abi = get_option('with-new-libcxx-abi')
if with_new_libcxx_abi == true
cdata.set('LSI_USE_NEW_ABI', '1')
endif
shim_system_report += ' New C++ ABI: @0@'.format(with_new_libcxx_abi)
# How are we handling LibreSSL?
with_libressl_mode = get_option('with-libressl-mode')
intercept_module_report += ' LibreSSL handling: @0@'.format(with_libressl_mode)
if with_libressl_mode == 'native'
# LibreSSL is provided by the distro as the native libssl, libcrypto, etc
cdata.set('LSI_LIBRESSL_MODE_NATIVE', '1')
cdata.set('LSI_OVERRIDE_LIBRESSL', '1')
elif with_libressl_mode == 'shim'
# A shim package has been provided for soname redirects to updated/secure libressl
# This allows distros to secure libressl without making it the system libssl/libcrypto option
cdata.set('LSI_LIBRESSL_MODE_SHIM', '1')
cdata.set('LSI_OVERRIDE_LIBRESSL', '1')
with_libressl_suffix = get_option('with-libressl-suffix')
intercept_module_report += ' LibreSSL library suffix: @0@'.format(with_libressl_suffix)
cdata.set_quoted('LSI_LIBRESSL_SUFFIX', with_libressl_suffix)
else
message('LibreSSL mode isn\'t configured which may impact security')
endif
# Got snap support?
with_snap_support = get_option('with-snap-support')
if with_snap_support == true
cdata.set('HAVE_SNAPD_SUPPORT', '1')
path_fake_scripts_dir = join_paths(path_datadir, meson.project_name(), 'scripts')
cdata.set_quoted('FAKE_SCRIPTS_DIR', path_fake_scripts_dir)
subdir('snapd')
message('Enabling snapd support. Do NOT do this for distribution builds!')
endif
# Let's write the global config.h now
config_h = configure_file(
configuration: cdata,
output: 'config.h',
)
# Make it discoverable
config_h_dir = include_directories('.')
# Descend into source trees
subdir('data')
subdir('src')
subdir('po')
report = [
' Build configuration:',
' ====================',
'',
' prefix: @0@'.format(path_prefix),
' datadir: @0@'.format(path_datadir),
' sysconfdir: @0@'.format(path_sysconfdir),
' bindir: @0@'.format(path_bindir),
'',
' Shim System (Execution/Environment Control):',
' ============================================',
'',
' enabled: @0@'.format(shim_enabled),
'@0@'.format('\n'.join(shim_system_report)),
'',
' Intercept Module (Dynamic Linker Control):',
' ==========================================',
'',
' enabled: @0@'.format(with_libintercept),
'@0@'.format('\n'.join(intercept_module_report)),
'',
' Redirect Module (Standard Library Control):',
' ===========================================',
'',
' enabled: @0@'.format(with_libredirect),
'',
' Snap Support (run as a snap):',
' =============================',
'',
' enabled: @0@'.format(with_snap_support),
'@0@'.format('\n'.join(redirect_module_report)),
]
# Output some stuff to validate the build config
message('\n\n\n' + '\n'.join(report) + '\n\n')
+16
View File
@@ -0,0 +1,16 @@
option('with-shim', type : 'combo', choices : ['replacement', 'co-exist', 'none'], value: 'replacement',
description : 'control how the shim is deployed')
option('with-steam-binary', type: 'string', description: 'Set the path to the Steam binary', value: '/usr/lib/steam/steam')
option('with-frontend', type: 'boolean', description: 'Build the LSI Settings UI', value: false)
option('with-preload-libs', type: 'string', description: 'Colon separated list of libraries required to launch Steam games',
value: '/usr/$LIB/libxcb.so.1:/usr/$LIB/libX11.so.6:/usr/$LIB/libstdc++.so.6')
option('with-libintercept', type: 'boolean', description: 'Enable libintercept library for controlling Steam linking', value: true)
option('with-libredirect', type: 'boolean', description: 'Enable libredirect library for fine-tuning Steam games', value: true)
option('with-new-libcxx-abi', type: 'boolean', description: 'Enable when using the new libstdc++ ABI', value: false)
option('with-libressl-mode', type: 'combo', choices: ['native', 'shim', 'none'], value: 'none',
description: 'Control how LibreSSL replacements are performed')
option('with-libressl-suffix', type: 'string', value: '-libressl',
description: 'Suffix for shim LibreSSL library when using --with-libressl-mode=shim')
option('with-snap-support', type: 'boolean', description: 'Build LSI with explicit support for snapd', value: false)
Executable
+35
View File
@@ -0,0 +1,35 @@
#!/bin/bash
set -e
DEFAULT_ARGS="-Dwith-libressl-mode=shim -Dwith-new-libcxx-abi=true"
if [[ ! -d buildroot/build32 ]]; then
ASFLAGS="$ASFLAGS --32" CFLAGS="$CFLAGS -m32" CXXFLAGS="$CXXFLAGS -m32" LDFLAGS="$LDFLAGS -m32" \
meson buildroot/build32 $DEFAULT_ARGS \
--prefix=/usr \
--sysconfdir=/etc \
--datadir=/usr/share \
--libdir=/usr/lib32 \
-Dwith-shim=none \
--buildtype debugoptimized
fi
if [[ ! -d buildroot/build64 ]]; then
meson buildroot/build64 $DEFAULT_ARGS \
--prefix=/usr \
--sysconfdir=/etc \
--datadir=/usr/share \
--libdir=/usr/lib64 \
-Dwith-shim=replacement \
-Dwith-steam-binary=/usr/lib64/steam/steam \
-Dwith-frontend=true \
--buildtype debugoptimized
fi
ninja -C buildroot/build32
ninja -C buildroot/build64
sudo ninja -C buildroot/build32 install
sudo ninja -C buildroot/build64 install
Executable
+14
View File
@@ -0,0 +1,14 @@
#!/bin/bash
set -e
git submodule init
git submodule update
# Script for ikey because he went with meson. *shrug*
VERSION="0.7.3"
NAME="linux-steam-integration"
git-archive-all.sh --format tar --prefix ${NAME}-${VERSION}/ --verbose -t HEAD ${NAME}-${VERSION}.tar
xz -9 "${NAME}-${VERSION}.tar"
gpg --armor --detach-sign "${NAME}-${VERSION}.tar.xz"
gpg --verify "${NAME}-${VERSION}.tar.xz.asc"
+38
View File
@@ -0,0 +1,38 @@
ar
ca_ES
ca
cs
da_DK
da
de_CH
de
en_GB
eo
es_419
es_AR
es_ES
es_MX
es_PE
es
fi
fr_FR
he
hu
id_ID
it_IT
ko_KR
ko
lt
nb_NO
ne_NP
nl_BE
nl_NL
pl_PL
pl
pt_BR
pt_PT
ro_RO
ru
sv_SE
tr
zh_CN
+1
View File
@@ -0,0 +1 @@
src/frontend/main-window.c
+81
View File
@@ -0,0 +1,81 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Ahmed Lemine <aljakany@gmail.com>, 2017\n"
"Language-Team: Arabic (https://www.transifex.com/solus-project/teams/68407/ar/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: ar\n"
"Plural-Forms: nplurals=6; plural=n==0 ? 0 : n==1 ? 1 : n==2 ? 2 : n%100>=3 && n%100<=10 ? 3 : n%100>=11 && n%100<=99 ? 4 : 5;\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "دمج ستيم® ولينكس"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"التحكم في سلوك عميل ستيم والألعاب. لن تكون الإعدادات سارية المفعول ما لم يتم"
" إعادة تشغيل عميل ستيم. استخدم خيار \"الخروج من ستيم\" للتأكد من إغلاقه."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "استخدم زمن تشغيل أصيل"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "بدّل بين زمن التشغيل الأصيل وزمن التشغيل المرفق مع ستيم."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "تم تعطيل هذا الخيار لأن النظام أساساً ذو معمارية 32 بت"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr "قد يصلح هذا بعض الألعاب المعطلة، لكن سيعطل متصفح متجر ستيم."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "افرض وضع 32 بت لستيم"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "استخدم مكتبة الاعتراض"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"أجبر تطبيقات ستيم على استخدام مزيد من المكتبات الأصيلة لزيادة التوافق إلى "
"أقصى درجة."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "استخدم مكتبة إعادة التوجيه"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr "تجاوز استدعاءات النظام لإصلاح مشكلات معروفة في بعض نسخ لينكس."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "فشل في حفظ الإعدادات"
+98
View File
@@ -0,0 +1,98 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-12-19 12:48+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Davidmp <medipas@gmail.com>, 2017\n"
"Language-Team: Catalan (https://www.transifex.com/solus-project/teams/68407/ca/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: ca\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:132 src/frontend/main-window.c:149
msgid "Linux Steam® Integration"
msgstr "Integració de Linux Steam®"
#: src/frontend/main-window.c:163
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Controleu el comportament del client i dels jocs d'Steam. La configuració no"
" tindrà efecte fins que no es reiniciï el client d'Steam. Useu l'opció "
"\"Surt de l'Steam\" per assegurar-vos que es tanqui."
#: src/frontend/main-window.c:192
msgid "Use native runtime"
msgstr "Usa l'entorn d'execució natiu"
#: src/frontend/main-window.c:193
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Canvieu entre l'entorn natiu i l'entorn d'Steam agrupat."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:202
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Aquesta opció s'ha inhabilitat ja que el sistema ja és de 32 bits."
#: src/frontend/main-window.c:206
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Això pot solucionar alguns jocs trencats, però inhabilitarà el navegador de "
"la botiga d'Steam."
#: src/frontend/main-window.c:211
msgid "Force 32-bit mode for Steam"
msgstr "Força el mode de 32 bits per a l'Steam"
#: src/frontend/main-window.c:219
msgid "Use the intercept library"
msgstr "Usa la biblioteca d'intercepció"
#: src/frontend/main-window.c:220
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Força que les aplicacions de l'Steam usin més biblioteques natives per "
"maximitzar la compatibilitat."
#: src/frontend/main-window.c:229
msgid "Use the redirect library"
msgstr "Usa la biblioteca de redirecció"
#: src/frontend/main-window.c:230
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Anul·la les crides de sistema per corregir errors coneguts en algunes "
"versions de Linux."
#: src/frontend/main-window.c:237
msgid "Use the Unity fullscreen workaround"
msgstr "Usa la solució provisional de pantalla completa de l'Unity."
#: src/frontend/main-window.c:238
msgid ""
"Prevent some Unity games from launching in full screen mode to fix numerous "
"issues"
msgstr ""
"Evita que alguns jocs d'Unity s'obrin en pantalla completa per tal de "
"corregir uns quants problemes."
#: src/frontend/main-window.c:403
msgid "Failed to save configuration"
msgstr "Ha fallat desar la configuració"
+86
View File
@@ -0,0 +1,86 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Davidmp <medipas@gmail.com>, 2017\n"
"Language-Team: Catalan (Spain) (https://www.transifex.com/solus-project/teams/68407/ca_ES/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: ca_ES\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Integració de Linux Steam®"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Controleu el comportament del client i dels jocs d'Steam. La configuració no"
" tindrà efecte fins que no es reiniciï el client d'Steam. Useu l'opció "
"\"Surt de l'Steam\" per assegurar-vos que es tanqui."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Usa l'entorn d'execució natiu"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Canvieu entre l'entorn natiu i l'entorn d'Steam agrupat."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Aquesta opció s'ha inhabilitat ja que el sistema ja és de 32 bits."
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Això pot solucionar alguns jocs trencats, però inhabilitarà el navegador de "
"la botiga d'Steam."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Força el mode de 32 bits per a l'Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Usa la biblioteca d'intercepció"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Força que les aplicacions de l'Steam usin més biblioteques natives per "
"maximitzar la compatibilitat."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Usa la biblioteca de redirecció"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Anul·la les crides de sistema per corregir errors coneguts en algunes "
"versions de Linux."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Ha fallat desar la configuració"
+85
View File
@@ -0,0 +1,85 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Ondřej Pucholt <o.pucholt@windowslive.com>, 2017\n"
"Language-Team: Czech (https://www.transifex.com/solus-project/teams/68407/cs/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: cs\n"
"Plural-Forms: nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Integrace služby Steam®"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Ovládá chování her a klienta služby Steam. Změny nastavení se projeví až po "
"restartování služby. Pro její zaručené ukončení zvolte možnost \"Ukončit "
"službu Steam\"."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Používat nativní běhové prostředí"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Přepíná mezi nativním a přibaleným běhovým prostředím služby Steam."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Tato volba není dostupná, protože systém už je 32bitový"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Umožňuje obejít některé problémy se hrami, ale deaktivuje prohlížeč obchodu "
"služby Steam."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Přinutit službu Steam používat 32bitový režim"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Používat knihovnu pro zachytávání"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Přinutí programy ze služby Steam používat více nativních knihoven pro "
"zajištění maximální kompatibility."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Používat knihovnu pro přesměrování"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Přepsáním systémových volání opraví známé chyby v linuxových portech her."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Uložení konfigurace selhalo"
+85
View File
@@ -0,0 +1,85 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: scootergrisen <scootergrisen@gmail.com>, 2017\n"
"Language-Team: Danish (https://www.transifex.com/solus-project/teams/68407/da/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: da\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Integration med Linux Steam®"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Styr opførslen af Steam-klienten og spil. Indstillingerne vil ikke træde i "
"kraft før Steam-klienten er blevet genstartet. Brug 'Afslut Steam' for af "
"sikre at programmet lukkes."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Brug nativ runtime"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Skift mellem nativ runtime og den runtime som følger med Steam."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr ""
"Denne mulighed er blevet deaktiveret eftersom systemet allerede er 32-bit"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Det løser muligvis problemer for nogle ødelagte spil, til gengæld "
"deaktiveres Steam butik-browseren."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Tving 32-bit-tilstand for Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Brug intercept-biblioteket"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Tving Steam-programmer til at bruge flere native biblioteker for at "
"maksimere kompatibilitet."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Brug redirect-biblioteket"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr "Tilsidesæt systemkald for at rette kendte fejl i nogle Linux-porte."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Kunne ikke gemme konfiguration"
+85
View File
@@ -0,0 +1,85 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Yavuznie <y.z@live.dk>, 2017\n"
"Language-Team: Danish (Denmark) (https://www.transifex.com/solus-project/teams/68407/da_DK/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: da_DK\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Integration med Linux Steam®"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Styr opførslen af Steam-klienten og spil. Indstillingerne vil ikke træde i "
"kraft før Steam-klienten er blevet genstartet. Brug 'Afslut Steam' for af "
"sikre at programmet lukkes."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Brug nativ runtime"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Skift mellem nativ runtime og den runtime som følger med Steam."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr ""
"Denne mulighed er blevet deaktiveret eftersom systemet allerede er 32-bit"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Det løser muligvis problemer for nogle ødelagte spil, til gengæld "
"deaktiveres Steam butik-browseren."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Tving 32-bit-tilstand for Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Brug intercept-biblioteket"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Tving Steam-programmer til at bruge flere native biblioteker for at "
"maksimere kompatibilitet."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Brug redirect-biblioteket"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr "Tilsidesæt systemkald for at rette kendte fejl i nogle Linux-porte."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Kunne ikke gemme konfiguration"
+90
View File
@@ -0,0 +1,90 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Thomas Staudinger <staudi.kaos@gmail.com>, 2017\n"
"Language-Team: German (https://www.transifex.com/solus-project/teams/68407/de/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: de\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Linux Steam® Integration"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Kontrolliere das Verhalten des Steam-Clients und von Spielen. Die "
"Einstellungen werden erst aktiv, nachdem der Steam-Client neu gestartet "
"wurde. Nutze \"Steam beenden\", um sicherzugehen, dass es beendet wird."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Nutze native Laufzeitumgebung"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr ""
"Wechsle zwischen der nativen Laufzeitumgebung und der Steam-"
"Laufzeitumgebung."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr ""
"Diese Option ist deaktiviert, da es sich bereits um ein 32-Bit-System "
"handelt."
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Diese Option behebt möglicherweise Probleme mit Steam-Spielen, wird aber den"
" Steam Store Browser deaktivieren."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Erzwinge 32-Bit-Modus für Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Nutze die Intercept-Bibliothek"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Zwinge Steam-Anwendungen dazu, mehr native Bibliotheken zu nutzen, um die "
"Kompatibilität zu maximieren."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Nutze die Redirect-Bibliothek"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Überschreibe Systemaufrufe, um bekannte Bugs in manchen Linux-Ports zu "
"beheben."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Konfiguration konnte nicht gespeichert werden"
+89
View File
@@ -0,0 +1,89 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: f vg <f_vongellhorn@outlook.de>, 2017\n"
"Language-Team: German (Switzerland) (https://www.transifex.com/solus-project/teams/68407/de_CH/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: de_CH\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Linux Steam® Integration "
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Kontrolliere das Verhalten des Steam-Clients und der Spiele. Die "
"Einstellungen werden erst wirksam, wenn der Steam Client neu gestartet wird."
" Verwenden Sie die Option \"Steam beenden\", um sicherzustellen, dass Steam "
"geschlossen wird."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Verwende Systemeigene Laufzeitumgebung "
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr ""
"Wechseln zwischen Systemeigene und der gebündelten Steam Laufzeitumgebung"
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr ""
"Diese Option wurde deaktiviert, da das System bereits auf 32-Bit läuft."
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Dies könnte einige Probleme von fehlerhafte Spiele umgehen, wird jedoch den "
"Steam Store Browser deaktivieren. "
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Erzwinge den 32-Bit-Modus für Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Verwende die intercept-Bibliothek "
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Zwingen Sie die Steam-Anwendungen dazu mehr Systemeigene Bibliotheken zu "
"verwenden, um die Kompatibilität zu maximieren."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Verwende die Redirect-Bibliothek "
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Überschreiben Sie Systemaufrufe, um bekannte Fehler in einigen Linux-Ports "
"zu beheben."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Konfiguration konnte nicht gespeichert werden"
+95
View File
@@ -0,0 +1,95 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-12-19 12:48+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: \n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:132 src/frontend/main-window.c:149
msgid "Linux Steam® Integration"
msgstr "Linux Steam® Integration"
#: src/frontend/main-window.c:163
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
#: src/frontend/main-window.c:192
msgid "Use native runtime"
msgstr "Use native runtime"
#: src/frontend/main-window.c:193
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Switch between the native runtime and the bundled Steam runtime."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:202
msgid "This option has been disabled as the system is already 32-bit"
msgstr "This option has been disabled as the system is already 32-bit"
#: src/frontend/main-window.c:206
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
#: src/frontend/main-window.c:211
msgid "Force 32-bit mode for Steam"
msgstr "Force 32-bit mode for Steam"
#: src/frontend/main-window.c:219
msgid "Use the intercept library"
msgstr "Use the intercept library"
#: src/frontend/main-window.c:220
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
#: src/frontend/main-window.c:229
msgid "Use the redirect library"
msgstr "Use the redirect library"
#: src/frontend/main-window.c:230
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr "Override system calls to fix known bugs in some Linux ports."
#: src/frontend/main-window.c:237
msgid "Use the Unity fullscreen workaround"
msgstr "Use the Unity fullscreen workaround"
#: src/frontend/main-window.c:238
msgid ""
"Prevent some Unity games from launching in full screen mode to fix numerous "
"issues"
msgstr ""
"Prevent some Unity games from launching in full screen mode to fix numerous "
"issues"
#: src/frontend/main-window.c:403
msgid "Failed to save configuration"
msgstr "Failed to save configuration"
+86
View File
@@ -0,0 +1,86 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Pablo Chere <pablo.foche@gmail.com>, 2017\n"
"Language-Team: Esperanto (https://www.transifex.com/solus-project/teams/68407/eo/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: eo\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Steam® Linuksa Integriĝo"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Ĝi kontrolas la konduton de la Steam-kliento kaj la ludoj. Agordoj ne "
"efektiviĝos ĝis la restartigo de la Steam-kliento. Uzu la elekton \"Eliri el"
" Steam\" por certiĝi pri tio ke ĝi fermiĝas."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Uzi denaskan rultempon"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Ŝanĝi inter la denaska rultempo kaj la faskigita rultempo de Steam."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Ĉi tiu elekto estis malŝaltita kaj la sistemo estas ankoraŭ 32-bita."
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Ĉi tio povas funkciigi kelkajn rompitajn ludojn sed malŝaltos la navigilon "
"de la Steam-vendejo."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Devigi 32-bitan reĝimon por Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Uzi la interkaptan bibliotekon"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Devigi la aplikaĵojn de Steam uzi pliajn denaskajn bibliotekojn por "
"maksimumigi kongruecon"
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Uzi la alidirektan bibliotekon"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Transpasi sistemajn alvokojn por solvi konatajn erarojn en kelkaj linuksaj "
"portoj."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Agordo-konservado malsukcesis"
+86
View File
@@ -0,0 +1,86 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: mrkucho <vhugo642@gmail.com>, 2017\n"
"Language-Team: Spanish (https://www.transifex.com/solus-project/teams/68407/es/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: es\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Linux Steam® Integration"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Controla el comportamiento del cliente y los juegos de Steam. La "
"configuración no tendrá efecto hasta que el cliente de Steam se reinicie. "
"Use la opción 'Salir de Steam' para asegurarse de que se cierre."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Usar librerías nativas"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Cambie entre las librerías nativas y las incluidas por Steam"
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Esta opción ha sido desactivada ya que el sistema ya es de 32-bit"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Esto puede mejorar algunos juegos rotos, pero desactivará el navegador de la"
" tienda de Steam."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Forzar modo de 32-bit para Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Usar librería de intercepción"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Forzar a las aplicaciones de Steam a usar más librerías del sistema para "
"maximizar la compatibilidad."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Usar librería de redirección"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Anular las llamadas del sistema para solucionar algunos problemas conocidos "
"en adaptaciones de Linux."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Error al guardar la configuración"
+87
View File
@@ -0,0 +1,87 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: mrkucho <vhugo642@gmail.com>, 2017\n"
"Language-Team: Spanish (Latin America) (https://www.transifex.com/solus-project/teams/68407/es_419/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: es_419\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Linux Steam® Integration"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Controla el comportamiento del cliente y los juegos de Steam. La "
"configuración no tendrá efecto hasta que el cliente de Steam se reinicie. "
"Use la opción 'Salir de Steam' para asegurarse de que se cierre."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Usar librerías nativas"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr ""
"Cambie entre las librerías nativas del sistema y las incluidas por Steam"
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Esta opción ha sido desactivada ya que el sistema ya es de 32-bit"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Esto puede mejorar algunos juegos rotos, pero desactivará el navegador de la"
" tienda de Steam."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Forzar modo de 32-bit para Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Utilizar librería de intercepción"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Forzar a las aplicaciones de Steam a usar más librerías nativas para "
"maximizar la compatibilidad."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Utilizar la biblioteca de redirección"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Anular las llamadas del sistema para solucionar algunos problemas conocidos "
"en adaptaciones de Linux."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Error al guardar la configuración"
+86
View File
@@ -0,0 +1,86 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Abe Linux <m.delvalle01@gmail.com>, 2017\n"
"Language-Team: Spanish (Argentina) (https://www.transifex.com/solus-project/teams/68407/es_AR/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: es_AR\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Integración Steam® para Linux"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Controla el comportamiento del cliente y juegos de Steam. Las preferencias "
"no tomarán efecto hasta que el cliente de Steam sea reiniciado. Usa la "
"opción \"Salir de Steam\" para asegurarte de que se cierre."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Usar el entorno nativo"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Cambiar entre el entorno nativo y el incluido por Steam."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Esta opción ha sido deshabilitada dado que el sistema ya es de 32-bit"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Esto puede solucionar algunos juegos que no funcionen, pero deshabilitará la"
" tienda Steam."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Forzar modo 32-bit para Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Usar la librería intercept"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Forzar a las aplicaciones de Steam a utilizar más librerías nativas para "
"maximizar la compatibilidad."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Usar la librería intercept"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Sobrescribir llamadas de sistema para corregir problemas conocidos en "
"algunas adaptaciones de juegos para Linux."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Falló en guardar la configuración"
+86
View File
@@ -0,0 +1,86 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: mrkucho <vhugo642@gmail.com>, 2017\n"
"Language-Team: Spanish (Spain) (https://www.transifex.com/solus-project/teams/68407/es_ES/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: es_ES\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Linux Steam® Integration"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Controla el comportamiento del cliente y los juegos de Steam. La "
"configuración no tendrá efecto hasta que el cliente de Steam se reinicie. "
"Use la opción 'Salir de Steam' para asegurarse de que se cierre."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Usar librerías nativas"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Cambie entre las librerías nativas y las incluidas por Steam"
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Esta opción ha sido desactivada ya que el sistema ya es de 32-bit"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Esto puede mejorar algunos juegos rotos, pero desactivará el navegador de la"
" tienda de Steam."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Forzar modo de 32-bit para Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Usar librería de intercepción"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Forzar a las aplicaciones de Steam a usar más librerías del sistema para "
"maximizar la compatibilidad."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Usar librería de redirección"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Anular las llamadas del sistema para solucionar algunos problemas conocidos "
"en adaptaciones de Linux."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Error al guardar la configuración"
+89
View File
@@ -0,0 +1,89 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Fernando Macias <FernandoMaciasR@yahoo.com.mx>, 2017\n"
"Language-Team: Spanish (Mexico) (https://www.transifex.com/solus-project/teams/68407/es_MX/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: es_MX\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Integración de Steam® con Linux"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Controla el comportamiento del cliente y los juegos de Steam. Los ajustes no"
" tendrán efecto hasta que el cliente de Steam sea reiniciado. Use la opción "
"de 'Salir de Steam' para asegurarse de que sea cerrado."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Usar tiempo de ejecución nativo"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr ""
"Cambia entre el tiempo de ejecución nativo y el tiempo de ejecución incluido"
" en Steam."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr ""
"Esta opción ha sido deshabilitada debido a que el sistema ya es de 32 bits"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Esto puede solucionar algunos juegos que no funcionen, pero desactivará el "
"navegador de la tienda de Steam."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Forzar modo de 32 bits para Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Usar la librería de intercepción"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Forzar a las aplicaciones de Steam a que utilizen más librerias nativas para"
" maximizar la compatibilidad."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Usar la librería de redirección"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Anular las llamadas del sistema para corregir errores conocidos en algunos "
"puertos Linux."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "No se pudo guardar la configuración"
+87
View File
@@ -0,0 +1,87 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: mrkucho <vhugo642@gmail.com>, 2017\n"
"Language-Team: Spanish (Peru) (https://www.transifex.com/solus-project/teams/68407/es_PE/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: es_PE\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Linux Steam® Integration"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Controla el comportamiento del cliente y los juegos de Steam. La "
"configuración no tendrá efecto hasta que el cliente de Steam se reinicie. "
"Use la opción 'Salir de Steam' para asegurarse de que se cierre."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Usar librerías nativas"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr ""
"Cambie entre las librerías nativas del sistema y las incluidas por Steam"
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Esta opción ha sido desactivada ya que el sistema ya es de 32-bit"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Esto puede mejorar algunos juegos rotos, pero desactivará el navegador de la"
" tienda de Steam."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Forzar modo de 32-bit para Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Usar librería de intercepción"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Forzar a las aplicaciones de Steam a usar más librerías del sistema para "
"maximizar la compatibilidad."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Usar librería de redirección"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Anular las llamadas del sistema para solucionar algunos problemas conocidos "
"en adaptaciones de Linux."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Error al guardar la configuración"
+88
View File
@@ -0,0 +1,88 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Kim Kröger <kroger.kim@gmail.com>, 2017\n"
"Language-Team: Finnish (https://www.transifex.com/solus-project/teams/68407/fi/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: fi\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Linux Steam® Integraatio"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Ohjaa Steam-sovelluksen ja -pelien toimintaa. Asetukset tulevat voimaan "
"vasta Steam-sovelluksen uudelleenkäynnistyksen myötä. Käytä \"Sulje Steam\" "
"-toimintoa varmistaaksesi sen sulkeutumisen."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Käytä paikallista ohjelmakirjastoa"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr ""
"Vaihda paikallisen ohjelmakirjaston ja Steamin mukana tulevan "
"ohjelmakirjaston välillä."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Tämä asetus ei ole käytössä, koska järjestelmä on jo 32-bittinen"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Tämä voi väliaikaisesti korjata joidenkin pelien yhteensopivuusongelmat, "
"mutta ottaa myös Steamin Kaupan pois käytöstä."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Pakota 32-bittinen tila Steamille"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Käytä intercept-kirjastoa"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Pakottaa Steamin sovellusten käyttämään enemmän paikallisia "
"ohjelmakirjastoja yhteensopivuuden maksimoimiseksi."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Käytä redirect-kirjastoa"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Ohittaa järjestelmän kutsut tunnettujen ongelmien korjaamiseksi joissakin "
"peleissä."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Asetusten tallentaminen epäonnistui"
+88
View File
@@ -0,0 +1,88 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Serge <vanmechelen.serge@gmail.com>, 2017\n"
"Language-Team: French (France) (https://www.transifex.com/solus-project/teams/68407/fr_FR/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: fr_FR\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Intégration Steam® Linux"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Contrôle le comportement du client et des jeux Steam. Les paramètres ne "
"prendront effet qu'après le redémarrage du client Steam. Utilisez l'option "
"'Quitter Steam' pour vous assurer que l'application a bien été arrêtée."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Utiliser l'environnement d'exécution natif"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr ""
"Basculer entre l'environnement d'exécution natif et l'environnement "
"d'exécution Steam."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Cette option a été désactivée car le système est déjà en 32-bit"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Ceci permet d'éviter des problèmes rencontrés avec certains jeux mais "
"désactive le magasin Steam."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Forcer le mode 32-bit pour Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Utiliser la bibliothèque d'interception"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Obliger les applications Steam à utiliser davantage de bibliothèques natives"
" pour maximiser la compatibilité."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Utiliser la bibliothèque de redirection"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Remplacer les appels système pour corriger les bogues connus pour certains "
"ports sous Linux."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Echec dans la sauvegarde de la configuration"
+81
View File
@@ -0,0 +1,81 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Moshe Sh <7moshe7@gmail.com>, 2017\n"
"Language-Team: Hebrew (https://www.transifex.com/solus-project/teams/68407/he/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: he\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "שילוב לינוקס וסטים "
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"שליטה על ההתנהגות של Steam Client ומשחקים. ההגדרות לא יכנסו לתוקף עד להפעלה "
"מחדש של Steam Client. מומלץ להשתמש באופציה 'יציאה מסטים' על מנת לוודא שנסגר."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "שימוש בהרצה מקומית"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "החלפה בין הרצה מקומית להרצה של סטים."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "אפשרות זו הושבתה מאחר שהמערכת כבר 32 סיביות"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"פעולה זו עשויה לעקוף בעיה של כמה משחקים לא תקינים, אבל ישבית את הדפדפן של "
"חנות סטים."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "הכרח מצב 32 סיביות עבור סטים"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "שימוש בספריית intercept"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr "הכרח יישומי סטים להשתמש בספריות מקומיות כדי להגדיל את התאימות."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "שימוש בספריית redirect"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr "מעקף לקריאות המערכת כדי לתקן באגים ידועים בכמה יציאות לינוקס."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "שמירת ההגדרות נכשלה"
+87
View File
@@ -0,0 +1,87 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Kevin Németh <keiro@vivaldi.net>, 2017\n"
"Language-Team: Hungarian (https://www.transifex.com/solus-project/teams/68407/hu/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: hu\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Linux Steam® Integration"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Szabályozza a Steam-kliens működését és a játékokat. A beállításoknak nem "
"lesz hatásuk a Steam-kliens újraindításáig. Használja a 'Kilépés a Steamből'"
" opciót, hogy biztosan bezáródjon."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Natív futtatási környezet használata"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr ""
"Váltás a natív futtási környezet és a csomagolt Steam futtatási környezet "
"között."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Ez az opció le van tiltva, ha a rendszer már 32 bites."
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Ez megoldja néhány játék problémáját, de le fogja tiltani a Steam Áruház "
"keresőjét."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "32 bites mód kényszerítése a Steamnek"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Az elfogó könyvtár használata"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Steam alkalmazások kényszerítése a natív könyvtársak használatára a "
"kompatibilitás maximalizálására."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Az átirányítási könyvtár használata"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Rendszerhívások felüllbírálása ismert bugok javítására néhány Linux porton."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "A konfiguráció mentése sikertelen"
+86
View File
@@ -0,0 +1,86 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Yurizal Susanto <rizal.sagi@gmail.com>, 2017\n"
"Language-Team: Indonesian (Indonesia) (https://www.transifex.com/solus-project/teams/68407/id_ID/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: id_ID\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Integrasi Steam® Linux"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Atur sifat klien Steam dan permainan. Pengaturan tidak akan berlaku sebelum "
"klien Steam dimulai ulang. Gunakan pilihan 'Exit Steam' untuk memastikan "
"klien tertutup."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Gunakan runtime bawaan"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Tukar antara runtime bawaan dan runtime yang dibundel Steam"
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Pilihan ini dimatikan karena sistem sudah 32-bit"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Ini bisa menyelesaikan masalah pada beberapa permainan, tapi akan "
"menonaktifkan penjelajahan toko Steam."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Paksa mode 32-bit untuk Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Gunakan pustaka pencegat"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Paksa aplikasi Steam untuk menggunakan lebih banyak pustaka bawaan untuk "
"memaksimalkan kompabilitas."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Gunakan pustaka pengalihan"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Timpa panggilan sistem untuk memperbaiki bug yang diketahui di beberapa port"
" Linux."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Gagal menyimpan konfigurasi"
+98
View File
@@ -0,0 +1,98 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-12-19 12:48+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Fabio <fabio0x@keemail.me>, 2017\n"
"Language-Team: Italian (Italy) (https://www.transifex.com/solus-project/teams/68407/it_IT/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: it_IT\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:132 src/frontend/main-window.c:149
msgid "Linux Steam® Integration"
msgstr "Linux Steam® Integration"
#: src/frontend/main-window.c:163
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Controlla il comportamento dei giochi e del client Steam. Le impostazioni "
"non avranno effetto finché il client Steam non sarà riavviato. Usa l'opzione"
" \"Esci da Steam\" per assicurarti che venga davvero chiuso."
#: src/frontend/main-window.c:192
msgid "Use native runtime"
msgstr "Use ambiente di runtime nativo"
#: src/frontend/main-window.c:193
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Scegli tra l'ambiente di runtime nativo e quello integrato in Steam."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:202
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Questa opzione è disabilitata perché il sistema è già a 32-bit"
#: src/frontend/main-window.c:206
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Può correggere alcuni giochi non funzionanti, ma disabiliterà la navigazione"
" nel negozio Steam."
#: src/frontend/main-window.c:211
msgid "Force 32-bit mode for Steam"
msgstr "Forza Steam a 32-bit"
#: src/frontend/main-window.c:219
msgid "Use the intercept library"
msgstr "Usa la libreria di intercettazione"
#: src/frontend/main-window.c:220
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Forza le applicazioni di Steam a usare ancor più librerie native per "
"massimizzare la compatibilità."
#: src/frontend/main-window.c:229
msgid "Use the redirect library"
msgstr "Usa la libreria di redirezione"
#: src/frontend/main-window.c:230
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Sostituisce le chiamate di sistema per correggere i bug noti di alcuni "
"porting su Linux."
#: src/frontend/main-window.c:237
msgid "Use the Unity fullscreen workaround"
msgstr "Aggira il problema di Unity a schermo intero"
#: src/frontend/main-window.c:238
msgid ""
"Prevent some Unity games from launching in full screen mode to fix numerous "
"issues"
msgstr ""
"Evita che alcuni giochi basati su Unity partano a schermo intero per "
"correggere svariate problematiche"
#: src/frontend/main-window.c:403
msgid "Failed to save configuration"
msgstr "Errore durante il salvataggio della configurazione"
+80
View File
@@ -0,0 +1,80 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: jemin_jeon <jemin.jeon@posteo.net>, 2017\n"
"Language-Team: Korean (https://www.transifex.com/solus-project/teams/68407/ko/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: ko\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "리눅스 스팀® 통합 설정"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"스팀 클라이언트와 게임의 작동방식을 설정합니다. 설정값은 스팀 클라이언트를 재시작하면 적용됩니다. \"스팀 종료하기\" 옵션을 이용해서 "
"스팀이 확실히 종료되게 해주세요."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "리눅스 자체 런타임 사용하기"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "리눅스 자체 런타임과 스팀 내장 런타임간 전환하기"
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "시스템이 이미 32비트 운영체제이므로 이 옵션은 비활성화 되었습니다."
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"이 옵션을 활성화하면 올바르게 실행되지 않는 특정 게임이 정상 작동 할 수도 있습니다. 그러나 스팀 상점은 이용이 불가능합니다."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "스팀이 32비트 모드에서 실행되도록 강제합니다."
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Intercept 라이브러리를 사용합니다."
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr "스팀이 더 많은 리눅스 자체 라이브러리를 사용하여 호환성을 최대화 할 수 있도록 강제합니다."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Redirect 라이브러리 사용하기"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr "시스템 콜을 오버라이드하여 리눅스로 이식된 프로그램에서 발생하는 알려진 특정 오류를 수정합니다."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "설정 저장에 실패했습니다."
+80
View File
@@ -0,0 +1,80 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: jemin_jeon <jemin.jeon@posteo.net>, 2017\n"
"Language-Team: Korean (Korea) (https://www.transifex.com/solus-project/teams/68407/ko_KR/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: ko_KR\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "리눅스 스팀® 통합 설정"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"스팀 클라이언트와 게임의 작동방식을 설정합니다. 설정값은 스팀 클라이언트를 재시작하면 적용됩니다. \"스팀 종료하기\" 옵션을 이용해서 "
"스팀이 확실히 종료되게 해주세요."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "리눅스 자체 런타임 사용하기"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "리눅스 자체 런타임과 스팀 내장 런타임간 전환하기"
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "시스템이 이미 32비트 운영체제이므로 이 옵션은 비활성화 되었습니다."
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"이 옵션을 활성화하면 올바르게 실행되지 않는 특정 게임이 정상 작동 할 수도 있습니다. 그러나 스팀 상점은 이용이 불가능합니다."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "스팀이 32비트 모드에서 실행되도록 강제합니다."
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Intercept 라이브러리를 사용합니다."
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr "스팀이 더 많은 리눅스 자체 라이브러리를 사용하여 호환성을 최대화 할 수 있도록 강제합니다."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Redirect 라이브러리 사용하기"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr "시스템 콜을 오버라이드하여 리눅스로 이식된 프로그램에서 발생하는 알려진 특정 오류를 수정합니다."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "설정 저장에 실패했습니다."
+86
View File
@@ -0,0 +1,86 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-12-19 12:48+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
"Language: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:132 src/frontend/main-window.c:149
msgid "Linux Steam® Integration"
msgstr ""
#: src/frontend/main-window.c:163
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
#: src/frontend/main-window.c:192
msgid "Use native runtime"
msgstr ""
#: src/frontend/main-window.c:193
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr ""
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:202
msgid "This option has been disabled as the system is already 32-bit"
msgstr ""
#: src/frontend/main-window.c:206
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
#: src/frontend/main-window.c:211
msgid "Force 32-bit mode for Steam"
msgstr ""
#: src/frontend/main-window.c:219
msgid "Use the intercept library"
msgstr ""
#: src/frontend/main-window.c:220
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
#: src/frontend/main-window.c:229
msgid "Use the redirect library"
msgstr ""
#: src/frontend/main-window.c:230
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
#: src/frontend/main-window.c:237
msgid "Use the Unity fullscreen workaround"
msgstr ""
#: src/frontend/main-window.c:238
msgid ""
"Prevent some Unity games from launching in full screen mode to fix numerous "
"issues"
msgstr ""
#: src/frontend/main-window.c:403
msgid "Failed to save configuration"
msgstr ""
+99
View File
@@ -0,0 +1,99 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-12-19 12:48+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Moo <moose@mail.ru>, 2017\n"
"Language-Team: Lithuanian (https://www.transifex.com/solus-project/teams/68407/lt/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: lt\n"
"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:132 src/frontend/main-window.c:149
msgid "Linux Steam® Integration"
msgstr "Linux Steam® integracija"
#: src/frontend/main-window.c:163
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Valdykite Steam kliento ir žaidimų elgseną. Nustatymai neįsigalios tol, kol "
"Steam klientas nebus paleistas iš naujo. Norėdami užtikrinti, kad programa "
"Steam baigtų darbą, naudokite parametrą \"Išeiti iš Steam\"."
#: src/frontend/main-window.c:192
msgid "Use native runtime"
msgstr "Naudoti savą vykdymo aplinką"
#: src/frontend/main-window.c:193
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr ""
"Perjungti tarp savos vykdymo aplinkos ir pridėtinės Steam vykdymo aplinkos."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:202
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Šis parametras buvo išjungtas, nes sistema jau ir yra 32-bitų"
#: src/frontend/main-window.c:206
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Tai galėti padėti apeiti kai kurių neveikiančių žaidimų problemas, tačiau "
"išjungs Steam parduotuvės naršyklę."
#: src/frontend/main-window.c:211
msgid "Force 32-bit mode for Steam"
msgstr "Programai Steam priverstinai naudoti 32-bitų veikseną"
#: src/frontend/main-window.c:219
msgid "Use the intercept library"
msgstr "Naudoti perėmimo biblioteką"
#: src/frontend/main-window.c:220
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Priversti Steam programas naudoti labiau savas bibliotekas, siekiant "
"padidinti suderinamumą."
#: src/frontend/main-window.c:229
msgid "Use the redirect library"
msgstr "Naudoti peradresavimo biblioteką"
#: src/frontend/main-window.c:230
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Nustelbti sistemines iškvietas, siekiant pataisyti žinomas klaidas kai "
"kuriuose Linux perkėlimuose."
#: src/frontend/main-window.c:237
msgid "Use the Unity fullscreen workaround"
msgstr "Naudoti Unity viso ekrano problemos apėjimą"
#: src/frontend/main-window.c:238
msgid ""
"Prevent some Unity games from launching in full screen mode to fix numerous "
"issues"
msgstr ""
"Neleisti kai kuriems Unity žaidimams pasileisti viso ekrano veiksenoje, "
"siekiant pataisyti daugelį klaidų"
#: src/frontend/main-window.c:403
msgid "Failed to save configuration"
msgstr "Nepavyko įrašyti konfigūracijos"
+3
View File
@@ -0,0 +1,3 @@
i18n = import('i18n')
i18n.gettext(meson.project_name(), preset: 'glib')
+86
View File
@@ -0,0 +1,86 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Lars-Eivind Bjørtvedt <larseivind.bjoertvedt@gmail.com>, 2017\n"
"Language-Team: Norwegian Bokmål (Norway) (https://www.transifex.com/solus-project/teams/68407/nb_NO/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: nb_NO\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Linux Steam® Integrasjon"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Endre oppførselen til Steam-klienten og spill. Innstillingene vil ikke tre i"
" kraft før Steam-klienten er restartet. Bruk 'Avslutt Steam '-valget for å "
"være sikker på at det lukkes helt."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Bruk lokal kjøreomgivelse"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Bytt mellom lokal kjøreomgivelse og Steams innebygde kjøreomgivelse."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Dette valget er deaktivert siden systemet allerede er 32-bits"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Dette kan få visse defekte spill til å fungere, men vil deaktivere "
"nettleseren i Steam-butikken."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Tving 32-bits modus for Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Bruk avskjæringsbiblioteket"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Tving Steam-applikasjoner til å bruke flere lokale kjøreomgivelser for å "
"maksimere kompatibiliteten."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Bruk videresendingsbiblioteket"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Overstyr systemkall for å fikse kjente feil i enkelte Linux-versjoner av "
"spill."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Kunne ikke lagre konfigurasjon"
+85
View File
@@ -0,0 +1,85 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Rabin Adhikari <rabin.adk1@gmail.com>, 2017\n"
"Language-Team: Nepali (Nepal) (https://www.transifex.com/solus-project/teams/68407/ne_NP/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: ne_NP\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "लिनक्स स्टिम® एकीकरण"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"स्टिम क्लाइन्ट र खेलहरूको व्यवहार नियन्त्रण गर्नुहोस्। स्टिम क्लाइन्ट पुन: "
"सुरु नभएसम्म सेटिङहरूमा प्रभाव पर्ने छैन। यो बन्द गर्न सुनिश्चित गर्नको लागि"
" 'बाहिर निस्कनुहोस्' विकल्प प्रयोग गर्नुहोस्।"
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "मूल रनटाइम प्रयोग गर्नुहोस्"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "मूल रनटाइम र बन्डल स्टिम रनटाइम बीच स्विच गर्नुहोस्।"
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "यो विकल्प असक्षम गरिएको छ किनभने प्रणाली पहिले नै 32-बिट छ"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"यसले केही बिच्छेद खेलहरूको गर्न वैकल्पिक समाधान गर्न सक्दछ, तर स्टिम भण्डार "
"ब्राउजर असक्षम पार्नेछ।"
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "स्टिमको लागि 32-बिट मोड बल गर्नुहोस्"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "इन्टरसेप्ट लाइब्रेरी प्रयोग गर्नुहोस्"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"अनुकूलता अधिकतम गर्नका लागी थप मूल पुस्तकालयहरू प्रयोग गर्न स्टिम "
"एप्लिकेसनहरूलाई बल गर्नुहोस्।"
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "पुन: निर्देशित पुस्तकालय प्रयोग गर्नुहोस्"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"केहि लिनक्स पोर्टहरूमा ज्ञात बगहरू ठीक गर्न प्रणाली कलहरू ओभरराइड गर्नुहोस्।"
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "कन्फिगरेसन सुरक्षित गर्न असफल भयो"
+86
View File
@@ -0,0 +1,86 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Geert Verheyde <geert.verheyde@gmail.com>, 2017\n"
"Language-Team: Dutch (Belgium) (https://www.transifex.com/solus-project/teams/68407/nl_BE/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: nl_BE\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Linux Steam® Integration"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Beheer het gedrag van de Steam Client en games. Wijzigingen zijn pas "
"effectief na het herstarten van de Steam Client. Gebruik de \"Exit Steam\" "
"optie om definitief af te sluiten."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Gebruik de systeemeigen runtime"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Wissel tussen de systeemeigen runtime en de gebundelde Steam runtime"
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Deze optie werd uitgezet omdat het systeem reeds 32-bit is"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Dit kan gebroken games doen werken, maar zal de Steam store browser "
"uitzetten."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Forceer 32-bit modus voor Steam."
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Gebruik de opvangende bibliotheek"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Forceer Steam toepassingen meer systeemeigen bibliotheken te gebruiken om de"
" compatibiliteit te maximaliseren"
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Gebruik de omleidende bibliotheek"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Negeer systeemoproepen om gekende fouten te herstellen in bepaalde Linux "
"ports"
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Het opslaan van de configuratie is mislukt."
+86
View File
@@ -0,0 +1,86 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Thimo dZ <tsdezwart@protonmail.com>, 2017\n"
"Language-Team: Dutch (Netherlands) (https://www.transifex.com/solus-project/teams/68407/nl_NL/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: nl_NL\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Linux Steam® Integration"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Beheer het gedrag van de Steam-client en spellen. De wijzigingen zijn pas "
"effectief na het herstarten van de Steam-client. Gebruik de \"Steam "
"afsluiten\"-optie om Steam definitief af te sluiten."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Gebruik de systeemeigen runtime"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Wissel tussen de systeemeigen runtime en de gebundelde Steam runtime"
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Deze optie is uitgeschakeld omdat het systeem reeds 32-bit is"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Dit kan niet werkende spellen doen werken, maar zal de Steam store browser "
"uitschakelen."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Forceer 32-bitsmodus voor Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Gebruik de opvangende bibliotheek"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Forceer Steam-toepassingen meer systeemeigen bibliotheken te gebruiken om de"
" compatibiliteit te maximaliseren."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Gebruik de omleidende bibliotheek"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Negeer systeemoproepen om bekende fouten te herstellen in bepaalde Linux-"
"ports"
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Het opslaan van de configuratie is mislukt"
+88
View File
@@ -0,0 +1,88 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Kacper Herchel <kacperski1@gmail.com>, 2017\n"
"Language-Team: Polish (https://www.transifex.com/solus-project/teams/68407/pl/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: pl\n"
"Plural-Forms: nplurals=4; plural=(n==1 ? 0 : (n%10>=2 && n%10<=4) && (n%100<12 || n%100>14) ? 1 : n!=1 && (n%10>=0 && n%10<=1) || (n%10>=5 && n%10<=9) || (n%100>=12 && n%100<=14) ? 2 : 3);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Integracja Linuksa ze Steam®"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Zarządzaj zachowaniem klienta Steam i gier. Ustawienia dadzą efekt dopiero "
"po zrestartowaniu klienta Steam. Użyj opcji „Zamknij Steam” aby upewnić się,"
" że klient został zamknięty."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Używaj natywnego środowiska"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr ""
"Przełączaj się między natywnym środowiskiem uruchomieniowym i wersją "
"dołączaną do klienta Steam."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Ta opcja została zablokowana, ponieważ używany system jest 32-bitowy"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"To może naprawić działanie niektórych gier, ale wyłączy możliwość "
"przeglądania sklepu Steam."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Wymuś tryb 32-bitowy dla Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Używaj biblioteki przechwytującej"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Wymusza na grach Steam używanie większej ilości natywnych bibliotek, co "
"zwiększa kompatybilność."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Używaj biblioteki przekierowującej"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Nadpisuje wywołania systemowe, aby poprawić błędy w niektórych linuksowych "
"portach."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Nie udało się zapisać konfiguracji"
+88
View File
@@ -0,0 +1,88 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Kacper Herchel <kacperski1@gmail.com>, 2017\n"
"Language-Team: Polish (Poland) (https://www.transifex.com/solus-project/teams/68407/pl_PL/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: pl_PL\n"
"Plural-Forms: nplurals=4; plural=(n==1 ? 0 : (n%10>=2 && n%10<=4) && (n%100<12 || n%100>14) ? 1 : n!=1 && (n%10>=0 && n%10<=1) || (n%10>=5 && n%10<=9) || (n%100>=12 && n%100<=14) ? 2 : 3);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Integracja Linuksa ze Steam®"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Zarządzaj zachowaniem klienta Steam i gier. Ustawienia dadzą efekt dopiero "
"po zrestartowaniu klienta Steam. Użyj opcji „Opuść Steam” aby upewnić się, "
"że klient został zamknięty."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Używaj natywnego środowiska"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr ""
"Przełączaj się między natywnym środowiskiem uruchomieniowym i wersją "
"dołączaną do klienta Steam."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Ta opcja została zablokowana, ponieważ używany system jest 32-bitowy"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"To może naprawić działanie niektórych gier, ale wyłączy możliwość "
"przeglądania sklepu Steam."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Wymuś tryb 32-bitowy dla Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Używaj biblioteki przechwytującej"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Wymusza na grach Steam używanie większej ilości natywnych bibliotek, co "
"zwiększa kompatybilność."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Używaj biblioteki przekierowującej"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Nadpisuje wywołania systemowe, aby poprawić błędy w niektórych linuksowych "
"portach."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Nie udało się zapisać konfiguracji"
+86
View File
@@ -0,0 +1,86 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Marcelo Ferreira <marceloffdeoliveira@gmail.com>, 2017\n"
"Language-Team: Portuguese (Brazil) (https://www.transifex.com/solus-project/teams/68407/pt_BR/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: pt_BR\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Integração Steam® com Linux"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Controla o comportamento dos jogos e do programa da Steam. As configurações "
"não terão efeito até que o programa seja reiniciado. Utilize a opção \"Sair "
"da Steam\" para garantir que ele seja fechado."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Usar runtime nativo"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Alternar entre o runtime nativo e o incluso da Steam."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Esta opção foi desativada, uma vez que o sistema já é de 32-bits"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Isto pode funcionar em alguns jogos defeituosos, mas irá desativar o "
"navegador da loja da Steam."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Forçar modo 32-bits para a Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Usar a biblioteca de interceptação"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Forçar aplicativos da Steam a usar mais bibliotecas nativas para maximizar a"
" compatibilidade."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Usar a biblioteca de redirecionamento"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Sobrescrever chamadas do sistema para corrigir bugs conhecidos em algumas "
"adaptações para Linux."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Falha ao salvar configuração"
+86
View File
@@ -0,0 +1,86 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Christophe Silva <christophesilva80@gmail.com>, 2017\n"
"Language-Team: Portuguese (Portugal) (https://www.transifex.com/solus-project/teams/68407/pt_PT/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: pt_PT\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Integração Linux Steam®"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Controla o comportamento do cliente e jogos em Steam. As configurações não "
"terão efeito antes de o Cliente de Steam ser reinicializado. Use a opção "
"\"Sair do Steam\" para ter a certeza que o cliente fecha."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Usar \"runtime\" nativo"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Alternar entre o \"runtime\" nativo e o \"runtime\" Steam incluído."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Esta opção foi desativada, já que o sistema já possui 32 bits"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Isto pode resolver alguns jogos danificados, mas irá desativar o navegador "
"da loja Steam."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Forçar o modo de 32 bits para Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Use a biblioteca de intercetação"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Força aplicativos do Steam para usar mais bibliotecas nativas para maximizar"
" a compatibilidade."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Use a biblioteca de redirecionamento"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Substitua as chamadas do sistema para corrigir erros conhecidos em algumas "
"portas Linux."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Falha ao salvar a configuração"
+86
View File
@@ -0,0 +1,86 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Andrei B <snoozeisdoze@gmail.com>, 2017\n"
"Language-Team: Romanian (Romania) (https://www.transifex.com/solus-project/teams/68407/ro_RO/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: ro_RO\n"
"Plural-Forms: nplurals=3; plural=(n==1?0:(((n%100>19)||((n%100==0)&&(n!=0)))?2:1));\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Integrare Steam® Linux"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Controleaza comportamentul jocurilor si al clientului Steam. Setarile nu vor"
" avea efect pana cand Clientul Steam nu este restartat. Utilizati optiunea "
"\"Exit Steam\" pentru a va asigura ca se inchide."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Utilizati runtime-ul nativ"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Comuta intre runtime-ul nativ si cel inclus in Steam"
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Aceasta optiune a fost dezactivata deoarece sistemul este deja 32-bit"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Aceasta poate fi o solutie pentru unele jocuri nefunctionale, dar va "
"dezactiva navigatorul magazinul Steam."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Forteaza modul 32-bit pentru Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Utilizati libraria de interceptare"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Fortati aplicatiile Steam sa foloseasca mai multe librarii native pentru a "
"maximiza compatibilitatea."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Utilizati libraria de redirectionare"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Suprascrie apelurile de sistem pentru a repara erori cunoscute in unele "
"portari Linux."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Nu s-a reusit salvarea configuratiei"
+88
View File
@@ -0,0 +1,88 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Alex Vorobyev <avorobyev@protonmail.com>, 2017\n"
"Language-Team: Russian (https://www.transifex.com/solus-project/teams/68407/ru/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: ru\n"
"Plural-Forms: nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Интеграция Steam в Linux"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Настройте поведение клиента Steam и игр. Настройки не возымеют эффекта, пока"
" клиент Steam не будет перезапущен. Выберите пункт \"Выход из Steam\", чтобы"
" закрыть клиент."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Использовать системные библиотеки"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr ""
"Переключение между системными библиотеками и библиотеками, поставляемыми с "
"клиентом Steam."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Эта настройка отключена, поскольку система является 32-битной"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Эта настройка может помочь с запуском некоторых \"сломанных\" игр, но при "
"этом магазин Steam будет недоступен."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Включить 32-битный режим в Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Использовать библиотеку intercept"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Приложения в Steam будут использовать системные библиотеки для лучшей "
"совместимости."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Использовать библиотеку redirect"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Перехват системных вызовов в некоторых Linux-портах для исправления "
"известных ошибок."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Не удалось сохранить конфигурацию"
+83
View File
@@ -0,0 +1,83 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Puppelimies <max.haureus@gmail.com>, 2017\n"
"Language-Team: Swedish (Sweden) (https://www.transifex.com/solus-project/teams/68407/sv_SE/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: sv_SE\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Linux Steam® Integration"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Styr beteendet av Steam klienten och spel. Inställningarna kommer inte att "
"träda i kraft förrän Steam klienten startas om. Använd 'Avsluta Steam' "
"alternativet för att se till att den stängs."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Använd inbyggd runtime"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "Växla mellan inbyggd runtime och inkluderad Steam runtime."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Detta alternativ är inaktiverat eftersom systemet redan är 32-bit"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Detta kan lösa endel trasiga spel, men inaktiverar Steam butik bläddraren."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Tvinga 32-bit läge för Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Använd avledningsbiblioteket"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Tvinga Steam applikationer att använda fler inbyggda bibliotek för att "
"maximera kompatibilitet."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Använd omdirigeringsbiblioteket"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr "Åsidosätt systemanrop för att åtgärda kända fel i vissa Linux-portar."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Spara konfiguration misslyckades"
+88
View File
@@ -0,0 +1,88 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Demiray Muhterem <mdemiray@msn.com>, 2017\n"
"Language-Team: Turkish (https://www.transifex.com/solus-project/teams/68407/tr/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: tr\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Linux Steam® Bütünleşmesi"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr ""
"Steam istemcisinin ve oyunların davranışını denetleyin. Ayarlar, Steam "
"İstemcisi yeniden başlatılıncaya kadar etkili olmaz. Kapanmasını sağlamak "
"için 'Exit Steam' seçeneğini kullanın."
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "Yerel çalışma zamanını kullan"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr ""
"Yerli çalışma zamanı ve birlikte verilen Steam çalışma zamanı arasında geçiş"
" yapın."
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "Sistem zaten 32-bit olduğu için bu seçenek devre dışı bırakılmıştır"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr ""
"Bu, bazı kırık oyunları geçici olarak çözebilir, ancak Steam deposu "
"tarayıcısını devre dışı bırakır."
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "Steam için 32 bitlik modu zorla"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "Kesme kitaplığını kullanın"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr ""
"Steam uygulamalarının uyumluluğu en üst düzeye çıkarmak için daha fazla "
"yerel kütüphane kullanmalarını zorunlu tutun."
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "Yönlendirme kütüphanesini kullanın"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr ""
"Bazı Linux bağlantı noktalarında bilinen hataları düzeltmek için sistem "
"çağrılarını geçersiz kılın."
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "Yapılandırma kaydedilemedi"
+9
View File
@@ -0,0 +1,9 @@
#!/bin/sh
tx pull -a --minimum-perc=100
cd po
rm LINGUAS
for i in *.po ; do
echo `echo $i|sed 's/.po$//'` >> LINGUAS
done
+77
View File
@@ -0,0 +1,77 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the linux-steam-integration package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: linux-steam-integration\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-05 19:28+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: plantman <weihanlin@live.com>, 2017\n"
"Language-Team: Chinese (China) (https://www.transifex.com/solus-project/teams/68407/zh_CN/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: zh_CN\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. Sort out window bits
#. header label
#: src/frontend/main-window.c:131 src/frontend/main-window.c:148
msgid "Linux Steam® Integration"
msgstr "Steam® 的 Linux 系统整合"
#: src/frontend/main-window.c:162
msgid ""
"Control the behaviour of the Steam client and games. Settings will not take "
"effect until the Steam Client is restarted. Use the 'Exit Steam' option to "
"ensure it closes."
msgstr "控制 Steam 客户端和游戏的运行方式。配置在重启后生效。使用“退出 Steam”选项来确保完全退出。"
#: src/frontend/main-window.c:191
msgid "Use native runtime"
msgstr "使用系统运行时"
#: src/frontend/main-window.c:192
msgid "Switch between the native runtime and the bundled Steam runtime."
msgstr "在系统运行时跟 Steam 自带运行时之间切换"
#. Label is shown to indicate we can't enable 32-bit option
#: src/frontend/main-window.c:201
msgid "This option has been disabled as the system is already 32-bit"
msgstr "此选项已禁用,因为系统已经是 32 位了"
#: src/frontend/main-window.c:205
msgid ""
"This may workaround some broken games, but will disable the Steam store "
"browser."
msgstr "这个解决方法可能会修复某些运行不正常的游戏,但是会禁用 Steam 商店浏览器"
#: src/frontend/main-window.c:210
msgid "Force 32-bit mode for Steam"
msgstr "强制以 32 位模式运行 Steam"
#: src/frontend/main-window.c:218
msgid "Use the intercept library"
msgstr "使用 “Intercept” 库"
#: src/frontend/main-window.c:219
msgid ""
"Force Steam applications to use more native libraries to maximise "
"compatibility."
msgstr "强制让 Steam 尽可能使用系统自带库,以确保最好的兼容性"
#: src/frontend/main-window.c:228
msgid "Use the redirect library"
msgstr "使用 \"Redirect\" 库"
#: src/frontend/main-window.c:229
msgid "Override system calls to fix known bugs in some Linux ports."
msgstr "覆盖系统调用以修复某些已知的游戏运行问题"
#: src/frontend/main-window.c:383
msgid "Failed to save configuration"
msgstr "无法保存配置"
+4
View File
@@ -0,0 +1,4 @@
install_data(
'pulseaudio',
install_dir: join_paths(path_fake_scripts_dir, 'pulseaudio'),
)
+12
View File
@@ -0,0 +1,12 @@
#!/bin/bash
# Work around games using libfmod which is determined to execute:
# pulseaudio --check > /dev/null 2>&1
if [[ ! -z "$1" ]]; then
if [[ "$1" == "--check" ]] ; then
exit 0
fi
fi
exec /usr/bin/pulseaudio $*
+35
View File
@@ -0,0 +1,35 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2016-2017 Ikey Doherty
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#pragma once
#define _GNU_SOURCE
/* Mark a variable/argument as unused to skip warnings */
#define __lsi_unused__ __attribute__((unused))
/* Force inlining of a function */
#define __lsi_inline__ __attribute__((always_inline))
#define ARRAY_SIZE(x) (sizeof(x) / sizeof(x[0]))
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+247
View File
@@ -0,0 +1,247 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2016-2018 Ikey Doherty <ikey@solus-project.com>
* Copyright © 2018-2019 Intel Corporation
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#define _GNU_SOURCE
#include <ctype.h>
#include <pwd.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/stat.h>
#include <unistd.h>
#include "common.h"
#include "files.h"
#include "log.h"
#include "nica/array.h"
#include "nica/util.h"
#include "vdf.h"
DEF_AUTOFREE(VdfFile, vdf_file_close)
bool lsi_file_exists(const char *path)
{
__lsi_unused__ struct stat st = { 0 };
return lstat(path, &st) == 0;
}
const char *lsi_get_home_dir()
{
char *c = NULL;
struct passwd *p = NULL;
c = getenv("HOME");
if (c) {
return c;
}
p = getpwuid(getuid());
if (!p) {
return NULL;
}
return p->pw_dir;
}
char *lsi_get_user_config_dir()
{
const char *home = NULL;
char *c = NULL;
char *xdg_config = getenv("XDG_CONFIG_HOME");
char *p = NULL;
/* Respect the XDG_CONFIG_HOME variable if it is set */
if (xdg_config) {
p = realpath(xdg_config, NULL);
if (p) {
return p;
}
return strdup(xdg_config);
}
home = lsi_get_home_dir();
if (asprintf(&c, "%s/.config", home) < 0) {
return NULL;
}
p = realpath(c, NULL);
if (p) {
free(c);
return p;
}
return c;
}
/**
* Just use .local/share/Steam at this point..
*/
static inline char *lsi_get_fallback_steam_dir(const char *home)
{
char *p = NULL;
char *xdg_data = getenv("XDG_DATA_HOME");
int r = 0;
/* Respect the XDG_CONFIG_HOME variable if it is set */
if (xdg_data) {
r = asprintf(&p, "%s/Steam", xdg_data);
} else {
r = asprintf(&p, "%s/.local/share/Steam", home);
}
if (r < 0) {
return NULL;
}
return p;
}
char *lsi_get_steam_dir()
{
const char *homedir = NULL;
autofree(char) *candidate = NULL;
autofree(char) *resolv = NULL;
homedir = lsi_get_home_dir();
if (asprintf(&candidate, "%s/.steam/root", homedir) < 0) {
return NULL;
}
resolv = realpath(candidate, NULL);
if (!resolv || !lsi_file_exists(resolv)) {
return lsi_get_fallback_steam_dir(homedir);
}
return strdup(resolv);
}
char *lsi_get_process_name(void)
{
char *realp = NULL;
realp = realpath("/proc/self/exe", NULL);
if (!realp) {
return NULL;
}
return realp;
}
char *lsi_get_process_base_name(void)
{
autofree(char) *p = NULL;
char *basep = NULL;
p = lsi_get_process_name();
if (!p) {
return NULL;
}
basep = basename(p);
return strdup(basep);
}
/**
* Quickly determine if a string is numeric..
*/
static inline bool lsi_is_string_numeric(char *p)
{
char *s;
for (s = p; *s; s++) {
if (!isdigit(*s)) {
return false;
}
}
/* Didn't wind, empty string */
if (s == p) {
return false;
}
return true;
}
char **lsi_get_steam_paths(void)
{
autofree(char) *steam_root = NULL;
autofree(char) *lib_conf = NULL;
autofree(VdfFile) *vdf = NULL;
VdfNode *root = NULL;
VdfNode *node = NULL;
NcArray *array = NULL;
steam_root = lsi_get_steam_dir();
if (!steam_root) {
return NULL;
}
array = nc_array_new();
if (!nc_array_add(array, strdup(steam_root))) {
goto bail;
}
if (asprintf(&lib_conf, "%s/steamapps/libraryfolders.vdf", steam_root) < 0) {
return NULL;
}
vdf = vdf_file_open(lib_conf);
if (!vdf) {
goto fallback;
}
if (!vdf_file_parse(vdf)) {
goto fallback;
}
/* Look up LibraryFolders under root */
root = vdf_file_get_root(vdf);
node = vdf_node_get(root, "LibraryFolders", NULL);
if (!node) {
goto fallback;
}
/* Walk all nodes immediately within LibraryFolders and ignore sections */
for (VdfNode *n = node->child; n; n = n->sibling) {
if (!n->value) {
continue;
}
if (lsi_is_string_numeric(n->key)) {
if (!nc_array_add(array, strdup(n->value))) {
goto bail;
}
lsi_log_debug("vdf: discovered LibraryFolders: %s", n->value);
}
}
fallback:
/* Trick nica into storing empty value to so we can terminate the array */
if (!nc_array_add(array, (void *)(long)1)) {
goto bail;
}
/* Steal the blob straight out of the array */
char **data = (char **)array->data;
data[array->len - 1] = NULL;
free(array);
return data;
bail:
nc_array_free(&array, free);
return NULL;
}
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+65
View File
@@ -0,0 +1,65 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2016-2017 Ikey Doherty <ikey@solus-project.com>
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#pragma once
#define _GNU_SOURCE
#include <stdbool.h>
#include <stdlib.h>
/**
* Determine the home directory
*/
const char *lsi_get_home_dir(void);
/**
* Determine the home config directory
*/
char *lsi_get_user_config_dir(void);
/**
* Find out where Steam is installed
*/
char *lsi_get_steam_dir(void);
/**
* Grab all the valid steam installation directories
*/
char **lsi_get_steam_paths(void);
/**
* Quick helper to determine if the path exists
*/
bool lsi_file_exists(const char *path);
/**
* Return the full process name
*/
char *lsi_get_process_name(void);
/**
* Determine the basename'd process
*/
char *lsi_get_process_base_name(void);
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+117
View File
@@ -0,0 +1,117 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2016-2018 Ikey Doherty <ikey@solus-project.com>
* Copyright © 2018-2019 Intel Corporation
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#define _GNU_SOURCE
#include <stdarg.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "log.h"
#include "nica/util.h"
static const char *_log_id = "__init__";
void lsi_log_set_id(const char *id)
{
_log_id = id;
}
void lsi_log_debug(const char *format, ...)
{
if (!getenv("LSI_DEBUG")) {
return;
}
autofree(char) *p = NULL;
va_list va;
va_start(va, format);
if (!vasprintf(&p, format, va)) {
/* At least print *something */
fprintf(stderr, "%s\n", format);
goto end;
}
fprintf(stderr, "\033[32;1m[lsi:%s]\033[0m %s\n", _log_id, p);
end:
va_end(va);
}
void lsi_log_info(const char *format, ...)
{
autofree(char) *p = NULL;
va_list va;
va_start(va, format);
if (!vasprintf(&p, format, va)) {
/* At least print *something */
fprintf(stderr, "%s\n", format);
goto end;
}
fprintf(stderr, "\033[34;1m[lsi:%s]\033[0m %s\n", _log_id, p);
end:
va_end(va);
}
void lsi_log_warn(const char *format, ...)
{
autofree(char) *p = NULL;
va_list va;
va_start(va, format);
if (!vasprintf(&p, format, va)) {
/* At least print *something */
fprintf(stderr, "%s\n", format);
goto end;
}
fprintf(stderr, "\033[33;1m[lsi:%s]\033[0m %s\n", _log_id, p);
end:
va_end(va);
}
void lsi_log_error(const char *format, ...)
{
autofree(char) *p = NULL;
va_list va;
va_start(va, format);
if (!vasprintf(&p, format, va)) {
/* At least print *something */
fprintf(stderr, "%s\n", format);
goto end;
}
fprintf(stderr, "\033[31;1m[lsi:%s]\033[0m %s\n", _log_id, p);
end:
va_end(va);
}
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+54
View File
@@ -0,0 +1,54 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2016-2017 Ikey Doherty <ikey@solus-project.com>
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#pragma once
#define _GNU_SOURCE
#include <stdlib.h>
/**
* Set the ID used in all log output
*/
void lsi_log_set_id(const char *id);
/**
* Emit some debug information if LSI_DEBUG is set
*/
void lsi_log_debug(const char *format, ...) __attribute__((format(printf, 1, 2)));
/**
* Emit information, always shown
*/
void lsi_log_info(const char *format, ...) __attribute__((format(printf, 1, 2)));
/**
* Emit a warning, always shown
*/
void lsi_log_warn(const char *format, ...) __attribute__((format(printf, 1, 2)));
/**
* Emit an error, always shown
*/
void lsi_log_error(const char *format, ...) __attribute__((format(printf, 1, 2)));
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+19
View File
@@ -0,0 +1,19 @@
# Build the common library to share functionality between various components
lsi_common_sources = [
'files.c',
'log.c',
'vdf.c',
]
lib_lsi_common = static_library(
'lsi-lsi-common',
sources: lsi_common_sources + nica_sources,
c_args: ['-fvisibility=hidden'],
include_directories: nica_includes,
)
link_lsi_common = declare_dependency(
link_with: lib_lsi_common,
include_directories: include_directories('.'),
)
+706
View File
@@ -0,0 +1,706 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2016-2018 Ikey Doherty <ikey@solus-project.com>
* Copyright © 2018-2019 Intel Corporation
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#define _GNU_SOURCE
#include <ctype.h>
#include <errno.h>
#include <fcntl.h>
#include <stdarg.h>
#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/mman.h>
#include <sys/stat.h>
#include <unistd.h>
#include "log.h"
#include "vdf.h"
#define VDF_CHAR_QUOTE '"'
#define VDF_CHAR_SLASH '\\'
#define VDF_CHAR_OPEN '{'
#define VDF_CHAR_CLOSE '}'
typedef enum {
VDF_FLAG_MIN = 1 << 0,
VDF_FLAG_QUOTED = 1 << 1, /**< Inside a quoted block */
VDF_FLAG_COMMENT = 1 << 2, /**< Inside a comment block */
VDF_FLAG_BLOCK_COMMENT = 1 << 3, /**< Inside a multiline comment block */
VDF_FLAG_CHEW_WHITESPACE = 1 << 4,
} VdfFlags;
/**
* VdfFile is the main dude required for parsing a file
*/
struct VdfFile {
/* Input */
size_t buffer_len;
char *buffer;
/* Output (memstream) */
FILE *ring;
char *out_buffer;
size_t out_len;
/* Input file */
int fd;
/* Tracking */
size_t index;
int flags;
char *key_id;
int n_quote; /**only allow 2 sets per "line" */
VdfNode *section;
VdfNode *root;
bool error; /**< Allow breaking. */
};
/**
* Function pointer to the generic handler functions.
*/
typedef bool (*vdf_handle_func)(VdfFile *file, char c);
/**
* Free node
*/
static void vdf_node_free(VdfNode *node)
{
if (!node) {
return;
}
if (node->key) {
free(node->key);
}
if (node->value) {
free(node->value);
}
vdf_node_free(node->sibling);
vdf_node_free(node->child);
free(node);
}
/**
* Allocate a new VdfNode, copying the key and value if they exist.
*/
static VdfNode *vdf_node_new(const char *key, const char *value)
{
VdfNode *ret = NULL;
ret = calloc(1, sizeof(VdfNode));
if (!ret) {
return NULL;
}
if (key) {
ret->key = strdup(key);
if (!ret->key) {
goto failed;
}
}
if (value) {
ret->value = strdup(value);
if (!ret->value) {
goto failed;
}
}
return ret;
failed:
vdf_node_free(ret);
return NULL;
}
void vdf_file_close(VdfFile *file)
{
if (!file) {
return;
}
if (file->buffer) {
munmap(file->buffer, file->buffer_len);
}
if (file->fd > -1) {
close(file->fd);
}
if (file->ring) {
fclose(file->ring);
}
if (file->out_buffer) {
free(file->out_buffer);
}
if (file->key_id) {
free(file->key_id);
}
/* TODO: Make free separate from close, so we can just keep the node */
vdf_node_free(file->root);
free(file);
}
VdfFile *vdf_file_open(const char *path)
{
VdfFile *ret = NULL;
struct stat st = { 0 };
ret = calloc(1, sizeof(VdfFile));
if (!ret) {
return NULL;
}
ret->fd = -1;
ret->fd = open(path, O_RDONLY);
if (ret->fd < 0) {
goto fail;
}
if (fstat(ret->fd, &st) != 0) {
goto fail;
}
ret->buffer_len = (size_t)st.st_size;
ret->buffer = mmap(NULL, ret->buffer_len, PROT_READ, MAP_PRIVATE, ret->fd, 0);
if (!ret->buffer) {
goto fail;
}
/* Now we have input map, build output memstream */
ret->ring = open_memstream(&ret->out_buffer, &ret->out_len);
if (!ret->ring) {
goto fail;
}
return ret;
fail:
vdf_file_close(ret);
return NULL;
}
VdfNode *vdf_file_get_root(VdfFile *file)
{
if (!file) {
return NULL;
}
return file->root;
}
/**
* Advance the buffer pointer forward if possible.
*/
static char vdf_file_next(VdfFile *file)
{
file->index++;
if (file->index > file->buffer_len) {
file->index = file->buffer_len;
return '\0';
}
return file->buffer[file->index];
}
/**
* Attempt to peek at the next character in the buffer
*/
static char vdf_file_peek(VdfFile *file)
{
if (file->index + 1 > file->buffer_len) {
return '\0';
}
return file->buffer[file->index + 1];
}
/**
* Skip a character in the stream
*/
static void vdf_file_skip(VdfFile *file)
{
if (++file->index > file->buffer_len) {
file->index = file->buffer_len;
}
}
/**
* Push a char to the ring buffer
*/
static bool vdf_file_push_ring(VdfFile *file, char c)
{
if (fwrite(&c, 1, sizeof(c), file->ring) != 1) {
return false;
}
return true;
}
/**
* End the ring buffer by writing a NUL byte
*/
static bool vdf_file_end_ring(VdfFile *file)
{
if (!vdf_file_push_ring(file, '\0')) {
return false;
}
if (fflush(file->ring) != 0) {
return false;
}
return true;
}
/**
* Reset the ring once more to begin writing again.
*/
static bool vdf_file_reset_ring(VdfFile *file)
{
if (fflush(file->ring) != 0) {
return false;
}
if (fseek(file->ring, 0, SEEK_SET) != 0) {
return false;
}
return true;
}
/**
* Handle newlines
*
* When encountering a newline we need to do a bit of state cleanup
*/
static bool vdf_file_handle_newline(VdfFile *file, char c)
{
if (c != '\n') {
return false;
}
file->flags &= ~VDF_FLAG_COMMENT;
if (file->flags & VDF_FLAG_QUOTED) {
file->flags |= VDF_FLAG_CHEW_WHITESPACE;
} else {
file->flags &= ~VDF_FLAG_CHEW_WHITESPACE;
}
return false;
}
/**
* Handle quote characters
*
* This function deals with the start/end quotes encountered in the stream
* to set keys and values
*/
static bool vdf_file_handle_quote(VdfFile *file, char c)
{
if (c != VDF_CHAR_QUOTE) {
return false;
}
/* Start tracking quoting if necessary */
if (!(file->flags & VDF_FLAG_QUOTED)) {
/* Start tracking the quoted thing */
if (file->n_quote > 2) {
lsi_log_error("vdf: Cannot start a third section");
goto bail;
}
file->flags |= VDF_FLAG_QUOTED;
file->flags &= ~VDF_FLAG_CHEW_WHITESPACE;
vdf_file_reset_ring(file);
return true;
}
++file->n_quote;
/* Stop tracking the quoted thing */
file->flags ^= VDF_FLAG_QUOTED;
vdf_file_end_ring(file);
/* Capture the ID */
if (file->n_quote == 1) {
if (file->key_id) {
lsi_log_error("vdf: Key should not already be set!");
goto bail;
}
file->key_id = strdup(file->out_buffer);
return true;
}
if (!file->key_id) {
lsi_log_error("vdf: Missing key for value!");
goto bail;
}
if (file->n_quote != 2) {
lsi_log_error("vdf: Invalid number of quotes on line");
goto bail;
}
/* Reset n_quote now */
file->n_quote = 0;
/* Store the node now */
VdfNode *t = vdf_node_new(file->key_id, file->out_buffer);
if (!t) {
fputs("OOM\n", stderr);
goto bail;
}
/* dispose of key ID now */
free(file->key_id);
file->key_id = NULL;
file->flags &= ~VDF_FLAG_CHEW_WHITESPACE;
/* Store the new key->value mapping */
t->parent = file->section->parent;
t->sibling = file->section->child;
file->section->child = t;
return true;
bail:
file->error = true;
return true;
}
/**
* Handle opening of a section
*
* This will perform some basic validation, and when all conditions are satisfied
* we'll attempt construction of a new section
*/
static bool vdf_file_handle_section_open(VdfFile *file)
{
VdfNode *node = NULL;
vdf_file_reset_ring(file);
if (file->n_quote == 2) {
lsi_log_error("vdf: section cannot have value!");
goto bail;
}
if (file->n_quote != 1) {
lsi_log_error("vdf: Section is missing id!");
goto bail;
}
file->n_quote = 0;
if (!file->key_id) {
lsi_log_error("vdf: key_id should not be NULL!");
goto bail;
}
node = vdf_node_new(file->out_buffer, NULL);
if (!node) {
goto bail;
}
free(file->key_id);
file->key_id = NULL;
node->parent = file->section;
node->sibling = file->section->child;
file->section->child = node;
file->section = node;
return true;
bail:
file->error = true;
return true;
}
/**
* Handle closing of a section
*
* This will perform some basic error checking to ensure we're closing it
* correctly. At this point we'll wind back to the nodes parent
*/
static bool vdf_file_handle_section_close(VdfFile *file)
{
if (file->n_quote != 0) {
lsi_log_error("vdf: unterminated section!");
goto bail;
}
if (!file->section) {
lsi_log_error("vdf: Closed section without creating one!");
goto bail;
}
/* Wind back */
file->section = file->section->parent;
if (!file->section) {
goto bail;
}
return true;
bail:
file->error = true;
return true;
}
/**
* Handle brace characters
*
* This function will proxy to the relevant handler function
*/
static bool vdf_file_handle_section(VdfFile *file, char c)
{
switch (c) {
case VDF_CHAR_CLOSE:
return vdf_file_handle_section_close(file);
case VDF_CHAR_OPEN:
return vdf_file_handle_section_open(file);
default:
return false;
}
}
/**
* Handle normal text
*
* Whilst in QUOTED mode we'll keep pushing text to the buffer, which will
* later become keys and values.
*
* We'll also do some sanity checks here to escape any common text sequences,
* so as not to break the quotes
*/
static bool vdf_file_handle_text(VdfFile *file, char c)
{
char next = '\0';
/* Must be within quoting */
if (!(file->flags & VDF_FLAG_QUOTED)) {
return false;
}
if (file->flags & VDF_FLAG_CHEW_WHITESPACE && isspace(c)) {
return true;
}
file->flags &= ~VDF_FLAG_CHEW_WHITESPACE;
/* Check if we need to do any escaping */
if (c != VDF_CHAR_SLASH) {
vdf_file_push_ring(file, c);
return true;
}
/* Perform text escaping */
switch ((next = vdf_file_peek(file))) {
case 'r':
vdf_file_push_ring(file, '\r');
vdf_file_skip(file);
return true;
case 'n':
vdf_file_push_ring(file, '\n');
vdf_file_skip(file);
return true;
case 't':
vdf_file_push_ring(file, '\t');
vdf_file_skip(file);
return true;
case '"':
vdf_file_push_ring(file, '"');
vdf_file_skip(file);
return true;
case '\'':
vdf_file_push_ring(file, '\'');
vdf_file_skip(file);
return true;
case '\\':
vdf_file_push_ring(file, '\\');
vdf_file_skip(file);
return true;
default:
// TODO: Handle errors properly!
lsi_log_error("vdf: Invalid escape sequence '\\%c'", next);
file->error = true;
return true;
}
}
/**
* Handle multiline comments
*
* This method will attempt to look for the start and ends of multiline comment
* blocks, which will result in all text from the start until the trailing
* characters of the comment to be ignored.
*/
static bool vdf_file_handle_multiline_comment(VdfFile *file, char c)
{
if (c == '/' && vdf_file_peek(file) == '*') {
vdf_file_skip(file);
if (file->flags & VDF_FLAG_BLOCK_COMMENT) {
lsi_log_error("vdf: Starting nested block comment");
goto bail;
}
file->flags |= VDF_FLAG_BLOCK_COMMENT;
} else if (c == '*' && vdf_file_peek(file) == '/') {
vdf_file_skip(file);
if (!(file->flags & VDF_FLAG_BLOCK_COMMENT)) {
lsi_log_error("vdf: Ended comment without starting one");
goto bail;
}
file->flags ^= VDF_FLAG_BLOCK_COMMENT;
} else {
return false;
}
return true;
bail:
file->error = true;
return true;
}
/**
* Handle single comments
*
* This will handle C++ style '//' comments and cause the remaining text on
* the line to be ignored
*/
static bool vdf_file_handle_single_comment(VdfFile *file, char c)
{
/* Don't switch us on if we're inside a multiline comment! */
if (file->flags & VDF_FLAG_BLOCK_COMMENT) {
return false;
}
/* Must be a C++ style comment. */
if (!(c == '/' && vdf_file_peek(file) == '/')) {
return false;
}
/* Skip the next character, and turn on comment mode */
vdf_file_skip(file);
file->flags |= VDF_FLAG_COMMENT;
return true;
}
/**
* Handle comment state
*
* If we're in a comment we might need to skip this line entirely, however
* if its a multiline comment we need to preemptively evaluate the termination.
*/
static bool vdf_file_handle_commented(VdfFile *file, char c)
{
if (file->flags & VDF_FLAG_COMMENT) {
return true;
}
if (file->flags & VDF_FLAG_BLOCK_COMMENT) {
/* Always return true here, must ignore the line! */
vdf_file_handle_multiline_comment(file, c);
return true;
}
return false;
}
bool vdf_file_parse(VdfFile *file)
{
char c = file->buffer[0];
bool ret = false;
static vdf_handle_func funcs[] = {
&vdf_file_handle_newline,
&vdf_file_handle_commented,
&vdf_file_handle_quote,
&vdf_file_handle_text,
&vdf_file_handle_section,
&vdf_file_handle_single_comment,
&vdf_file_handle_multiline_comment,
};
static size_t n_funcs = sizeof(funcs) / sizeof(funcs[0]);
file->flags = 0;
file->key_id = NULL;
file->section = file->root = vdf_node_new(NULL, NULL);
if (!file->root) {
goto bail;
}
while (c != '\0') {
/* Pass through all of our functions */
for (size_t i = 0; i < n_funcs; i++) {
if (funcs[i](file, c)) {
goto next;
}
}
if (file->error) {
goto bail;
}
/* Now the only thing left is to allow whitespace */
if (!isspace(c)) {
lsi_log_error("vdf: Illegal character in stream: '%c'", c);
goto bail;
}
next:
c = vdf_file_next(file);
}
ret = true;
/* Check a comment actually ended .. */
if (file->flags & VDF_FLAG_BLOCK_COMMENT) {
lsi_log_error("vdf: Started block comment without ending one");
ret = false;
}
bail:
if (file->key_id) {
free(file->key_id);
file->key_id = NULL;
}
return ret;
}
VdfNode *vdf_node_get_child(VdfNode *node, const char *id)
{
if (!id || !node) {
return NULL;
}
for (VdfNode *tmp = node->child; tmp; tmp = tmp->sibling) {
if (tmp->key && strcmp(tmp->key, id) == 0) {
return tmp;
}
}
return NULL;
}
VdfNode *vdf_node_get(VdfNode *node, ...)
{
va_list va;
va_start(va, node);
char *id = NULL;
VdfNode *retr = node;
while ((id = va_arg(va, char *)) != NULL) {
retr = vdf_node_get_child(retr, id);
if (!retr) {
goto end;
}
}
end:
va_end(va);
return retr;
}
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+93
View File
@@ -0,0 +1,93 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2016-2017 Ikey Doherty <ikey@solus-project.com>
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*
*/
#pragma once
#include <stdbool.h>
#include <stdlib.h>
#define _GNU_SOURCE
/**
* VdfFile is an opaque type containing fields used primarily for parsing
* a .vdf file
*
* A VdfFile is used to parse the Valve Data Format file, allowing LSI to
* parse the users library paths, etc.
*/
typedef struct VdfFile VdfFile;
/**
* A VdfNode may be any element in a VDF document, and has optional value,
* children and parent.
* The root node in a document has no parent
*/
typedef struct VdfNode {
struct VdfNode *sibling; /**First sibling */
struct VdfNode *child; /**<First child, may have siblings. */
struct VdfNode *parent; /**<Parent if not the root */
char *key; /**<Only null for the root node */
char *value; /**<Only exists for key-value nodes */
} VdfNode;
/**
* Close and free an existing VdfFile
*/
void vdf_file_close(VdfFile *file);
/**
* Attempt to map the source path and open a .vdf file
*/
VdfFile *vdf_file_open(const char *path);
/**
* Return the root node for this file, if it has been parsed
*/
VdfNode *vdf_file_get_root(VdfFile *file);
/**
* Attempt to parse a file
*
* @file Pointer to a VdfFile instance
* @returns true if parsing succeeds
*/
bool vdf_file_parse(VdfFile *file);
/**
* Grab a child node by the given ID
*
* @node Parent node
* @id Child ID
*/
VdfNode *vdf_node_get_child(VdfNode *node, const char *id);
/**
* Variadic function to retrieve a child node
*
* This function will keep iterating the args passed until it hits NULL and
* has a node, or no node can be found prior to this and it returns NULL.
*/
__attribute__((sentinel(0))) VdfNode *vdf_node_get(VdfNode *node, ...);
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+421
View File
@@ -0,0 +1,421 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2016-2018 Ikey Doherty <ikey@solus-project.com>
* Copyright © 2018-2019 Intel Corporation
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#define _GNU_SOURCE
#include "main-window.h"
#include "config.h"
#include "lsi.h"
#include <errno.h>
#include <glib/gi18n.h>
#include <stdlib.h>
#include <string.h>
struct _LsiSettingsWindow {
GtkWindow parent;
LsiConfig config; /**<Current LSI config */
/* Only when libintercept is enabled will we have this option */
#ifdef HAVE_LIBINTERCEPT
GtkWidget *check_intercept;
#endif
/* Only when libredirect is enabled will we have this option */
#ifdef HAVE_LIBREDIRECT
GtkWidget *check_redirect;
GtkWidget *check_unity_hack;
#endif
/* Always have these guys */
GtkWidget *check_native;
GtkWidget *check_emul32;
};
struct _LsiSettingsWindowClass {
GtkWindowClass parent_class;
};
G_DEFINE_TYPE(LsiSettingsWindow, lsi_settings_window, GTK_TYPE_WINDOW)
static void _align_label(GtkWidget *label);
static void insert_grid(GtkWidget *grid, int *row, const char *title, const char *description,
GtkWidget *widget);
static GtkWidget *insert_grid_toggle(GtkWidget *grid, int *row, const char *title,
const char *description);
static void set_row_sensitive(GtkWidget *toggle, gboolean sensitive);
static void lsi_native_swapped(LsiSettingsWindow *window, gpointer v);
static gboolean lsi_window_closed(LsiSettingsWindow *window, GdkEvent *event, gpointer v);
/**
* lsi_settings_window_new:
*
* Construct a new LsiSettingsWindow object
*/
GtkWidget *lsi_settings_window_new()
{
return g_object_new(LSI_TYPE_SETTINGS_WINDOW, "type", GTK_WINDOW_TOPLEVEL, NULL);
}
/**
* lsi_settings_window_dispose:
*
* Clean up a LsiSettingsWindow instance
*/
static void lsi_settings_window_dispose(GObject *obj)
{
G_OBJECT_CLASS(lsi_settings_window_parent_class)->dispose(obj);
}
/**
* lsi_settings_window_class_init:
*
* Handle class initialisation
*/
static void lsi_settings_window_class_init(LsiSettingsWindowClass *klazz)
{
GObjectClass *obj_class = G_OBJECT_CLASS(klazz);
/* gobject vtable hookup */
obj_class->dispose = lsi_settings_window_dispose;
}
/**
* lsi_settings_window_init:
*
* Handle construction of the LsiSettingsWindow
*/
static void lsi_settings_window_init(LsiSettingsWindow *self)
{
GtkWidget *grid = NULL;
GtkWidget *layout = NULL;
GtkWidget *header = NULL;
GtkWidget *widget = NULL;
GtkStyleContext *style = NULL;
const gchar *xdg_desktop = NULL;
const gchar *emul32_desc = NULL;
bool is_64bit = false;
gchar *label = NULL;
int row = 0;
/* Ensure we correctly clean this up.. */
memset(&self->config, 0, sizeof(LsiConfig));
/* Load the LSI configuration now */
if (!lsi_config_load(&self->config)) {
lsi_config_load_defaults(&self->config);
}
/* Conditionally apply CSD */
#if GTK_CHECK_VERSION(3, 12, 0)
xdg_desktop = g_getenv("XDG_CURRENT_DESKTOP");
if (xdg_desktop && (strstr(xdg_desktop, "GNOME:") || strstr(xdg_desktop, ":GNOME") ||
g_str_equal(xdg_desktop, "GNOME"))) {
widget = gtk_header_bar_new();
gtk_header_bar_set_show_close_button(GTK_HEADER_BAR(widget), TRUE);
gtk_window_set_titlebar(GTK_WINDOW(self), widget);
}
#endif
/* For now we'll just exit on close */
g_signal_connect(self, "delete-event", G_CALLBACK(lsi_window_closed), NULL);
/* Sort out window bits */
gtk_window_set_title(GTK_WINDOW(self), _("Linux Steam® Integration"));
gtk_window_set_icon_name(GTK_WINDOW(self), "steam");
gtk_window_set_position(GTK_WINDOW(self), GTK_WIN_POS_CENTER);
gtk_widget_set_size_request(GTK_WIDGET(self), 320, 500);
gtk_window_set_resizable(GTK_WINDOW(self), FALSE);
/* Add main layout */
layout = gtk_box_new(GTK_ORIENTATION_VERTICAL, 0);
gtk_container_add(GTK_CONTAINER(self), layout);
gtk_container_set_border_width(GTK_CONTAINER(self), 12);
gtk_widget_set_valign(GTK_WIDGET(layout), GTK_ALIGN_START);
/* Header box */
header = gtk_box_new(GTK_ORIENTATION_HORIZONTAL, 0);
gtk_box_pack_start(GTK_BOX(layout), header, FALSE, FALSE, 0);
/* header label */
label = g_strdup_printf("<big>%s</big>", _("Linux Steam® Integration"));
widget = gtk_label_new(label);
gtk_label_set_use_markup(GTK_LABEL(widget), TRUE);
g_free(label);
_align_label(widget);
gtk_box_pack_start(GTK_BOX(header), widget, FALSE, FALSE, 0);
/* header image */
widget = gtk_image_new_from_icon_name("steam", GTK_ICON_SIZE_DIALOG);
gtk_widget_set_valign(widget, GTK_ALIGN_START);
gtk_box_pack_end(GTK_BOX(header), widget, FALSE, FALSE, 0);
/* small label */
widget = gtk_label_new(
_("Control the behaviour of the Steam client and games. Settings will not take effect "
"until the Steam Client is restarted. Use the 'Exit Steam' option to ensure it "
"closes."));
g_object_set(widget, "xalign", 0.0, NULL);
gtk_label_set_max_width_chars(GTK_LABEL(widget), 80);
gtk_label_set_line_wrap(GTK_LABEL(widget), TRUE);
gtk_label_set_line_wrap_mode(GTK_LABEL(widget), PANGO_WRAP_WORD);
_align_label(widget);
gtk_box_pack_start(GTK_BOX(layout), widget, TRUE, TRUE, 0);
style = gtk_widget_get_style_context(widget);
gtk_style_context_add_class(style, GTK_STYLE_CLASS_DIM_LABEL);
#if GTK_CHECK_VERSION(3, 12, 0)
gtk_widget_set_margin_end(widget, 100);
#else
gtk_widget_set_margin_right(widget, 100);
#endif
/* add a separator now */
widget = gtk_separator_new(GTK_ORIENTATION_HORIZONTAL);
gtk_box_pack_start(GTK_BOX(layout), widget, FALSE, FALSE, 0);
g_object_set(widget, "margin-top", 12, "margin-bottom", 4, NULL);
/* Start populating main grid with controls */
grid = gtk_grid_new();
gtk_box_pack_start(GTK_BOX(layout), grid, FALSE, FALSE, 0);
/* Start populating options into the UI */
self->check_native = insert_grid_toggle(
grid,
&row,
_("Use native runtime"),
_("Switch between the native runtime and the bundled Steam runtime."));
/* Load in the existing configuration */
gtk_switch_set_active(GTK_SWITCH(self->check_native), self->config.use_native_runtime);
is_64bit = lsi_system_is_64bit();
/* Can only force on a 64-bit system. */
if (!is_64bit) {
/* Label is shown to indicate we can't enable 32-bit option */
emul32_desc = _("This option has been disabled as the system is already 32-bit");
} else {
/* Label is shown on 64-bit systems only */
emul32_desc =
_("This may workaround some broken games, but will disable the Steam store "
"browser.");
}
self->check_emul32 =
insert_grid_toggle(grid, &row, _("Force 32-bit mode for Steam"), emul32_desc);
set_row_sensitive(self->check_emul32, is_64bit);
gtk_switch_set_active(GTK_SWITCH(self->check_emul32), self->config.force_32);
#ifdef HAVE_LIBINTERCEPT
self->check_intercept = insert_grid_toggle(
grid,
&row,
_("Use the intercept library"),
_("Force Steam applications to use more native libraries to maximise compatibility."));
set_row_sensitive(self->check_intercept, FALSE);
gtk_switch_set_active(GTK_SWITCH(self->check_intercept), self->config.use_libintercept);
#endif
#ifdef HAVE_LIBREDIRECT
self->check_redirect =
insert_grid_toggle(grid,
&row,
_("Use the redirect library"),
_("Override system calls to fix known bugs in some "
"Linux ports."));
set_row_sensitive(self->check_redirect, FALSE);
gtk_switch_set_active(GTK_SWITCH(self->check_redirect), self->config.use_libredirect);
self->check_unity_hack = insert_grid_toggle(grid,
&row,
_("Use the Unity fullscreen workaround"),
_("Prevent some Unity games from launching in "
"full screen mode to fix numerous issues"));
set_row_sensitive(self->check_unity_hack, FALSE);
gtk_switch_set_active(GTK_SWITCH(self->check_unity_hack), self->config.use_unity_hack);
#endif
/* Hook up our signals. Basically the "native runtime" option controls the two library
* options, they must be used in conjunction.
*/
g_signal_connect_swapped(self->check_native,
"notify::active",
G_CALLBACK(lsi_native_swapped),
self);
/* Changes to redirect will disable/enable unity hack */
g_signal_connect_swapped(self->check_redirect,
"notify::active",
G_CALLBACK(lsi_native_swapped),
self);
/* Ensure our properties are now in sync. */
lsi_native_swapped(self, self->check_native);
/* Finally, make sure we're visible will we. */
gtk_widget_show_all(GTK_WIDGET(self));
}
static void _align_label(GtkWidget *label)
{
#if GTK_CHECK_VERSION(3, 12, 0)
gtk_widget_set_halign(label, GTK_ALIGN_START);
#else
gtk_misc_set_alignment(GTK_MISC(label), 0.0f, 0.5f);
#endif
gtk_widget_set_hexpand(label, FALSE);
gtk_widget_set_valign(label, GTK_ALIGN_START);
}
/**
* Generic function to add titled description box with a custom widget into the grid.
*/
static void insert_grid(GtkWidget *grid, int *row, const char *title, const char *description,
GtkWidget *widget)
{
GtkWidget *label = NULL;
GtkWidget *desc = NULL;
GtkStyleContext *style = NULL;
/* Sort out title label */
label = gtk_label_new(title);
_align_label(label);
g_object_set(label, "margin-top", 12, "hexpand", TRUE, NULL);
gtk_grid_attach(GTK_GRID(grid), label, 0, *row, 1, 1);
g_object_set(widget,
"halign",
GTK_ALIGN_END,
"valign",
GTK_ALIGN_END,
"vexpand",
FALSE,
NULL);
gtk_grid_attach(GTK_GRID(grid), widget, 1, *row, 1, 1);
*row += 1;
/* Sort out description label */
desc = gtk_label_new(description);
_align_label(desc);
style = gtk_widget_get_style_context(desc);
gtk_style_context_add_class(style, GTK_STYLE_CLASS_DIM_LABEL);
#if GTK_CHECK_VERSION(3, 12, 0)
gtk_widget_set_margin_end(desc, 12);
#else
gtk_widget_set_margin_right(desc, 12);
#endif
/* Deprecated but line wrap is busted without it.. */
g_object_set(desc, "xalign", 0.0, NULL);
gtk_label_set_line_wrap(GTK_LABEL(desc), TRUE);
gtk_label_set_line_wrap_mode(GTK_LABEL(desc), PANGO_WRAP_WORD);
gtk_label_set_max_width_chars(GTK_LABEL(desc), 90);
gtk_grid_attach(GTK_GRID(grid), desc, 0, *row, 1, 1);
*row += 1;
/* Allow accessing these dynamic items again */
g_object_set_data(G_OBJECT(widget), "lsi_title", label);
g_object_set_data(G_OBJECT(widget), "lsi_desc", desc);
}
/**
* Set the complete row within the grid to the given sensitivity state
*/
static void set_row_sensitive(GtkWidget *toggle, gboolean sensitive)
{
GtkWidget *title = NULL;
GtkWidget *desc = NULL;
title = g_object_get_data(G_OBJECT(toggle), "lsi_title");
desc = g_object_get_data(G_OBJECT(toggle), "lsi_desc");
gtk_widget_set_sensitive(toggle, sensitive);
gtk_widget_set_sensitive(title, sensitive);
gtk_widget_set_sensitive(desc, sensitive);
}
/**
* Builds on the insert_grid function to insert a GtkSwitch and return only the
* switch widget.
*/
static GtkWidget *insert_grid_toggle(GtkWidget *grid, int *row, const char *title,
const char *description)
{
GtkWidget *toggle = NULL;
/* Sort out widget */
toggle = gtk_switch_new();
insert_grid(grid, row, title, description, toggle);
return toggle;
}
/**
* Update the sensitivity of the UI controls based on whether or not we have
* native runtime turned on
*/
static void lsi_native_swapped(LsiSettingsWindow *self, __lsi_unused__ gpointer v)
{
gboolean native_runtime;
gboolean redirect;
native_runtime = gtk_switch_get_active(GTK_SWITCH(self->check_native));
#ifdef HAVE_LIBREDIRECT
redirect = gtk_switch_get_active(GTK_SWITCH(self->check_redirect));
set_row_sensitive(self->check_redirect, native_runtime);
set_row_sensitive(self->check_unity_hack, native_runtime && redirect);
#endif
#ifdef HAVE_LIBINTERCEPT
set_row_sensitive(self->check_intercept, native_runtime);
#endif
}
/**
* Window is closed, so let's write our config out
*/
static gboolean lsi_window_closed(LsiSettingsWindow *self, __lsi_unused__ GdkEvent *event,
__lsi_unused__ gpointer v)
{
/* Just pop the properties back into the struct */
self->config.force_32 = gtk_switch_get_active(GTK_SWITCH(self->check_emul32));
self->config.use_native_runtime = gtk_switch_get_active(GTK_SWITCH(self->check_native));
#ifdef HAVE_LIBREDIRECT
self->config.use_libredirect = gtk_switch_get_active(GTK_SWITCH(self->check_redirect));
self->config.use_unity_hack = gtk_switch_get_active(GTK_SWITCH(self->check_unity_hack));
#endif
#ifdef HAVE_LIBINTERCEPT
self->config.use_libintercept = gtk_switch_get_active(GTK_SWITCH(self->check_intercept));
#endif
/* Try to write new config */
if (!lsi_config_store(&self->config)) {
lsi_report_failure("%s: %s", _("Failed to save configuration"), strerror(errno));
}
gtk_main_quit();
return FALSE;
}
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+49
View File
@@ -0,0 +1,49 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2016-2017 Ikey Doherty <ikey@solus-project.com>
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#pragma once
#include <glib-object.h>
#include <gtk/gtk.h>
G_BEGIN_DECLS
typedef struct _LsiSettingsWindow LsiSettingsWindow;
typedef struct _LsiSettingsWindowClass LsiSettingsWindowClass;
#define LSI_TYPE_SETTINGS_WINDOW lsi_settings_window_get_type()
#define LSI_SETTINGS_WINDOW(o) \
(G_TYPE_CHECK_INSTANCE_CAST((o), LSI_TYPE_SETTINGS_WINDOW, LsiSettingsWindow))
#define LSI_IS_SETTINGS_WINDOW(o) (G_TYPE_CHECK_INSTANCE_TYPE((o), LSI_TYPE_SETTINGS_WINDOW))
#define LSI_SETTINGS_WINDOW_CLASS(o) \
(G_TYPE_CHECK_CLASS_CAST((o), LSI_TYPE_SETTINGS_WINDOW, LsiSettingsWindowClass))
#define LSI_IS_SETTINGS_WINDOW_CLASS(o) (G_TYPE_CHECK_CLASS_TYPE((o), LSI_TYPE_SETTINGS_WINDOW))
#define LSI_SETTINGS_WINDOW_GET_CLASS(o) \
(G_TYPE_INSTANCE_GET_CLASS((o), LSI_TYPE_SETTINGS_WINDOW, LsiSettingsWindowClass))
GtkWidget *lsi_settings_window_new(void);
GType lsi_settings_window_get_type(void);
G_END_DECLS
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+18 -124
View File
@@ -1,7 +1,8 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2016 Ikey Doherty
* Copyright © 2016-2018 Ikey Doherty <ikey@solus-project.com>
* Copyright © 2018-2019 Intel Corporation
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
@@ -11,138 +12,31 @@
#define _GNU_SOURCE
#include <errno.h>
#include <gtk/gtk.h>
#include <glib/gi18n.h>
#include <stdlib.h>
#include <string.h>
#include <sys/stat.h>
#include "lsi.h"
static inline void _align_label(GtkWidget *label)
{
#if GTK_MINOR_VERSION <= 12
gtk_misc_set_alignment(GTK_MISC(label), 0.0f, 0.5f);
#else
gtk_widget_set_halign(label, GTK_ALIGN_START);
#endif
gtk_widget_set_hexpand(label, FALSE);
gtk_widget_set_valign(label, GTK_ALIGN_START);
}
#include "config.h"
#include "main-window.h"
/**
* Main application entry.
*/
int main(int argc, char **argv)
{
GtkWidget *window = NULL;
setlocale(LC_ALL, "");
bindtextdomain(GETTEXT_PACKAGE, LOCALEDIR);
bind_textdomain_codeset(GETTEXT_PACKAGE, "UTF-8");
textdomain(GETTEXT_PACKAGE);
gtk_init(&argc, &argv);
GtkWidget *dialog = NULL;
GtkWidget *grid = NULL;
GtkWidget *container = NULL;
GtkWidget *button = NULL;
GtkWidget *image = NULL;
GtkWidget *check_native = NULL;
GtkWidget *check_emul32 = NULL;
GtkWidget *label = NULL;
GtkSettings *settings = NULL;
int response = 0;
bool is_x86_64 = lsi_system_is_64bit();
LsiConfig lconfig = { 0 };
dialog = gtk_dialog_new();
g_object_set(G_OBJECT(dialog),
"title",
"Linux Steam® Integration",
"icon-name",
"steam",
NULL);
window = lsi_settings_window_new();
gtk_widget_show(window);
settings = gtk_settings_get_default();
g_object_set(settings, "gtk-application-prefer-dark-theme", TRUE, NULL);
gtk_main();
/* Sort out the buttons */
(void)gtk_dialog_add_button(GTK_DIALOG(dialog), "Cancel", GTK_RESPONSE_REJECT);
button = gtk_dialog_add_button(GTK_DIALOG(dialog), "OK", GTK_RESPONSE_ACCEPT);
gtk_style_context_add_class(gtk_widget_get_style_context(button), "suggested-action");
/* Pack the grid */
grid = gtk_grid_new();
gtk_grid_set_column_spacing(GTK_GRID(grid), 12);
gtk_grid_set_row_spacing(GTK_GRID(grid), 12);
container = gtk_dialog_get_content_area(GTK_DIALOG(dialog));
gtk_container_add(GTK_CONTAINER(container), grid);
gtk_container_set_border_width(GTK_CONTAINER(container), 6);
/* Add a splash of colour. */
image = gtk_image_new_from_icon_name("steam", GTK_ICON_SIZE_DIALOG);
gtk_image_set_pixel_size(GTK_IMAGE(image), 64);
gtk_grid_attach(GTK_GRID(grid), image, 0, 0, 1, 1);
label = gtk_label_new(
"<big>Linux Steam® Integration</big>\n"
"Note that settings are not applied until the next time Steam® starts.\n"
"Use the \'Exit Steam\' option on the Steam® tray icon to exit the application.");
_align_label(label);
gtk_grid_attach(GTK_GRID(grid), label, 1, 0, 2, 1);
gtk_label_set_use_markup(GTK_LABEL(label), TRUE);
gtk_widget_set_margin_bottom(label, 8);
label = gtk_label_new("Use the native runtime provided by the Operating System");
_align_label(label);
gtk_widget_set_tooltip_text(label,
"Alternatively, the default Steam® runtime "
"will be used, which may cause issues.");
gtk_grid_attach(GTK_GRID(grid), label, 1, 1, 1, 1);
check_native = gtk_switch_new();
gtk_grid_attach(GTK_GRID(grid), check_native, 2, 1, 1, 1);
/* Handle the 32-bit cruft */
label = gtk_label_new("Force 32-bit mode for Steam®");
_align_label(label);
if (is_x86_64) {
gtk_widget_set_tooltip_text(label,
"Some games may run better using 32-bit than 64-bit");
} else {
gtk_widget_set_tooltip_text(label, "You are using a 32-bit operating system");
}
gtk_grid_attach(GTK_GRID(grid), label, 1, 2, 1, 1);
check_emul32 = gtk_switch_new();
gtk_grid_attach(GTK_GRID(grid), check_emul32, 2, 2, 1, 1);
gtk_widget_set_sensitive(label, is_x86_64);
gtk_widget_set_sensitive(check_emul32, is_x86_64);
gtk_container_set_border_width(GTK_CONTAINER(grid), 6);
gtk_widget_set_margin_bottom(grid, 18);
/* Load the config */
if (!lsi_config_load(&lconfig)) {
lsi_config_load_defaults(&lconfig);
}
/* Adapt UI to match config */
gtk_switch_set_active(GTK_SWITCH(check_native), lconfig.use_native_runtime);
gtk_switch_set_active(GTK_SWITCH(check_emul32), lconfig.force_32);
/* Run the dialog */
gtk_widget_show_all(container);
response = gtk_dialog_run(GTK_DIALOG(dialog));
if (response == GTK_RESPONSE_REJECT) {
gtk_widget_destroy(dialog);
return EXIT_SUCCESS;
}
/* Get the config from the UI */
lconfig.use_native_runtime = gtk_switch_get_active(GTK_SWITCH(check_native));
lconfig.force_32 = gtk_switch_get_active(GTK_SWITCH(check_emul32));
/* Cleanup */
gtk_widget_destroy(dialog);
/* Try to write new config */
if (!lsi_config_store(&lconfig)) {
lsi_report_failure("Failed to save configuration: %s", strerror(errno));
return EXIT_FAILURE;
}
return EXIT_SUCCESS;
}
+25
View File
@@ -0,0 +1,25 @@
if with_frontend == true
dep_gtk3 = dependency('gtk+-3.0', version: '>= 3.4.0')
frontend_sources = [
'main.c',
'main-window.c',
]
frontend_name = 'lsi-settings'
if with_snap_support == true
frontend_name = 'linux-steam-integration.settings'
endif
frontend = executable(
frontend_name,
sources: frontend_sources + nica_sources,
include_directories: nica_includes,
dependencies: [
dep_gtk3,
link_lsi,
],
install: true,
install_dir: path_bindir,
)
endif
+670
View File
@@ -0,0 +1,670 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2016-2018 Ikey Doherty <ikey@solus-project.com>
* Copyright © 2018-2019 Intel Corporation
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#define _GNU_SOURCE
#include <libgen.h>
#include <link.h>
#include <linux/limits.h>
#include <stdio.h>
#include <stdlib.h>
#include <sys/stat.h>
#include "../common/common.h"
#include "../common/files.h"
#include "../common/log.h"
#include "config.h"
#include "nica/util.h"
/**
* What's the known process name?
*/
static const char *matched_process = NULL;
static bool lsi_override_replace_with_host(const char *orig_name, const char **soname,
const char *msg);
static bool lsi_override_soname(unsigned int flag, const char *orig_name, const char **soname);
/**
* We support a number of modes, but we mostly exist to make Steam behave
*/
typedef enum {
INTERCEPT_MODE_NONE = 0,
INTERCEPT_MODE_STEAM,
INTERCEPT_MODE_VENDOR_OFFENDER,
} InterceptMode;
/**
* by default, we're not "on"
*/
static InterceptMode work_mode = INTERCEPT_MODE_NONE;
/* Patterns we'll permit Steam to privately load */
static const char *steam_allowed[] = {
/* general */
"libicui18n.so",
"libicuuc.so",
"libavcodec.so.",
"libavformat.so.",
"libavresample.so.",
"libavutil.so.",
"libswscale.so.",
"libx264.so.",
/* core plugins */
"chromehtml.so",
"crashhandler.so",
"filesystem_stdio.so",
"friendsui.so",
"gameoverlayrenderer.so",
"gameoverlayui.so",
"libaudio.so",
"libmiles.so",
"libopenvr_api.so",
"liboverride.so",
"libsteam.so",
"libtier0_s.so",
"libv8.so",
"libvideo.so",
"libvstdlib_s.so",
"serverbrowser.so",
"steamclient.so",
"steamoverlayvulkanlayer.so",
"steamservice.so",
"steamui.so",
"vgui2_s.so",
/* big picture mode */
"panorama",
"libpangoft2-1.0.so",
"libpango-1.0.so",
"libpangocairo-1.0.so",
/* steamwebhelper */
"libcef.so",
/* Swift shader */
"libGLESv2.so",
"libEGL.so",
/* widevine */
"libwidevinecdmadapter.so",
"libwidevinecdm.so",
};
static const char *wanted_steam_processes[] = {
"html5app_steam",
"opengl-program",
"steam",
"steamwebhelper",
};
/**
* Vendor offendors should not be allowed to load replacements for libraries
* that are KNOWN to cause issues, i.e. SDL + libstdc++
*/
static const char *vendor_blacklist[] = {
/* base libraries being replaced will cause a C++ ABI issue when
* loading the mesalib drivers. */
"libgcc_",
"libstdc++",
/* Ensure we don't match weird made up cruft like "libSDL2_locale" */
"libSDL-1.2",
#if UINTPTR_MAX == 0xffffffffffffffff
/* Only blacklist SDL on native 64-bit builds
* 32-bit builds tend to do weird stuff, like ship incompatible
* patched builds of libSDL (Don't Starve, for example)
*/
"libSDL2-2",
#endif
"libSDL2_ttf",
"libSDL_ttf",
"libSDL2_image",
"libSDL_image",
"libSDL2_mixer",
"libSDL_mixer",
"libSDL2_net",
"libSDL_net",
"libSDL2_gfx",
"libSDL_gfx",
/* vendor-owned */
"libz.so.1",
"libfreetype.so.6",
"libmpg123.so.0",
/* general problem causer. */
"libopenal.so.",
/* glews (provide glew + glew110 in your distro for full compat) */
"libGLEW.so.1.10",
"libGLEW.so.1.12",
/* libglu has stable soname */
"libGLU.so.",
/* Security sensitive libraries should not be replaced */
"libcurl.so.",
#ifdef LSI_OVERRIDE_LIBRESSL
/* Sometimes libressl but this is handled separately. */
"libcrypto.so.",
"libssl.so.",
#else
"libcrypto.so.1.0.0",
"libssl.so.1.0.0",
#endif
/* TODO/FUTURE:
"libaudiofile.so.1", */
};
/**
* Determine if we're in a given process set, i.e. the process name matches
* the given table
*/
static bool is_in_process_set(char *process_name, const char **processes, size_t n_processes)
{
/* Are we some portion of the process set? */
for (size_t i = 0; i < n_processes; i++) {
if (streq(processes[i], process_name)) {
work_mode = INTERCEPT_MODE_STEAM;
matched_process = processes[i];
lsi_log_debug("loading libintercept for '%s'", matched_process);
return true;
}
}
return false;
}
/**
* Find out if we're being executed by a process we actually need to override,
* otherwise we'd not be loaded by rtld-audit
*/
static void check_is_intercept_candidate(void)
{
autofree(char) *nom = NULL;
nom = lsi_get_process_base_name();
if (!nom) {
return;
}
if (is_in_process_set(nom, wanted_steam_processes, ARRAY_SIZE(wanted_steam_processes))) {
work_mode = INTERCEPT_MODE_STEAM;
} else {
work_mode = INTERCEPT_MODE_VENDOR_OFFENDER;
matched_process = "vendor_offender";
}
lsi_log_set_id(matched_process);
}
/**
* la_version is our main entry point and will only continue if our
* process is explicitly Steam
*/
_nica_public_ unsigned int la_version(unsigned int supported_version)
{
/* Unfortunately glibc will die if we tell it to skip us .. */
check_is_intercept_candidate();
return supported_version;
}
/**
* lsi_search_steam handles whitelisting for the main Steam processes
*/
char *lsi_search_steam(unsigned int flag, const char *name)
{
const char *soname = NULL;
/* Preemptively catch transmutations */
if (lsi_override_soname(flag, name, &soname)) {
return (char *)soname;
}
if (!lsi_file_exists(name)) {
return (char *)name;
}
/* Find out if its a Steam private lib.. These are relative "./" files too! */
if (name && (strstr(name, "/Steam/") || strncmp(name, "./", 2) == 0)) {
for (size_t i = 0; i < ARRAY_SIZE(steam_allowed); i++) {
if (strstr(name, steam_allowed[i])) {
return (char *)name;
}
}
lsi_log_debug("blacklisted loading of vendor library: \033[34;1m%s\033[0m", name);
return NULL;
}
return (char *)name;
}
/**
* Source identifier patterns that indicate a soname replacement is happening.
* Note that this is a basic pattern match for the soname and just allows us
* to lookup the transmute target
*/
static const char *vendor_transmute_source[] = {
/* Common */
"libSDL2-2.0.",
"libSDL2_image-2.0.",
/* ".so" renames */
"libSDL2_ttf.so",
"libSDL2_image.so",
"libSDL2_mixer.so",
"libSDL2_net.so",
"libSDL2_gfx.so",
/* libressl (security updates) */
#ifdef LSI_OVERRIDE_LIBRESSL
"libcrypto.so.36",
"libssl.so.37",
"libcrypto.so.42",
"libssl.so.44",
#endif
/* old name for openal */
"libopenal-soft.so.1",
/* invalid curls */
"libcurl-gnutls.so.3",
"libcurl.so.3",
"libbz2.so.1.0",
"libudev.so.0",
};
/**
* The transmute target is the intended replacement for any source name, assuming
* that the soname doesn't identically match the currently requested soname.
* This allows us to do on the fly replacements for re-soname'd libraries.
*/
static const char *vendor_transmute_target[] = {
/* Common */
"libSDL2-2.0.so.0",
"libSDL2_image-2.0.so.0",
/* ".so" renames */
"libSDL2_ttf-2.0.so.0",
"libSDL2_image-2.0.so.0",
"libSDL2_mixer-2.0.so.0",
"libSDL2_net-2.0.so.0",
"libSDL2_gfx-1.0.so.0",
/* libressl (security updates) */
#if defined(LSI_LIBRESSL_MODE_SHIM)
"libcrypto" LSI_LIBRESSL_SUFFIX ".so",
"libssl" LSI_LIBRESSL_SUFFIX ".so",
"libcrypto" LSI_LIBRESSL_SUFFIX ".so",
"libssl" LSI_LIBRESSL_SUFFIX ".so",
#elif defined(LSI_LIBRESSL_MODE_NATIVE)
"libcrypto.so.1.0.0",
"libssl.so.1.0.0",
"libcrypto.so.1.0.0",
"libssl.so.1.0.0",
#endif
/* new name for openal */
"libopenal.so.1",
/* invalid curls */
"libcurl-gnutls.so.4",
"libcurl.so.4",
"libbz2.so.1.0.6",
"libudev.so.1",
};
/**
* Every so often a game comes along that does the following:
*
* open("path") ? dlopen("path").
* Except: path = "*.dll", dlopen() is transformed to ".dll.so"
*
* This is unrelated to the ".la" errors
*/
static bool lsi_override_dll_fail(const char *orig_name, const char **soname)
{
size_t len = strlen(orig_name);
static char path_lookup[PATH_MAX];
if (len < 7) {
return false;
}
if (strncmp(orig_name + (len - 7), ".dll.so", 7) != 0) {
return false;
}
if (!strncpy(path_lookup, orig_name, len - 3)) {
return false;
}
if (!lsi_file_exists(path_lookup)) {
return false;
}
*soname = path_lookup;
lsi_log_debug("fixed invalid suffix dlopen() \033[31;1m%s\033[0m -> \033[34;1m%s\033[0m",
orig_name,
path_lookup);
return true;
}
/**
* Mono games might try looking for /x86/ plugin directory for a 64-bit process,
* as seen with testing with Project Highrise.
*
* This function simply redirects the dlopen to the file in the x86_64 directory,
* if it actually exists.
*
* Typically this is for libCSteamWorks, libsteam_api, and Unity ScreenSelector.so
*/
#if UINTPTR_MAX == 0xffffffffffffffff
static bool lsi_override_x86_derp(const char *orig_name, const char **soname)
{
static char path_copy[PATH_MAX];
static char path_lookup[PATH_MAX];
char *small_name = NULL;
char *dir = NULL;
if (!(strstr(orig_name, "/Plugins/x86/") && strstr(orig_name, ".so"))) {
return false;
}
if (!strcpy(path_copy, orig_name)) {
return false;
}
small_name = basename(path_copy);
dir = dirname(path_copy);
if (snprintf(path_lookup, sizeof(path_lookup), "%s/../x86_64/%s", dir, small_name) < 0) {
return false;
}
if (!lsi_file_exists(path_lookup)) {
return false;
}
*soname = path_lookup;
lsi_log_debug(
"fixed invalid architecture dlopen() \033[31;1m%s\033[0m -> \033[34;1m%s\033[0m",
orig_name,
path_lookup);
return true;
}
#else
static bool lsi_override_x86_derp(__lsi_unused__ const char *orig_name,
__lsi_unused__ const char **soname)
{
/* Don't perform x86 translation on 32-bit machines */
return false;
}
#endif
/**
* Internal helper for path replacement to host lib
*/
static bool lsi_override_replace_with_host(const char *orig_name, const char **soname,
const char *msg)
{
static char path_lookup[PATH_MAX];
static char path_copy[PATH_MAX];
char *small_name = NULL;
static const char *library_paths[] = {
#if UINTPTR_MAX == 0xffffffffffffffff
#ifdef HAVE_SNAPD_SUPPORT
"/var/lib/snapd/lib/gl",
#endif
"/usr/lib64",
"/usr/lib/x86_64-linux-gnu",
"/usr/lib",
#else
#ifdef HAVE_SNAPD_SUPPORT
"/var/lib/snapd/lib/gl32",
#endif
"/usr/lib32",
"/usr/lib/i386-linux-gnu",
"/usr/lib",
#endif
};
if (!strcpy(path_copy, orig_name)) {
return false;
}
small_name = basename(path_copy);
/* Iterate all of the library paths for this process architecture and try
* to find a system variant of the library instead of allowing the process
* to dlopen() the vendored version.
*/
for (size_t i = 0; i < ARRAY_SIZE(library_paths); i++) {
if (snprintf(path_lookup,
sizeof(path_lookup),
"%s/%s",
library_paths[i],
small_name) < 0) {
return false;
}
if (!lsi_file_exists(path_lookup)) {
continue;
}
/* We hit a match but it was identical to our expectation */
if (strcmp(path_lookup, orig_name) == 0) {
return false;
}
*soname = path_lookup;
if (!msg) {
return true;
}
lsi_log_debug("%s \033[31;1m%s\033[0m -> \033[34;1m%s\033[0m",
msg,
orig_name,
path_lookup);
return true;
}
return false;
}
/**
* lsi_override_dlopen is used to override simple dlopen() requests typically
* used by Mono games, i.e.:
*
* <dllmap dll="SDL2.dll" os="linux" cpu="x86-64" target="./lib64/libSDL2-2.0.so.0"/>
*
* We'll attempt to do a trivial lookup for "/usr/./lib64/libSDL2-2.0.so.0 in this
* case.
*/
static bool lsi_override_dlopen(const char *orig_name, const char **soname)
{
if (lsi_override_dll_fail(orig_name, soname)) {
return true;
}
if (!lsi_file_exists(orig_name)) {
return false;
}
if (lsi_override_x86_derp(orig_name, soname)) {
return true;
}
return lsi_override_replace_with_host(orig_name, soname, "intercepting vendor dlopen()");
}
/**
* lsi_override_soname will deal with LA_SER_ORIG entries, i.e. the original
* soname request when the linker tries to load a library.
*
* Certain Steam games (notably Feral Interactive ports) use their own vendored
* SDL libraries with changed sonames, which are implicitly blacklisted by the
* lsi_blacklist_vendor function.
*
* As such, we intercept those renamed libraries, and convert their names back
* to the ABI stable system libraries on the fly.
*/
static bool lsi_override_soname(unsigned int flag, const char *orig_name, const char **soname)
{
*soname = NULL;
/* We only need to deal with LA_SER_ORIG */
if ((flag & LA_SER_ORIG) != LA_SER_ORIG) {
return false;
}
/* Don't transform dlopen */
if (strstr(orig_name, "/")) {
return lsi_override_dlopen(orig_name, soname);
}
for (size_t i = 0; i < ARRAY_SIZE(vendor_transmute_source); i++) {
if (!strstr(orig_name, vendor_transmute_source[i])) {
continue;
}
/* Ensure we're not just replacing the same thing here as the
* string would be identical, no real replacement would happen,
* and ld will be confused about memory and die.
*/
if (streq(orig_name, vendor_transmute_target[i])) {
continue;
}
*soname = vendor_transmute_target[i];
lsi_log_debug(
"transforming vendor soname: \033[31;1m%s\033[0m -> \033[34;1m%s\033[0m",
orig_name,
*soname);
return true;
}
return false;
}
/**
* If the library exists locally, and we're attempting to load this from a
* relative location, strongly attempt to actually use the system-version instead.
*
* Thus, if our CWD is our LD_LIBRARY_PATH and contains "libfreetype.so.6", we'll
* try to use the host version of the library if that exists, instead of relying
* on the locally vendored, potentially insecure/buggy version.
*/
static bool lsi_override_local(unsigned int flag, const char *orig_name, const char **soname)
{
*soname = NULL;
/* We only need to deal with LA_SER_ORIG */
if ((flag & LA_SER_ORIG) != LA_SER_ORIG) {
return false;
}
/* We only care about relative paths */
if (strstr(orig_name, "/")) {
return false;
}
/* We also only care about relative paths */
if (!lsi_file_exists(orig_name)) {
return false;
}
/* Resolve all paths back to the real library path version if they exist */
for (size_t i = 0; i < ARRAY_SIZE(vendor_blacklist); i++) {
if (!strstr(orig_name, vendor_blacklist[i])) {
continue;
}
return lsi_override_replace_with_host(orig_name,
soname,
"forcing use of host library");
}
return false;
}
char *lsi_blacklist_vendor(unsigned int flag, const char *name)
{
/* Find out if it exists */
bool file_exists = lsi_file_exists(name);
const char *override_soname = NULL;
/* Find out if we have to rename some libraries on the fly */
if (lsi_override_soname(flag, name, &override_soname)) {
return (char *)override_soname;
}
/* Locally exists due to directory foobar */
if (lsi_override_local(flag, name, &override_soname)) {
return (char *)override_soname;
}
/* Find out if its a Steam private lib.. These are relative "./" files too! */
if (name && (strstr(name, "/Steam/") || strstr(name, "/steamapps/") ||
strncmp(name, "./", 2) == 0)) {
for (size_t i = 0; i < ARRAY_SIZE(vendor_blacklist); i++) {
if (!strstr(name, vendor_blacklist[i])) {
continue;
}
if (file_exists) {
lsi_log_debug(
"blacklisted loading of vendor library: \033[34;1m%s\033[0m",
name);
}
return NULL;
}
/* Allowed to exist */
return (char *)name;
}
return (char *)name;
}
/**
* la_objsearch will allow us to blacklist certain LD_LIBRARY_PATH duplicate
* libraries being loaded by the Steam client, such as the broken libSDL shipped
* as a private vendored lib
*/
_nica_public_ char *la_objsearch(const char *name, __lsi_unused__ uintptr_t *cookie,
unsigned int flag)
{
switch (work_mode) {
case INTERCEPT_MODE_STEAM:
return lsi_search_steam(flag, name);
case INTERCEPT_MODE_VENDOR_OFFENDER:
return lsi_blacklist_vendor(flag, name);
case INTERCEPT_MODE_NONE:
default:
return (char *)name;
}
}
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+22
View File
@@ -0,0 +1,22 @@
# Only build libintercept if told to!
if with_libintercept == true
intercept_sources = [
'main.c',
]
sym_map = join_paths(meson.current_source_dir(), 'sym.map')
main_intercept = shared_library(
'lsi-intercept',
sources: intercept_sources,
c_args: ['-fvisibility=hidden'],
link_args: ['-Wl,--version-script=@0@'.format(sym_map)],
include_directories: nica_includes,
dependencies: [
link_lsi_common,
],
install: true,
)
endif
+7
View File
@@ -0,0 +1,7 @@
{
global:
la_objsearch;
la_version;
local:
*;
};
Submodule
+1
Submodule src/libnica added at 8ec3cf2291
+46 -35
View File
@@ -1,7 +1,8 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2016 Ikey Doherty
* Copyright © 2016-2018 Ikey Doherty <ikey@solus-project.com>
* Copyright © 2018-2019 Intel Corporation
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
@@ -26,6 +27,8 @@
#include "nica/hashmap.h"
#include "nica/inifile.h"
#include "../common/files.h"
/**
* Configuration file suffix, i.e. ~/.config/linux-steam-integration.conf
*/
@@ -42,38 +45,6 @@
*/
#define LSI_VENDOR_CONFIG_FILE VENDORDIR "/ " LSI_CONFIG_FILE
/**
* Determine the home directory
*/
static const char *lsi_get_home_dir(void)
{
char *c = NULL;
struct passwd *p = NULL;
c = getenv("HOME");
if (c) {
return c;
}
p = getpwuid(getuid());
if (!p) {
return NULL;
}
return p->pw_dir;
}
/**
* Determine the home config directory
*/
static char *lsi_get_user_config_dir(void)
{
const char *home = lsi_get_home_dir();
char *c = NULL;
if (asprintf(&c, "%s/.config", home) < 0) {
return NULL;
}
return c;
}
/**
* Build the user config file path
*/
@@ -143,6 +114,27 @@ bool lsi_config_load(LsiConfig *config)
map_val = NULL;
}
/* Do we want libintercept? */
map_val = nc_hashmap_get(nc_hashmap_get(mconfig, "Steam"), "use-libintercept");
if (map_val) {
config->use_libintercept = lsi_is_boolean_true(map_val);
map_val = NULL;
}
/* Do we want libredirect? */
map_val = nc_hashmap_get(nc_hashmap_get(mconfig, "Steam"), "use-libredirect");
if (map_val) {
config->use_libredirect = lsi_is_boolean_true(map_val);
map_val = NULL;
}
/* Do we want unity3d hack? */
map_val = nc_hashmap_get(nc_hashmap_get(mconfig, "Steam"), "use-unity-hack");
if (map_val) {
config->use_unity_hack = lsi_is_boolean_true(map_val);
map_val = NULL;
}
/* Check if 32-bit is being forced */
map_val = nc_hashmap_get(nc_hashmap_get(mconfig, "Steam"), "force-32bit");
if (map_val) {
@@ -163,11 +155,23 @@ bool lsi_config_store(LsiConfig *config)
{
autofree(FILE) *fp = NULL;
autofree(char) *conf = NULL;
autofree(char) *dir = NULL;
if (!config) {
return false;
}
/* Ensure we have config directory, i.e. when as a snap.. */
dir = lsi_get_user_config_dir();
if (!dir) {
return false;
}
if (!lsi_file_exists(dir)) {
if (mkdir(dir, 00755) < 0) {
return false;
}
}
conf = lsi_get_user_config_file();
if (!conf) {
return false;
@@ -178,9 +182,13 @@ bool lsi_config_store(LsiConfig *config)
return false;
}
if (fprintf(fp,
"[Steam]\nuse-native-runtime = %s\nforce-32bit = %s\n",
"[Steam]\nuse-native-runtime = %s\nforce-32bit = %s\nuse-libintercept = "
"%s\nuse-libredirect = %s\nuse-unity-hack = %s\n",
lsi_bool_to_string(config->use_native_runtime),
lsi_bool_to_string(config->force_32)) < 0) {
lsi_bool_to_string(config->force_32),
lsi_bool_to_string(config->use_libintercept),
lsi_bool_to_string(config->use_libredirect),
lsi_bool_to_string(config->use_unity_hack)) < 0) {
return false;
}
return true;
@@ -194,6 +202,9 @@ void lsi_config_load_defaults(LsiConfig *config)
* things that LSI knows about */
config->force_32 = false;
config->use_native_runtime = true;
config->use_libintercept = true;
config->use_libredirect = true;
config->use_unity_hack = true;
}
void lsi_report_failure(const char *s, ...)
+6 -19
View File
@@ -1,7 +1,7 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2016 Ikey Doherty
* Copyright © 2016-2017 Ikey Doherty <ikey@solus-project.com>
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
@@ -16,25 +16,21 @@
#include <fcntl.h>
#include <stdbool.h>
#include <stdint.h>
#include <sys/stat.h>
#include <stdlib.h>
#include <unistd.h>
#include "../common/common.h"
#include "config.h"
/* Mark a variable/argument as unused to skip warnings */
#define __lsi_unused__ __attribute__((unused))
/* Force inlining of a function */
#define __lsi_inline__ __attribute__((always_inline))
#define ARRAY_SIZE(x) (sizeof(x) / sizeof(x[0]))
/**
* Current Linux Steam Integration settings.
*/
typedef struct LsiConfig {
bool force_32; /**<Do we force 32-bit? */
bool use_native_runtime; /**<Do we force our native runtime? */
bool use_libintercept; /**<Do we force libintercept? */
bool use_libredirect; /**<Do we force libredirect? */
bool use_unity_hack; /**<Do we enable unity3d hack? */
} LsiConfig;
/**
@@ -101,15 +97,6 @@ __lsi_inline__ static inline const char *lsi_preload_list(void)
*/
void lsi_report_failure(const char *s, ...);
/**
* Quick helper to determine if the path exists
*/
__lsi_inline__ static inline bool lsi_file_exists(const char *path)
{
__lsi_unused__ struct stat st = { 0 };
return lstat(path, &st) == 0;
}
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
+21
View File
@@ -0,0 +1,21 @@
# Only build liblsi if told to!
if shim_behaviour != 'none' or with_frontend == true
lsi_sources = [
'lsi.c',
]
lib_lsi = static_library(
'lsi-lsi',
sources: lsi_sources,
dependencies: [
link_lsi_common,
],
include_directories: nica_includes,
)
link_lsi = declare_dependency(
link_with: lib_lsi,
include_directories: include_directories('.'),
)
endif
+24
View File
@@ -0,0 +1,24 @@
# Track how to build nica, as we actually build it twice..
nica_sources = [
'../libnica/src/array.c',
'../libnica/src/hashmap.c',
'../libnica/src/files.c',
'../libnica/src/inifile.c',
'../libnica/src/list.c',
'../libnica/src/nc-string.c',
'../libnica/src/util.c',
]
nica_includes = [
include_directories('libnica/src/include'),
include_directories('libnica/src/include/nica'),
config_h_dir,
]
subdir('common')
subdir('lsi')
subdir('frontend')
subdir('intercept')
subdir('redirect')
subdir('shim')
-472
View File
@@ -1,472 +0,0 @@
/*
* This file is part of libnica.
*
* Copyright (C) 2016 Intel Corporation
*
* libnica is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#define _GNU_SOURCE
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "hashmap.h"
#define INITIAL_SIZE 61
/* When we're "full", 70% */
#define FULL_FACTOR 0.7
/* Multiple to increase bucket size by */
#define INCREASE_FACTOR 4
/**
* An bucket/chain within the hashmap
*/
typedef struct NcHashmapEntry {
void *hash; /**<The key for this item */
void *value; /**<Value for this item */
struct NcHashmapEntry *next; /**<Next item in the chain */
bool occ; /**<Whether this bucket is occupied */
} NcHashmapEntry;
/**
* A NcHashmap
*/
struct NcHashmap {
int size; /**<Current size of the hashmap */
int next_size; /**<Next size at which we need to resize */
int n_buckets; /**<Current number of buckets */
NcHashmapEntry *buckets; /**<Stores our bucket chains */
nc_hash_create_func hash; /**<Hash generation function */
nc_hash_compare_func compare; /**<Key comparison function */
nc_hash_free_func key_free; /**<Cleanup function for keys */
nc_hash_free_func value_free; /**<Cleanup function for values */
};
/**
* Iteration object
*/
typedef struct _NcHashmapIter {
int bucket; /**<Current bucket position */
NcHashmap *map; /**<Associated NcHashmap */
void *item; /**<Current item in this iteration */
} _NcHashmapIter;
static void nc_hashmap_update_next_size(NcHashmap *self);
static bool nc_hashmap_resize(NcHashmap *self);
static inline bool nc_hashmap_maybe_resize(NcHashmap *self)
{
if (!self) {
return false;
}
if (self->size >= self->next_size) {
return true;
}
return false;
}
static NcHashmap *nc_hashmap_new_internal(nc_hash_create_func create, nc_hash_compare_func compare,
nc_hash_free_func key_free, nc_hash_free_func value_free)
{
NcHashmap *map = NULL;
NcHashmapEntry *buckets = NULL;
map = calloc(1, sizeof(NcHashmap));
if (!map) {
return NULL;
}
buckets = calloc(INITIAL_SIZE, sizeof(NcHashmapEntry));
if (!buckets) {
free(map);
return NULL;
}
map->buckets = buckets;
map->n_buckets = INITIAL_SIZE;
map->hash = create ? create : nc_simple_hash;
map->compare = compare ? compare : nc_simple_compare;
map->key_free = key_free;
map->value_free = value_free;
map->size = 0;
nc_hashmap_update_next_size(map);
return map;
}
NcHashmap *nc_hashmap_new(nc_hash_create_func create, nc_hash_compare_func compare)
{
return nc_hashmap_new_internal(create, compare, NULL, NULL);
}
NcHashmap *nc_hashmap_new_full(nc_hash_create_func create, nc_hash_compare_func compare,
nc_hash_free_func key_free, nc_hash_free_func value_free)
{
return nc_hashmap_new_internal(create, compare, key_free, value_free);
}
static inline unsigned nc_hashmap_get_hash(NcHashmap *self, const void *key)
{
unsigned hash = self->hash(key);
return hash;
}
static bool nc_hashmap_insert_bucket(NcHashmap *self, NcHashmapEntry *buckets, int n_buckets,
unsigned hash, const void *key, void *value)
{
NcHashmapEntry *row = &(buckets[hash % n_buckets]);
NcHashmapEntry *head = NULL;
NcHashmapEntry *parent = head = row;
bool can_replace = false;
NcHashmapEntry *tomb = NULL;
int ret = 1;
while (row) {
if (!row->occ) {
tomb = row;
}
parent = row;
if (row->occ && row->hash == key) {
if (self->compare(row->hash, key)) {
can_replace = true;
break;
}
}
row = row->next;
}
if (can_replace) {
/* Replace existing allocations. */
if (self->value_free) {
self->value_free(row->value);
}
if (self->key_free) {
self->key_free(row->hash);
}
ret = 0;
} else if (tomb) {
row = tomb;
}
if (!row) {
row = calloc(1, sizeof(NcHashmapEntry));
if (!row) {
return -1;
}
}
row->hash = (void *)key;
row->value = value;
row->occ = true;
if (parent != row && parent) {
parent->next = row;
}
return ret;
}
bool nc_hashmap_put(NcHashmap *self, const void *key, void *value)
{
if (!self) {
return false;
}
int inc;
if (nc_hashmap_maybe_resize(self)) {
if (!nc_hashmap_resize(self)) {
return false;
}
}
unsigned hash = nc_hashmap_get_hash(self, key);
inc = nc_hashmap_insert_bucket(self, self->buckets, self->n_buckets, hash, key, value);
if (inc > 0) {
self->size += inc;
return true;
} else {
return false;
}
}
static NcHashmapEntry *nc_hashmap_get_entry(NcHashmap *self, const void *key)
{
if (!self) {
return NULL;
}
unsigned hash = nc_hashmap_get_hash(self, key);
NcHashmapEntry *row = &(self->buckets[hash % self->n_buckets]);
while (row) {
if (self->compare(row->hash, key)) {
return row;
}
row = row->next;
}
return NULL;
}
void *nc_hashmap_get(NcHashmap *self, const void *key)
{
if (!self) {
return NULL;
}
NcHashmapEntry *row = nc_hashmap_get_entry(self, key);
if (row) {
return row->value;
}
return NULL;
}
static bool nc_hashmap_remove_internal(NcHashmap *self, const void *key, bool remove)
{
if (!self) {
return false;
}
NcHashmapEntry *row = nc_hashmap_get_entry(self, key);
if (!row) {
return false;
}
if (remove) {
if (self->key_free) {
self->key_free(row->hash);
}
if (self->value_free) {
self->value_free(row->value);
}
}
self->size -= 1;
row->hash = NULL;
row->value = NULL;
row->occ = false;
return true;
}
bool nc_hashmap_steal(NcHashmap *self, const void *key)
{
return nc_hashmap_remove_internal(self, key, false);
}
bool nc_hashmap_remove(NcHashmap *self, const void *key)
{
return nc_hashmap_remove_internal(self, key, true);
}
bool nc_hashmap_contains(NcHashmap *self, const void *key)
{
return (nc_hashmap_get(self, key)) != NULL;
}
static inline void nc_hashmap_free_bucket(NcHashmap *self, NcHashmapEntry *bucket, bool nuke)
{
if (!self) {
return;
}
NcHashmapEntry *tmp = bucket;
NcHashmapEntry *bk = bucket;
NcHashmapEntry *root = bucket;
while (tmp) {
bk = NULL;
if (tmp->next) {
bk = tmp->next;
}
if (nuke && tmp->occ) {
if (self->key_free) {
self->key_free(tmp->hash);
}
if (self->value_free) {
self->value_free(tmp->value);
}
}
if (tmp != root) {
free(tmp);
}
tmp = bk;
}
}
void nc_hashmap_free(NcHashmap *self)
{
if (!self) {
return;
}
for (int i = 0; i < self->n_buckets; i++) {
NcHashmapEntry *row = &(self->buckets[i]);
nc_hashmap_free_bucket(self, row, true);
}
if (self->buckets) {
free(self->buckets);
}
free(self);
}
static void nc_hashmap_update_next_size(NcHashmap *self)
{
if (!self) {
return;
}
self->next_size = (int)(self->n_buckets * FULL_FACTOR);
}
int nc_hashmap_size(NcHashmap *self)
{
if (!self) {
return -1;
}
return self->size;
}
static bool nc_hashmap_resize(NcHashmap *self)
{
if (!self || !self->buckets) {
return false;
}
NcHashmapEntry *old_buckets = self->buckets;
NcHashmapEntry *new_buckets = NULL;
NcHashmapEntry *entry = NULL;
int incr;
int old_size, new_size;
int items = 0;
new_size = old_size = self->n_buckets;
new_size *= INCREASE_FACTOR;
new_buckets = calloc(new_size, sizeof(NcHashmapEntry));
if (!new_buckets) {
return false;
}
for (int i = 0; i < old_size; i++) {
entry = &(old_buckets[i]);
while (entry) {
if (entry->occ) {
unsigned hash = nc_hashmap_get_hash(self, entry->hash);
if ((incr = nc_hashmap_insert_bucket(self,
new_buckets,
new_size,
hash,
entry->hash,
entry->value)) > 0) {
items += incr;
} else {
/* Likely a memory issue */
goto failure;
}
}
entry = entry->next;
}
}
/* Successfully resized - do this separately because we need to
* gaurantee old data is preserved */
for (int i = 0; i < old_size; i++) {
nc_hashmap_free_bucket(self, &(old_buckets[i]), false);
}
free(old_buckets);
self->n_buckets = new_size;
self->size = items;
self->buckets = new_buckets;
nc_hashmap_update_next_size(self);
return true;
failure:
for (int i = 0; i < new_size; i++) {
nc_hashmap_free_bucket(self, &(new_buckets[i]), true);
}
free(new_buckets);
return false;
}
void nc_hashmap_iter_init(NcHashmap *map, NcHashmapIter *citer)
{
_NcHashmapIter *iter = NULL;
if (!map || !citer) {
return;
}
iter = (_NcHashmapIter *)citer;
_NcHashmapIter it = {
.bucket = -1, .map = map, .item = NULL,
};
*iter = it;
}
bool nc_hashmap_iter_next(NcHashmapIter *citer, void **key, void **value)
{
_NcHashmapIter *iter = NULL;
NcHashmapEntry *item = NULL;
NcHashmap *map = NULL;
int n_buckets = 0;
if (!citer) {
return false;
}
iter = (_NcHashmapIter *)citer;
map = iter->map;
if (!map) {
return false;
}
n_buckets = map->n_buckets;
item = iter->item;
for (;;) {
if (iter->bucket >= n_buckets) {
if (item && !item->next) {
return false;
}
}
if (!item) {
iter->bucket++;
if (iter->bucket > n_buckets - 1) {
return false;
}
item = &(map->buckets[iter->bucket]);
}
if (item && item->occ) {
goto success;
}
item = item->next;
}
return false;
success:
iter->item = item->next;
if (key) {
*key = item->hash;
}
if (value) {
*value = item->value;
}
return true;
}
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
-239
View File
@@ -1,239 +0,0 @@
/*
* This file is part of libnica.
*
* Copyright (C) 2016 Intel Corporation
*
* libnica is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*
* This is a chained Hashmap implementation. It focuses on being clean
* and efficient, and is comparable (at -O2) to open addressing hashmaps
* up until around 105,000 elements, where open addressing will begin
* to come out in front. At 1 million elements, open addressing is a clear
* winner, however currently we only need a maximum of 70k elements in
* our implementation.
*
* Given the memory required to even begin to deal with 1 million elements,
* it becomes very questionable whether a hashmap should have even been
* used in the first place (mmap'd db?)
*/
#pragma once
#define _GNU_SOURCE
#include <stdbool.h>
#include <stdint.h>
#include "util.h"
/* Convert between uint and void* */
#define NC_HASH_KEY(x) ((void *)((uintptr_t)(x)))
#define NC_HASH_VALUE(x) NC_HASH_KEY(x)
#define NC_UNHASH_KEY(x) ((unsigned int)((uintptr_t)(x)))
#define NC_UNHASH_VALUE(x) NC_UNHASH_KEY(x)
typedef struct NcHashmap NcHashmap;
/**
* Iteration object
*/
typedef struct NcHashmapIter {
int n0;
void *n1;
void *n2;
} NcHashmapIter;
/**
* Hash comparison function definition
*
* @param l First value to compare
* @param r Second value to compare
*
* @return true if l and r both match, otherwise false
*/
typedef bool (*nc_hash_compare_func)(const void *l, const void *r);
/**
* Hash creation function definition
*
* @param key Key to generate a hash for
*
* @return an unsigned integer hash result
*/
typedef unsigned (*nc_hash_create_func)(const void *key);
/**
* Callback definition to free keys and values
*
* @param p Single-depth pointer to either a key or value that should be freed
*/
typedef void (*nc_hash_free_func)(void *p);
/**
* Default hash/comparison functions
*
* @note These are only used for comparison of *keys*, not values. Unless
* explicitly using string keys, you should most likely stick with the default
* nc_simple_hash and nc_simple_compare functions
*/
/* Default string hash */
static inline unsigned nc_string_hash(const void *key)
{
unsigned hash = 5381;
const signed char *c;
/* DJB's hash function */
for (c = key; *c != '\0'; c++) {
hash = (hash << 5) + hash + (unsigned)*c;
}
return hash;
}
/**
* Trivial pointer->uint hash
*/
static inline unsigned nc_simple_hash(const void *source)
{
return NC_UNHASH_KEY(source);
}
/**
* Comparison of string keys
*/
static inline bool nc_string_compare(const void *l, const void *r)
{
if (!l || !r) {
return false;
}
return (strcmp(l, r) == 0);
}
/**
* Trivial pointer comparison
*/
static inline bool nc_simple_compare(const void *l, const void *r)
{
return (l == r);
}
/**
* Create a new NcHashmap
*
* @param hash Hash creation function
* @param compare Key comparison function
*
* @return A newly allocated NcHashmap
*/
NcHashmap *nc_hashmap_new(nc_hash_create_func hash, nc_hash_compare_func compare);
/**
* Create a new NcHashmap with cleanup functions
*
* @param hash Hash creation function
* @param compare Key comparison function
* @param key_free Function to free keys when removed/destroyed
* @param value_free Function to free values when removed/destroyed
*
* @return A newly allocated NcHashmap
*/
NcHashmap *nc_hashmap_new_full(nc_hash_create_func hash, nc_hash_compare_func compare,
nc_hash_free_func key_free, nc_hash_free_func value_free);
/**
* Store a key/value pair in the hashmap
*
* @note This will displace duplicate keys, and may free both the key
* and value if key_free and value_free are non null
*
* @param key Key to store in the hashmap
* @param value Value to be associated with the key
*
* @return true if the operation succeeded.
*/
bool nc_hashmap_put(NcHashmap *map, const void *key, void *value);
/**
* Get the value associated with the unique key
*
* @param key Unique key to obtain a value for
* @return The associated value if it exists, otherwise NULL
*/
void *nc_hashmap_get(NcHashmap *map, const void *key);
/**
* Determine if the key has an associated value in the NcHashmap
*
* @param key Unique key to check value for
* @return True if the key exists in the hashmap
*/
bool nc_hashmap_contains(NcHashmap *self, const void *key);
/**
* Free the given NcHashmap, and all keys/values if appropriate
*/
void nc_hashmap_free(NcHashmap *map);
/**
* Remove the value and key identified by key.
*
* @note If key_free or value_free are non-NULL, they will be invoked
* for both the key and value being removed
*
* @param key The unique key to remove
* @return true if the key/value pair were removed
*/
bool nc_hashmap_remove(NcHashmap *map, const void *key);
/**
* Remove the value and key identified by key without freeing them
*
* @return true if the key/value pair were stolen
*/
bool nc_hashmap_steal(NcHashmap *map, const void *key);
/**
* Return the current size of the hashmap
*
* @return size of the current hashmap (element count)
*/
int nc_hashmap_size(NcHashmap *map);
/**
* Initialise a NcHashmapIter for iteration purposes
*
* @note The iter *must* be re-inited to re-use, or if it becomes
* exhausted from a previous iteration run
*
* @param iter pointer to a NcHashmapIter
*/
void nc_hashmap_iter_init(NcHashmap *map, NcHashmapIter *iter);
/**
* Iterate every key/value pair in the hashmap
*
* @param iter A correctly initialised NcHashmapIter
* @param key Pointers to store the key in, may be NULL to skip
* @param value Pointer to store the value in, may be NULL to skip
*
* @return true if it's possible to iterate
*/
bool nc_hashmap_iter_next(NcHashmapIter *iter, void **key, void **value);
DEF_AUTOFREE(NcHashmap, nc_hashmap_free)
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
-341
View File
@@ -1,341 +0,0 @@
/*
* This file is part of libnica.
*
* Copyright (C) 2016 Intel Corporation
*
* libnica is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#define _GNU_SOURCE
#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "hashmap.h"
#include "inifile.h"
/**
* Mapping of @NcIniError to static strings
*/
static const char *_errors[] = {[NC_INI_ERROR_FILE] = "",
[NC_INI_ERROR_EMPTY_KEY] = "Encountered empty key",
[NC_INI_ERROR_NOT_CLOSED] = "Expected closing \']\' for section",
[NC_INI_ERROR_NO_SECTION] =
"Encountered key=value mapping without a valid section",
[NC_INI_ERROR_INVALID_LINE] = "Expected key=value notation" };
const char *nc_ini_error(NcIniError error)
{
int j = abs(error);
if (j < NC_INI_ERROR_FILE || j >= NC_INI_ERROR_MAX) {
return "[Unknown Error]";
}
return _errors[j];
}
/**
* Strip leading whitespace from string (left)
*/
static char *lstrip(char *str, size_t len, size_t *out_len)
{
size_t skip_len = 0;
for (size_t i = 0; i < len; i++) {
if (str[i] == ' ' || str[i] == '\t') {
++skip_len;
continue;
}
break;
}
*out_len = len - skip_len;
if (skip_len > 0) {
char *c = strdup(str + skip_len);
free(str);
return c;
}
return str + skip_len;
}
/**
* Strip trailing whitespace from string (right)
*/
static char *rstrip(char *str, size_t len, size_t *out_len)
{
size_t skip_len = 0;
for (int i = len; i > 0; i--) {
if (str[i] == ' ' || str[i] == '\t') {
++skip_len;
continue;
} else if (str[i] == '\0') {
continue;
}
break;
}
*out_len = len - skip_len;
if (len == skip_len) {
return str;
}
str[(len - skip_len)] = '\0';
return str;
}
/**
* Chew both ends of a null terminated string of whitespace
* If the left side is whitespace padded, this will always result
* in a new allocation due to fast-forwarding the pointer. Keep
* this in mind.
*/
static char *string_chew_terminated(char *inp)
{
int skip_offset = 0;
int len = 0;
int end_len = 0;
bool count = true;
if (!inp) {
return NULL;
}
for (char *c = inp; *c; c++) {
if (count && (*c == ' ' || *c == '\t')) {
++skip_offset;
continue;
} else {
count = false;
}
++len;
}
for (int i = len; i > skip_offset; i--) {
if (inp[i] == ' ' || inp[i] == '\t') {
++end_len;
continue;
} else if (inp[i] == '\0') {
continue;
}
break;
}
if (end_len > 0) {
inp[(len - end_len)] = '\0';
}
if (skip_offset > 0) {
char *c = strdup(inp + skip_offset);
free(inp);
return c;
}
return inp;
}
/**
* Munch both ends of the string
*/
static char *string_strip(char *str, size_t len, size_t *out_len)
{
size_t mylen = len;
char *c = lstrip(str, len, &mylen);
c = rstrip(c, mylen, &mylen);
if (out_len) {
*out_len = mylen;
}
return c;
}
NcHashmap *nc_ini_file_parse(const char *path)
{
NcHashmap *ret = NULL;
int error_line = 0;
int r = 0;
r = nc_ini_file_parse_full(path, &ret, &error_line);
if (r != 0) {
if (abs(r) == NC_INI_ERROR_FILE) {
fprintf(stderr, "[inifile] %s: %s\n", strerror(errno), path);
} else {
fprintf(stderr,
"[inifile] %s [L%d]: %s\n",
nc_ini_error(r),
error_line,
path);
}
return NULL;
}
return ret;
}
int nc_ini_file_parse_full(const char *path, NcHashmap **out_map, int *error_line_number)
{
autofree(FILE) *file = NULL;
char *buf = NULL;
ssize_t r = 0;
size_t sn = 0;
int line_count = 1;
char *current_section = NULL;
NcHashmap *root_map = NULL;
NcHashmap *section_map = NULL;
bool failed = false;
int err_ret = 0;
file = fopen(path, "r");
if (!file) {
return -(NC_INI_ERROR_FILE);
}
if (!out_map) {
fprintf(stderr, "nc_ini_file_parse_full(): NcHashmap pointer invalid\n");
return -1;
}
root_map = nc_hashmap_new_full(nc_string_hash,
nc_string_compare,
free,
(nc_hash_free_func)nc_hashmap_free);
while ((r = getline(&buf, &sn, file)) != -1) {
char *ch = NULL;
size_t str_len = r;
/* Fix newline */
if (buf[r - 1] == '\n') {
buf[r - 1] = '\0';
--r;
}
str_len = r;
buf = string_strip(buf, r, &str_len);
/* Empty lines are fine */
if (streq(buf, "")) {
goto next;
}
if (buf[0] == '[') {
/* Validate section start */
if (buf[str_len - 1] != ']') {
/* Throw error */
err_ret = NC_INI_ERROR_NOT_CLOSED;
goto fail;
}
/* Grab the section name, and "close" last section */
buf[str_len - 1] = '\0';
if (current_section) {
free(current_section);
}
current_section = strdup(buf + 1);
section_map = nc_hashmap_get(root_map, current_section);
if (!section_map) {
/* Create a new section dynamically */
section_map = nc_hashmap_new_full(nc_string_hash,
nc_string_compare,
free,
free);
nc_hashmap_put(root_map, strdup(current_section), section_map);
}
goto next;
} else if (buf[0] == '#' || buf[0] == ';') {
/* Skip comment */
goto next;
}
/* Look for key = value */
ch = strchr(buf, '=');
if (!ch) {
/* Throw error */
err_ret = NC_INI_ERROR_INVALID_LINE;
goto fail;
}
/* Can't have sectionless k->v */
if (!current_section) {
err_ret = NC_INI_ERROR_NO_SECTION;
goto fail;
}
int offset = ch - buf;
/* Grab the key->value from this assignment line */
char *value = strdup((buf + offset) + 1);
buf[offset] = '\0';
char *key = strdup(buf);
key = string_chew_terminated(key);
value = string_chew_terminated(value);
if (streq(key, "")) {
err_ret = NC_INI_ERROR_EMPTY_KEY;
free(key);
free(value);
goto fail;
}
/* Ensure a section mapping exists */
section_map = nc_hashmap_get(root_map, current_section);
if (!section_map) {
err_ret = 1;
fprintf(stderr,
"[inifile] Fatal! No section map for named "
"section: %s\n",
current_section);
abort();
}
/* Insert these guys into the map */
if (!nc_hashmap_put(section_map, key, value)) {
err_ret = 1;
fprintf(stderr, "[inifile] Fatal! Out of memory\n");
abort();
}
/* Progression + cleanup */
next:
if (buf) {
free(buf);
buf = NULL;
}
++line_count;
sn = 0;
continue;
/* Parsing error, bail */
fail:
failed = true;
if (error_line_number) {
*error_line_number = line_count;
}
break;
}
if (buf) {
free(buf);
buf = NULL;
}
if (current_section) {
free(current_section);
current_section = NULL;
}
if (failed) {
if (root_map) {
nc_hashmap_free(root_map);
}
return -(err_ret);
}
*out_map = root_map;
return 0;
}
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
-111
View File
@@ -1,111 +0,0 @@
/*
* This file is part of libnica.
*
* Copyright (C) 2016 Intel Corporation
*
* libnica is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#pragma once
#include "hashmap.h"
#include "util.h"
/**
* The Nica INI Parser focuses on simplicity and ease of use, therefore it
* currently only supports a read-only parse operation.
*
* The parse functions are used to return a _root_ @NcHashmap which contains
* name to section mappings. Each section is in turn an @NcHashmap with string
* to string mappings.
*
* Consider the following example:
*
* [Person]
* alive = true
* ; This person is alive
*
* The returned @NcHashmap will contain the key "Person", which corresponds to
* another @NcHashmap. This @NcHashmap will contain the key "alive", which has
* the value "true". Therefore we can access this variable using the @NcHashmap
* API:
*
* char *alive = nc_hashmap_get(nc_hashmap_get(ini, "Person"), "alive");
*
* Conversely, we can use the API to determine whether a section or key is set:
*
* if (nc_hashmap_contains(ini, "Person"))
*
* As @NcHashmap returns NULL in nc_hashmap_get, you can happily pass NULL
* keys, allowing quick key fetches without checking if the section exists.
*
* In our INI file, lines beginning with ";" or "#" are considered as comments
* and are not processed. A line following the "key = value" notation is an
* _assignment_. "[Section]" is considered to be a section in the INI file, and
* all INI files must have at least one section.
*
* We do allow duplication section definitions, by following a merge policy. If
* a key is redefined then the original key->value mapping is freed and the new
* key->value mapping is inserted.
*
* The parser will return a correctly configured @NcHashmap, the only cleanup
* required is to call nc_hashmap_free on it. Alternatively, use the autofree
* helper, for a RAII approach:
*
* autofree(NcHashmap) *map = nc_ini_file_parse("myfile.ini");
*/
/**
* Errors that are reported when parsing an ini file
*/
typedef enum {
NC_INI_ERROR_MIN = 0,
NC_INI_ERROR_FILE, /**< File based error, check strerror(errno) */
NC_INI_ERROR_EMPTY_KEY, /**< Empty key in an assignment line */
NC_INI_ERROR_NOT_CLOSED, /**< Encountered section start that wasn't closed with a ']' */
NC_INI_ERROR_NO_SECTION, /**< Key assignment with no defined sections */
NC_INI_ERROR_INVALID_LINE, /**< Encountered an invalid line (syntax) */
NC_INI_ERROR_MAX
} NcIniError;
/**
* Convenience wrapper for nc_ini_file_parse_full, reports errors to stderrr
* and returns an NcHashmap if the parsing succeeded
*/
NcHashmap *nc_ini_file_parse(const char *path);
/**
* Parse an INI file into a hash of hashes.
*
* @param path Path on the filesystem to parse, must be in INI syntax.
* @param out_map Pointer to store the resulting root NcHashmap in
* @param error_line_number If not null, then the erronous line number is
* stored.
*
* @return 0 if the call was succesful, or a negative integer. See nc_ini_error
*/
int nc_ini_file_parse_full(const char *path, NcHashmap **out_map, int *error_line_number);
/**
* Return a string representation for a given @NcIniError
*
* @param error Valid NcIniError code
* @return a static string owned by the implementation
*/
const char *nc_ini_error(NcIniError error);
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
-53
View File
@@ -1,53 +0,0 @@
/*
* This file is part of libnica.
*
* Copyright (C) 2016 Intel Corporation
*
* libnica is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#pragma once
#define _GNU_SOURCE
#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#define DEF_AUTOFREE(N, C) \
static inline void _autofree_func_##N(void *p) \
{ \
if (p && *(N **)p) { \
C(*(N **)p); \
(*(void **)p) = NULL; \
} \
}
#define autofree(N) __attribute__((cleanup(_autofree_func_##N))) N
/**
* Dump any leaked file descriptors
*/
void nc_dump_file_descriptor_leaks(void);
#define streq(x, y) strcmp(x, y) == 0 ? true : false
DEF_AUTOFREE(char, free)
DEF_AUTOFREE(FILE, fclose)
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+390
View File
@@ -0,0 +1,390 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2016-2018 Ikey Doherty <ikey@solus-project.com>
* Copyright © 2018-2019 Intel Corporation
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#define _GNU_SOURCE
#include <dlfcn.h>
#include <libgen.h>
#include <stdarg.h>
#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "config.h"
/* Expose getpwuid override in snapd */
#ifdef HAVE_SNAPD_SUPPORT
#include <pwd.h>
#endif
#include "../common/common.h"
#include "../common/files.h"
#include "../common/log.h"
#include "nica/util.h"
#include "private.h"
#include "profile.h"
#include "redirect.h"
#define _STRINGIFY(x) #x
#define SYMBOL_BINDING(l, x) \
{ \
.handle = &lsi_table.handles.l, .name = _STRINGIFY(x), \
.func = (void **)(&lsi_table.x), .func_size = sizeof(lsi_table.x) \
}
/**
* Whether we've initialised yet or not.
*/
static volatile bool lsi_init = false;
/**
* Whether we should actually perform overrides
* This is determined by the process name
*/
static volatile bool lsi_override = false;
/**
* Known profiles
*/
static lsi_profile_generator_func generators[] = {
&lsi_redirect_profile_new_ark,
&lsi_redirect_profile_new_project_highrise,
};
/**
* Easy mapping to make it quick and easy to add new function overrides
*/
typedef struct LsiSymbolBinding {
void **handle;
char *name;
void **func;
size_t func_size;
} LsiSymbolBinding;
/**
* Our redirect instance, stack only.
*/
static LsiRedirectTable lsi_table = { 0 };
/**
* Contains all of our replacement rules.
*/
static LsiRedirectProfile *lsi_profile = NULL;
/**
* Our current set of libc bindings. This sets up the LsiRedirectTable with
* all of our needed dlsym() functions from libc.so.6.
*/
static LsiSymbolBinding lsi_libc_bindings[] = {
SYMBOL_BINDING(libc, open),
SYMBOL_BINDING(libc, fopen64),
#ifdef HAVE_SNAPD_SUPPORT
SYMBOL_BINDING(libc, getpwuid),
#endif
};
/**
* We'll only perform teardown code if the process doesn't `abort()` or `_exit()`
*/
__attribute__((destructor)) static void lsi_redirect_shutdown(void)
{
if (lsi_profile) {
lsi_redirect_profile_free(lsi_profile);
lsi_profile = NULL;
}
if (!lsi_init) {
return;
}
lsi_init = false;
lsi_unity_cleanup(&lsi_table);
if (lsi_table.handles.libc) {
dlclose(lsi_table.handles.libc);
lsi_table.handles.libc = NULL;
}
}
/**
* Internal helper to perform the symbol binding
*/
static bool lsi_redirect_bind_function(void *handle, const char *name, void **out_func,
size_t func_size)
{
void *symbol_lookup = NULL;
char *dl_error = NULL;
/* Safely look up the symbol */
symbol_lookup = dlsym(handle, name);
dl_error = dlerror();
if (dl_error || !symbol_lookup) {
fprintf(stderr, "Failed to bind '%s': %s\n", name, dl_error);
return false;
}
/* Have the symbol correctly, copy it to make it usable */
memcpy(out_func, &symbol_lookup, func_size);
return true;
}
/**
* Responsible for setting up the vfunc redirect table so that we're able to
* get `open` and such working before we've hit the constructor, and ensure
* we only init once.
*/
static void lsi_redirect_init_tables(void)
{
if (lsi_init) {
return;
}
lsi_init = true;
/* Try to explicitly open libc. We can't safely rely on RTLD_NEXT
* as we might be dealing with a strange link order
*/
lsi_table.handles.libc = dlopen("libc.so.6", RTLD_LAZY);
if (!lsi_table.handles.libc) {
fprintf(stderr, "Unable to grab libc.so.6 handle: %s\n", dlerror());
goto failed;
}
/* Hook up all necessary symbol binding */
for (size_t i = 0; i < ARRAY_SIZE(lsi_libc_bindings); i++) {
LsiSymbolBinding *binding = &lsi_libc_bindings[i];
if (!lsi_redirect_bind_function(*(binding->handle),
binding->name,
binding->func,
binding->func_size)) {
goto failed;
}
}
/* We might not get an unload, so chain onto atexit */
atexit(lsi_redirect_shutdown);
return;
failed:
/* Pretty damn fatal. */
lsi_redirect_shutdown();
abort();
}
/**
* Main entry point into this redirect module.
*
* We'll check the process name and determine if we're interested in installing
* some redirect hooks into this library.
* Otherwise we'll continue to operate in a pass-through mode
*/
__attribute__((constructor)) static void lsi_redirect_init(void)
{
/* Ensure we're open. */
lsi_redirect_init_tables();
autofree(char) *process_name = NULL;
char **paths = NULL;
char **orig = NULL;
/* Absolute path to the process for fine-grained matching */
process_name = lsi_get_process_name();
if (!process_name) {
fputs("Out of memory!\n", stderr);
return;
}
lsi_unity_startup(&lsi_table);
/* Grab the steam installation directories */
orig = paths = lsi_get_steam_paths();
/* For each path try to form a valid profile for the process name and Steam directory */
while (*paths) {
for (size_t i = 0; i < ARRAY_SIZE(generators); i++) {
lsi_profile = generators[i](process_name, *paths);
if (lsi_profile) {
goto use_profile;
}
}
++paths;
}
use_profile:
/* Rewind path set */
paths = orig;
if (!lsi_profile) {
goto clean_array;
}
lsi_override = true;
lsi_log_debug("Enable lsi_redirect for '%s'", lsi_profile->name);
clean_array:
/* Free them again */
if (paths) {
while (*paths) {
free(*paths);
++paths;
}
free(orig);
}
}
/**
* Get a redirect path from the table if it exists, otherwise return NULL
*/
static char *lsi_get_redirect_path(const char *syscall_id, LsiRedirectOperation op, const char *p)
{
autofree(char) *path = NULL;
LsiRedirect *redirect = NULL;
/* Get the absolute path here */
path = realpath(p, NULL);
if (!path) {
return NULL;
}
/* find a valid replacement */
for (redirect = lsi_profile->op_table[op]; redirect; redirect = redirect->next) {
/* Currently we only known path replacements */
if (redirect->type != LSI_REDIRECT_PATH) {
continue;
}
if (strcmp(redirect->path_source, path) != 0) {
continue;
}
if (!lsi_file_exists(redirect->path_target)) {
lsi_log_warn("Replacement path does not exist: %s", redirect->path_target);
return NULL;
}
lsi_log_info("%s(): Replaced '%s' with '%s'",
syscall_id,
path,
redirect->path_target);
return strdup(redirect->path_target);
}
/* Got nothin' */
return NULL;
}
_nica_public_ int open(const char *p, int flags, ...)
{
va_list va;
mode_t mode;
LsiRedirectOperation op = LSI_OPERATION_OPEN;
autofree(char) *replacement = NULL;
/* Must ensure we're **really** initialised, as we might see open happen
* before the constructor..
*/
lsi_redirect_init_tables();
/* Grab the mode_t */
va_start(va, flags);
mode = va_arg(va, mode_t);
va_end(va);
lsi_maybe_init_unity3d(&lsi_table, p);
/* Not interested in this guy apparently */
if (!lsi_override) {
goto fallback_open;
}
replacement = lsi_get_redirect_path("open", op, p);
if (replacement) {
return lsi_table.open(replacement, flags, mode);
}
fallback_open:
return lsi_table.open(p, flags, mode);
}
_nica_public_ FILE *fopen64(const char *p, const char *modes)
{
LsiRedirectOperation op = LSI_OPERATION_OPEN;
autofree(char) *replacement = NULL;
/* Must ensure we're **really** initialised, as we might see open happen
* before the constructor..
*/
lsi_redirect_init_tables();
lsi_maybe_init_unity3d(&lsi_table, p);
/* Not interested in this guy apparently */
if (!lsi_override) {
goto fallback_open;
}
replacement = lsi_get_redirect_path("fopen64", op, p);
if (replacement) {
return lsi_table.fopen64(replacement, modes);
}
fallback_open:
if (is_unity3d_prefs_file(&lsi_table, p)) {
return lsi_unity_redirect(&lsi_table, p, modes);
}
return lsi_table.fopen64(p, modes);
}
#ifdef HAVE_SNAPD_SUPPORT
#include <unistd.h>
_nica_public_ struct passwd *getpwuid(uid_t uid)
{
/* Must ensure we're **really** initialised, as we might see open happen
* before the constructor..
*/
lsi_redirect_init_tables();
struct passwd *ret = NULL;
const char *snap_root = getenv("SNAP_USER_COMMON");
/* If they're requesting our uid and SNAP_USER_COMMON is set, then
* let us override the home directory to be correct.
*/
ret = lsi_table.getpwuid(uid);
if (!ret) {
return NULL;
}
if (uid == getuid() && snap_root && *snap_root) {
ret->pw_dir = (char *)snap_root;
}
return ret;
}
#endif
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+32
View File
@@ -0,0 +1,32 @@
# Only build libredirect if told to!
if with_libredirect == true
# Might not need libdl for alt libcs
libdl = meson.get_compiler('c').find_library('dl', required : false)
librt = meson.get_compiler('c').find_library('rt', required : false)
redirect_sources = [
'main.c',
'profile.c',
'profiles/ark.c',
'profiles/project_highrise.c',
'unity.c',
]
sym_map = join_paths(meson.current_source_dir(), 'sym.map')
main_redirect = shared_library(
'lsi-redirect',
sources: redirect_sources,
c_args: ['-fvisibility=hidden'],
link_args: ['-Wl,--version-script=@0@'.format(sym_map)],
include_directories: nica_includes,
dependencies: [
libdl,
librt,
link_lsi_common,
],
install: true,
)
endif
+83
View File
@@ -0,0 +1,83 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2017 Ikey Doherty <ikey@solus-project.com>
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#pragma once
#include <stdbool.h>
#include <stdio.h>
#include "config.h"
#ifdef HAVE_SNAPD_SUPPORT
#include <pwd.h>
#endif
/**
* Handle definitions
*/
typedef int (*lsi_open_file)(const char *p, int flags, mode_t mode);
typedef FILE *(*lsi_fopen64_file)(const char *p, const char *modes);
#ifdef HAVE_SNAPD_SUPPORT
typedef struct passwd *(*lsi_getpwuid)(uid_t uid);
#endif
/**
* Global storage of handles for nicer organisation.
*/
typedef struct LsiRedirectTable {
lsi_open_file open;
lsi_fopen64_file fopen64;
#ifdef HAVE_SNAPD_SUPPORT
lsi_getpwuid getpwuid;
#endif
/* Allow future handle opens.. */
struct {
void *libc;
} handles;
/* Our shm_open() unity3d redirect.. */
struct {
char *original_config_path;
char *config_path;
char *shm_path;
bool enabled;
bool failed;
bool had_init;
} unity3d;
} LsiRedirectTable;
void lsi_unity_startup(LsiRedirectTable *lsi_table);
void lsi_unity_cleanup(LsiRedirectTable *lsi_table);
/* API Definitions for Unity handlers */
void lsi_maybe_init_unity3d(LsiRedirectTable *lsi_table, const char *p);
void lsi_unity_backup_config(LsiRedirectTable *lsi_table);
FILE *lsi_unity_redirect(LsiRedirectTable *lsi_table, const char *p, const char *modes);
FILE *lsi_unity_get_config_file(LsiRedirectTable *lsi_table, const char *modes);
void lsi_unity_trim_copy_config(FILE *from, FILE *to);
bool is_unity3d_prefs_file(LsiRedirectTable *lsi_table, const char *p);
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+131
View File
@@ -0,0 +1,131 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2016-2018 Ikey Doherty <ikey@solus-project.com>
* Copyright © 2018-2019 Intel Corporation
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#define _GNU_SOURCE
#include <stdlib.h>
#include <string.h>
#include "../common/log.h"
#include "redirect.h"
LsiRedirectProfile *lsi_redirect_profile_new(const char *name)
{
LsiRedirectProfile p = { .name = strdup(name), { 0 } };
LsiRedirectProfile *ret = NULL;
if (!p.name) {
return NULL;
}
ret = calloc(1, sizeof(LsiRedirectProfile));
if (!ret) {
return NULL;
}
*ret = p;
return ret;
}
void lsi_redirect_profile_free(LsiRedirectProfile *self)
{
if (!self) {
return;
}
/* Free all chains */
for (unsigned int i = 0; i < LSI_NUM_OPERATIONS; i++) {
LsiRedirect *r = self->op_table[i];
if (!r) {
continue;
}
lsi_redirect_free(r);
}
free(self->name);
free(self);
}
void lsi_redirect_profile_insert_rule(LsiRedirectProfile *self, LsiRedirect *redirect)
{
LsiRedirectOperation op;
switch (redirect->type) {
case LSI_REDIRECT_PATH:
op = LSI_OPERATION_OPEN;
break;
default:
lsi_log_error("Attempted insert of unknown rule into '%s'", self->name);
lsi_redirect_free(redirect);
return;
}
/* Set head or prepend the rule */
if (self->op_table[op]) {
redirect->next = self->op_table[op];
self->op_table[op] = redirect;
} else {
self->op_table[op] = redirect;
}
}
LsiRedirect *lsi_redirect_new_path_replacement(const char *source_path, const char *target_path)
{
LsiRedirect *ret = NULL;
ret = calloc(1, sizeof(LsiRedirect));
if (!ret) {
return NULL;
}
ret->type = LSI_REDIRECT_PATH;
ret->path_source = realpath(source_path, NULL);
ret->path_target = realpath(target_path, NULL);
if (!ret->path_source || !ret->path_target) {
lsi_redirect_free(ret);
return NULL;
}
return ret;
}
void lsi_redirect_free(LsiRedirect *self)
{
if (!self) {
return;
}
/* Pass it along */
if (self->next) {
lsi_redirect_free(self->next);
}
switch (self->type) {
case LSI_REDIRECT_PATH:
default:
free(self->path_source);
free(self->path_target);
break;
}
free(self);
}
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+46
View File
@@ -0,0 +1,46 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2017 Ikey Doherty <ikey@solus-project.com>
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#pragma once
#include <stdbool.h>
#include <stdlib.h>
#include "redirect.h"
/**
* Generator function is used to attempt creation of profiles based on the
* steam directory
*/
typedef LsiRedirectProfile *(*lsi_profile_generator_func)(char *process_name, char *steam_root);
/**
* Profile generator for Ark survival evolved
*/
LsiRedirectProfile *lsi_redirect_profile_new_ark(char *process_name, char *steam_root);
/**
* Profile generator for Project Highrise
*/
LsiRedirectProfile *lsi_redirect_profile_new_project_highrise(char *process_name, char *steam_root);
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+107
View File
@@ -0,0 +1,107 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2016-2018 Ikey Doherty <ikey@solus-project.com>
* Copyright © 2018-2019 Intel Corporation
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
#include "../common/log.h"
#include "nica/util.h"
#include "profile.h"
#include "redirect.h"
#define ARK_BASE "steamapps/common/ARK/ShooterGame"
#define ARK_CONTENT ARK_BASE "/Content"
#define ARK_BINARY ARK_BASE "/Binaries/Linux/ShooterGame"
/**
* This generator function is responsible for supporting ARK: Survival Evolved
*
* Simply it redirects the executable to open the correct asset when TheCenter
* DLC is installed.
*/
LsiRedirectProfile *lsi_redirect_profile_new_ark(char *process_name, char *steam_path)
{
LsiRedirectProfile *p = NULL;
LsiRedirect *redirect = NULL;
autofree(char) *mic_source = NULL;
autofree(char) *mic_target = NULL;
autofree(char) *match_process = NULL;
autofree(char) *test_process = NULL;
if (asprintf(&match_process, "%s/%s", steam_path, ARK_BINARY) < 0) {
return NULL;
}
/* Check it even exists */
test_process = realpath(match_process, NULL);
if (!test_process) {
return NULL;
}
/* Check the process name now */
if (strcmp(test_process, process_name) != 0) {
return NULL;
}
static const char *def_mic_source =
ARK_CONTENT "/PrimalEarth/Environment/Water/Water_DepthBlur_MIC.uasset";
static const char *def_mic_target =
ARK_CONTENT "/Mods/TheCenter/Assets/Mic/Water_DepthBlur_MIC.uasset";
p = lsi_redirect_profile_new("ARK: Survival Evolved");
if (!p) {
fputs("OUT OF MEMORY\n", stderr);
return NULL;
}
if (asprintf(&mic_source, "%s/%s", steam_path, def_mic_source) < 0) {
goto failed;
}
if (asprintf(&mic_target, "%s/%s", steam_path, def_mic_target) < 0) {
goto failed;
}
/* Don't add a redirect if the paths don't exist. */
redirect = lsi_redirect_new_path_replacement(mic_source, mic_target);
if (!redirect) {
goto unused;
}
/* We're in, set our log ID now */
lsi_log_set_id("ARK");
lsi_redirect_profile_insert_rule(p, redirect);
return p;
failed:
/* Dead in the water.. */
fputs("OUT OF MEMORY\n", stderr);
unused:
lsi_redirect_profile_free(p);
return NULL;
}
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+118
View File
@@ -0,0 +1,118 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2016-2018 Ikey Doherty <ikey@solus-project.com>
* Copyright © 2018-2019 Intel Corporation
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#define _GNU_SOURCE
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include "../common/files.h"
#include "../common/log.h"
#include "nica/util.h"
#include "profile.h"
#include "redirect.h"
#define PHR_PREF_DIR "unity3d/SomaSim/Project Highrise/prefs"
#define PHR_PREF_FILE "unity3d/SomaSim/Project Highrise/prefs/prefs.txt"
#if UINTPTR_MAX == 0xffffffffffffffff
#define PHR_BINARY "steamapps/common/Project Highrise/Game.x86_64"
#else
#define PHR_BINARY "steamapps/common/Project Highrise/Game.x86"
#endif
/**
* This generator function is responsible for supporting: Project Highrise
*
* Currently a bug exists in Projec Highrise, where on the second launch, i.e.
* preferences tree exists, it will try to load/map the preferences directory
* as a file, and fails to use the correct *file path*
*
* This is a temporary workaround and we'll let them know what we found.
*/
LsiRedirectProfile *lsi_redirect_profile_new_project_highrise(char *process_name, char *steam_path)
{
LsiRedirectProfile *p = NULL;
LsiRedirect *redirect = NULL;
autofree(char) *p_source = NULL;
autofree(char) *p_target = NULL;
autofree(char) *match_process = NULL;
autofree(char) *test_process = NULL;
autofree(char) *config_dir = NULL;
if (asprintf(&match_process, "%s/%s", steam_path, PHR_BINARY) < 0) {
return NULL;
}
/* Check it even exists */
test_process = realpath(match_process, NULL);
if (!test_process) {
return NULL;
}
/* Check the process name now */
if (strcmp(test_process, process_name) != 0) {
return NULL;
}
config_dir = lsi_get_user_config_dir();
if (!config_dir) {
return NULL;
}
p = lsi_redirect_profile_new("Project Highrise");
if (!p) {
fputs("OUT OF MEMORY\n", stderr);
return NULL;
}
if (asprintf(&p_source, "%s/%s", config_dir, PHR_PREF_DIR) < 0) {
goto failed;
}
if (asprintf(&p_target, "%s/%s", config_dir, PHR_PREF_FILE) < 0) {
goto failed;
}
/* Don't add a redirect if the paths don't exist. */
redirect = lsi_redirect_new_path_replacement(p_source, p_target);
if (!redirect) {
goto unused;
}
/* We're in, set our log ID now */
lsi_log_set_id("ProjectHighrise");
lsi_redirect_profile_insert_rule(p, redirect);
return p;
failed:
/* Dead in the water.. */
fputs("OUT OF MEMORY\n", stderr);
unused:
lsi_redirect_profile_free(p);
return NULL;
}
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+106
View File
@@ -0,0 +1,106 @@
/*
* This file is part of linux-steam-integration.
*
* Copyright © 2017 Ikey Doherty <ikey@solus-project.com>
*
* linux-steam-integration is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1
* of the License, or (at your option) any later version.
*/
#pragma once
#include <stdbool.h>
#include <stdlib.h>
/**
* The type of redirect required
*/
typedef enum {
LSI_REDIRECT_MIN = 1,
LSI_REDIRECT_PATH,
} LsiRedirectType;
/**
* LsiRedirect describes the configuration required for each operation.
*/
typedef struct LsiRedirect {
LsiRedirectType type;
union {
/* Path replacement */
struct {
char *path_source;
char *path_target;
};
};
struct LsiRedirect *next;
} LsiRedirect;
/**
* LsiRedirectOperation specifies the syscall we're intended for.
*/
typedef enum { LSI_OPERATION_OPEN = 0, LSI_NUM_OPERATIONS } LsiRedirectOperation;
/**
* We build an LsiRedirectProfile to match the current process.
* It contains a table of LsiRedirect members corresponding to a given
* op, i.e:
*
* op_table[LSI_OPERATION_OPEN]
*/
typedef struct LsiRedirectProfile {
char *name; /**< Name for this profile */
LsiRedirect *op_table[LSI_NUM_OPERATIONS]; /* vtable information */
} LsiRedirectProfile;
/**
* Construct a new LsiRedirectProfile
*
* @param name Profile name
* @returns A newly allocated LsiRedirectProfile
*/
LsiRedirectProfile *lsi_redirect_profile_new(const char *name);
/**
* Free a previously allocated LsiRedirectProfile
*
* @param profile Pointer to an allocated LsiRedirectProfile
*/
void lsi_redirect_profile_free(LsiRedirectProfile *profile);
/**
* Attempt insert of a redirect rule into this profile
*
* @param profile Pointer to a valid LsiRedirectProfile
* @param redirect Pointer to an allocated LsiRedirect
*/
void lsi_redirect_profile_insert_rule(LsiRedirectProfile *self, LsiRedirect *redirect);
/* LsiRedirect APIs follow */
/**
* Construct a new LsiRedirect to perform path replacements
*/
LsiRedirect *lsi_redirect_new_path_replacement(const char *source_path, const char *target_path);
/**
* Attempt to free this redirect
*
* @param redirect Pointer to allocated LsiRedirect
*/
void lsi_redirect_free(LsiRedirect *self);
/*
* Editor modelines - https://www.wireshark.org/tools/modelines.html
*
* Local variables:
* c-basic-offset: 8
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* vi: set shiftwidth=8 tabstop=8 expandtab:
* :indentSize=8:tabSize=8:noTabs=true:
*/
+8
View File
@@ -0,0 +1,8 @@
{
global:
fopen64;
getpwuid;
open;
local:
*;
};

Some files were not shown because too many files have changed in this diff Show More