ValveSoftware / voglperf

Benchmarking tool for Linux OpenGL games. Spews frame information, logs frametimes.
Other
201 stars 31 forks source link

Add debian packaging #28

Closed mdeguzis closed 8 years ago

mdeguzis commented 8 years ago

Tested on latest OS beta, client beta. This repository doesn't seem to be updated anymore, but if anyone sees this, let me know if any corrections are needed.

I should add, I still have issues showing fps stats though:

> game stop
> game start

ERROR: Could not retrieve pid of launched game.

ERROR: Game not running.

GameID: 38740 (gameid38740)

LD_PRELOAD=./libvoglperf32.so:./libvoglperf64.so:$LD_PRELOAD

VOGLPERF_CMD_LINE="--msqid=0  --showfps"

Steam url string:
  steam steam://run/38740//VOGLPERF_CMD_LINE="--msqid=0  --showfps" LD_PRELOAD=./libvoglperf32.so:./libvoglperf64.so:$LD_PRELOAD %command%

Launch string:
  steam steam://run/38740//VOGLPERF_CMD_LINE%3d%22--msqid%3d0%20%20--showfps%22%20LD_PRELOAD%3d.%2flibvoglperf32.so%3a.%2flibvoglperf64.so%3a%24LD_PRELOAD%20%25command%25

Waiting for child process to start...

Running Steam on steamos 2.0 64-bit
STEAM_RUNTIME is enabled automatically

> fpsshow on
> fpsprint on

ERROR: Could not retrieve pid of launched game.

fpsshow: On

fpsprint: On
kingtaurus commented 8 years ago

(1) Couple of issues: debian/changelog is not of the correct format; You should probably use: dch --create -v 1.0 --package voglperf

(2) steamos-dev probably shouldn't be added as dependency. Since this I want to be able to build this in any ubuntu, debian and steam-os without modification.

(3) There needs to be changes to the CMakeLists.txt (so that you use system packages instead of the ones that are in the repository).

(4) Due to a bug in Ubuntu dev library location the build_options.cmake (causes a linking issue when trying to build the i386 library); In addition the build dependencies listed are not complete for both i386 and amd64 builds. [So this will not build on my Ubuntu 15.10 amd64 machine]

mdeguzis commented 8 years ago

Ok, ill reassess the approach I took and see what I can do about these issues. Thanks.

mdeguzis commented 8 years ago

@kingtaurus

  1. fixed, just a misstep in not uploading mine
  2. fixed, integrated requested packages in meta-package
  3. Any idea what part of the cmake documentation would help explain this? Guess I have some studying to do. I get what you mean now, with linking libGL in the repository vs . the actual package library. I am testing an integrating your excellent changes as well.
  4. I'll set up a VM and look at this soon.
kingtaurus commented 8 years ago

(1) Although this is just a starting point: changelog best practices. (2) What are you using for building the package (since there is more than one way to build a debian package, debuild, dpkg-buildpackage, pbuilder)? (3) Its probably best to just use the machine arch to build the package and not worry about building the i386 package from an amd64 environment (it just makes it simpler).

mdeguzis commented 8 years ago

I have a fork here with working preliminary packaging. See the reddit announcement here. I need to sort through some things. I am using clean room pbuilder packaging methods. On point 3, it actually works to make the 32 bit and 64 bit librariy/runtime binary in the same package. Doing this based on ARCH would not be ideal. I did that approach for an experimental libframetime (similar utility), as there were issues in their current Makefile/code (at least it seemed). I mean, I suppose I could make a voglperf32 and voglperf64 package, but this works just fine it seems. I also modified the run paths for the libs to be /usr/lib and the runtime binaries to be /usr/bin

kingtaurus commented 8 years ago

I'll give this a test run (hopefully soon); Although it appears that Valve haven't been paying attention to a few of the tools that they open sourced - you should still create a pull request :) . What is the currently recommended commit to pull?

kingtaurus commented 8 years ago

@ProfessorKaos64 You should also have a list of packages necessary to build the debian packages (as well as include commands to build the debian package).

mdeguzis commented 8 years ago

Yes, I need to, but i need to sort out what's really required from the dev package in the runtime deps too. I could list the build deps at least regardless. That mesa run time dev package should not be 100% needed, but covers the bases for the game to launch fine, other wise it crashes back to Steam.

kingtaurus commented 8 years ago

@ProfessorKaos64 There are some build issues with Ubuntu 14.04 LTS (due a conflict between libbsd for the two arches specified - AMD64 and i386). This is related to something I documented earlier ( Issue #22). Trying with ubuntu 15.10.

EDIT: improved description of the problem.

mdeguzis commented 8 years ago

I'll modify the build-deps and test with your set in #22. Not a problem.

kingtaurus commented 8 years ago

Not saying you have to modified the build-deps (just saying that it doesn't work out of the box with Ubuntu 14.04). Just wanted to document the problem. In addition I'd rather move towards using Ubuntu 15.10 or 16.04 LTS as a build target.

mdeguzis commented 8 years ago

I will document that on my readme tonight. To be honest, if you want to fork or submit me PRs to improve it a bit, I don't mind. I'm a technical person, but not a c/cpp dev. I'm glad I was able to segment the runtime binary and lib paths. I just maintained my own to package it. Is 15.10 or 16.04 LTS confirmed working for you?

On May 2, 2016 3:07:06 PM EDT, Gregory King notifications@github.com wrote:

Not saying you have to modified the build-deps (just saying that it doesn't work out of the box with Ubuntu 14.04). Just wanted to document the problem. In addition I'd rather move towards using Ubuntu 15.10 or 16.04 LTS as a build target.


You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub: https://github.com/ValveSoftware/voglperf/pull/28#issuecomment-216331087

Sent from my Android device with K-9 Mail. Please excuse my brevity.

kingtaurus commented 8 years ago

@ProfessorKaos64 Builds work in 15.10 and 16.04; With all dependencies installed; I use the following commands (one to extract the archive, and the other to build the package);

git archive --format=tar.gz -o ../voglperf_0.3+git+bsos.orig.tar.gz HEAD
debuild -us -uc
mdeguzis commented 8 years ago

Ok good. I'll at least note this release as marker since it builds on Debian 8 / SteamOS / Ubuntu 15.10 and 16.04. I'll shape up the readme a bit for now as well.