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

git commands in source package cause (harmless) error messages #10

Closed
yuyuyak opened this issue Feb 6, 2020 · 3 comments
Closed

git commands in source package cause (harmless) error messages #10

yuyuyak opened this issue Feb 6, 2020 · 3 comments
Assignees

Comments

@yuyuyak
Copy link

yuyuyak commented Feb 6, 2020

Thank you for picking this package up, I was concerned that my beloved beep had to go after discovering the suid security issues.
I apologize for this somewhat nitpicking bug report and won't be offended if you just close it. I made a Gentoo ebuild that I may submit and all works fine with a small amount of finesse. However in the install phase it reports "FATAL: Not a git repository" (It affects nothing, but it's ugly). This is simply git giving up on the helper commands at the end of GNUmakefile, but since I am using the tar.gz package at "https://github.com/spkr-beep/beep/archive/v1.4.7.tar.gz" I don't believe these commands are relevant, shouldn't be in the package version
. I remove them with a patch and all goes well, but I believe the bug belongs here. Thanks for your time, it's working great here.

--- a/GNUmakefile	2020-02-05 19:44:22.948088696 -0800
+++ b/GNUmakefile	2020-02-05 19:47:09.293940985 -0800
@@ -34,7 +34,6 @@
 DOT = $(call pathsearch,dot)
 DOXYGEN = $(call pathsearch,doxygen)
 EGREP = $(GREP) -E
-GIT = $(call pathsearch,git)
 GREP = $(call pathsearch,grep)
 INSTALL = $(call pathsearch,install)
 MKDIR_P = mkdir -p
@@ -422,28 +421,6 @@
 	for f in $(man1_DATA);     do rm -f "$(DESTDIR)$(man1dir)/$$f";   done
 	for f in $(pkgdoc_DATA);   do rm -f "$(DESTDIR)$(pkgdocdir)/$$f"; done
 
-
-########################################################################
-# Development helpers
-########################################################################
-
-# List all references to documentation in the git repo
-.PHONY: refs
-refs:
-	$(GIT) grep -n -E '((http|https)://[a-zA-Z0-9\._/-]+|([A-Z]+\.md)|([a-zA-Z][a-zA-Z0-9_-]+\([0-9]+\)))'
-
-# List all TODOs and FIXMEs in the git repo
-.PHONY: todo fixme
-todo fixme:
-	$(GIT) grep -n -E '(TODO:|FIXME:|\\todo\s|@todo\s)'
-
-# Generate a kind of dist tarball to help with preparing for release
-PACKAGE_TARBASE := $(PACKAGE_TARNAME)-$(shell $(GIT) describe --tags | $(SED) 's/^v\([0-9]\)/\1/')
-.PHONY: dist
-dist:
-	$(GIT) archive --format=tar.gz --verbose --prefix=$(PACKAGE_TARBASE)/ --output=$(PACKAGE_TARBASE).tar.gz HEAD
-
-
 ########################################################################
 # End of GNUmakefile
 ########################################################################
@ndim
Copy link
Member

ndim commented Feb 6, 2020

Ah. Good point. I definitely need to fix that. Thanks a lot for finding and reporting that.

I should define PACKAGE_TARBASE inside the dist rule, not as a make := variable which is generated every time make is run. Alternatively, I could use a = variable instead of :=. Or fix the shell command to work in the absence of a .git directory, or even in the absence of the git utility.

Let me check this out in more detail. Expect a fix which will not call git for normal builds, with no patching required.

@ndim ndim self-assigned this Feb 6, 2020
@ndim ndim closed this as completed in afe0d29 Feb 6, 2020
@ndim
Copy link
Member

ndim commented Feb 6, 2020

If the problem persists, or if a similar problem appears, please reopen this.

Thanks again for the report. This gave me a useful impulse to think of those rules from a different angle.

@ndim
Copy link
Member

ndim commented Feb 6, 2020

@yuyuyak I have just tagged a new release beep-1.4.8 over at https://github.com/spkr-beep/beep/releases/tag/v1.4.8 for you. It should not print those error messages any more.

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

No branches or pull requests

2 participants