How to compile libpng16 for SteamOS using CMake?

206 views Asked by At

For Ubuntu, I successfully compiled my game using CMake. Now I would like to run it on SteamOS as well, as I am publishing on Steam (SteamOS + Linux).

I am using libpng16, but SteamOS 2 is based on Debian 8 Jessie, which uses libpng12. I believe that it does not support libpng16 yet. And I don't believe the latest version of Ubuntu still includes libpng12.

How do I compile a single build for both platforms?

Some sample code (if useful):

...

find_package(PNG REQUIRED)

...

include_directories(
    ...
    ${PNG_INCLUDE_DIR}
)

...

target_link_libraries( ${PROJECT_NAME}
    ...
    ${PNG_LIBRARY}
)
0

There are 0 answers