Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

make paths modifiable #71

Closed
wants to merge 3 commits into from
Closed

make paths modifiable #71

wants to merge 3 commits into from

Conversation

hasufell
Copy link
Contributor

@hasufell hasufell commented Apr 3, 2012

paths are made modifiable

path_share had to be fixed too, so it get's the texture location

did I miss anything?

celeron55 and others added 3 commits April 3, 2012 01:24
make install-paths modifiable
prepend "CMAKE_INSTALL_PREFIX" to SHAREDIR for proper variable substitution
make path_share look explicitly in SHAREDIR instead of potentially-broken
relative path
@Calinou
Copy link
Member

Calinou commented Apr 8, 2012

There is "texture_path" in minetest.conf, it works fine for me.

@hasufell
Copy link
Contributor Author

hasufell commented Apr 8, 2012

The paths are still not modifiable, only the cmake prefix and that is not sufficient for some cases.

@celeron55
Copy link
Member

Can you tell those cases?

@hasufell
Copy link
Contributor Author

hasufell commented Apr 9, 2012

All cases where the binary and the data files go into a distro-specific custom location like "/usr/share/games" and "/usr/games/bin/" without system-data like "/usr/share/icons", "/usr/share/man" or "/usr/share/applications" ending up there too, because we only have the cmake-prefix and nothing else.
This prevents distributors from easily integrating minetest in some distribution environments.

minetest.conf does not help in this case unless I want to ignore the cmake install rules and write my own + mess with user-configuration which is not good practice.

@celeron55
Copy link
Member

I wonder if these patches break any existing build scripts or installations; has anyone tested?

@hasufell
Copy link
Contributor Author

It should not break, because I added
set(SHAREDIR "${CMAKE_INSTALL_PREFIX}/share/${PROJECT_NAME}" CACHE PATH "")
instead of
set(SHAREDIR "share/${PROJECT_NAME}" CACHE PATH "")
so the variable will be complete when it's passed to the preprocessor.

However I could test this on archlinux shortly...

@hasufell
Copy link
Contributor Author

I have tested this on archlinux and the resulting directory structure was exactly the same.

@celeron55
Copy link
Member

Modified and added a number of things in aef1332. It should fix this too. Can you confirm?

@hasufell
Copy link
Contributor Author

I think "CACHE PATH" is to be preferred over "CACHE STRING" here and makes a difference for people using CMake GUI, although I never tried it.

I find the CUSTOM_* stuff confusing, but yes, it works.

@celeron55
Copy link
Member

I didn't want to cache the paths generated based on ${CMAKE_INSTALL_PREFIX} - they would be a pain in the ass to regenerate without losing all other cached settings. Now you can just set the CUSTOM_* values to empty and get going with the ${CMAKE_INSTALL_PREFIX}-based defaults, without touching anything else.

The STRING vs. PATH is a good catch. Altough those are basically useless on anything else than unix-style platforms, on which nobody uses GUIs... so I'll just let them be as for now.

I consider this closed - new issues or pull requests should be made for further problems.

@celeron55 celeron55 closed this Jul 23, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants