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

Update Makefile #95

Merged
merged 1 commit into from
Jul 12, 2018
Merged

Update Makefile #95

merged 1 commit into from
Jul 12, 2018

Conversation

blshkv
Copy link
Contributor

@blshkv blshkv commented Jul 11, 2018

fixing the issue #52

@dpayne
Copy link
Owner

dpayne commented Jul 11, 2018

Instead of the mkdir, could you put a check to see if it exists and then error out if it doesn?

@blshkv
Copy link
Contributor Author

blshkv commented Jul 11, 2018

That is taken cared automatically by -p parameter

@dpayne
Copy link
Owner

dpayne commented Jul 11, 2018

It's more that I didn't want the install script making an important directory like /usr/local/bin/ without the user knowing very explicitly. It can potentially create a directory with odd permissions. It seems better to fail loudly and force the user to think about what they are doing before making the directory.

@blshkv
Copy link
Contributor Author

blshkv commented Jul 11, 2018

The purpose of this PR is to fix the DESTDIR variable and ability to compile the tool in a sandbox env where there are NO directories at all. So you HAVE to create it or make DESTDIR=/var/tmp install WILL fail.

Feel free to add your other ideas in a different PR, this is not related to this problem. I also disagree with your idea. A regular user will not be able to create a system directory. If a user decided to run "sudo make install" this is not your responsibility to check the integrity and hardening (umask and so on) of his system. it is common that this command will install into /usr/local/bin and it is known that one need to change prefix if needed.

I also do not like static Makefile concept. It's better to use a proper autotools (automake) or cmake tools which are specifically design to check all unthinkable conditions.

@dpayne dpayne merged commit 7e7ee0a into dpayne:master Jul 12, 2018
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

2 participants