make install: Copy from .CURDIR
Running make install on NetBSD currently gives
cp: vis: No such file or directory
cp: vis-menu: No such file or directory
cp: vis-digraph: No such file or directory
cp: vis-clipboard: No such file or directory
cp: vis-complete: No such file or directory
cp: vis-open: No such file or directory
(I configured with --path=$HOME/sw/vis in case that matters.)
Apparently this is because BSD make (at least on NetBSD and OpenBSD) runs commands from $.OBJDIR, which defaults to ./obj if it exists, otherwise the current working directly. I don't know why this ever worked.
~~NB: I have not successfully tested this results in a working vis installation. I can confirm that make install installs stuff, but vis currently just hangs on NetBSD and I don't currently have time to investigate why.~~ Edit: oops, it actually does work. I was just accidentally running the base system's vis filter instead of the editor.
I should also mention I have not yet checked that make install is broken on OpenBSD, for example, or that this patch fixes it. But if I have time later I may do that.
Edit: oops, it actually does work. I was just accidentally running the base system's vis filter instead of the editor.
So, should this be closed or not?
Edit: oops, it actually does work. I was just accidentally running the base system's vis filter instead of the editor.
So, should this be closed or not?
No, it should not be. Sorry, my comment was remarking that vis worked after I installed it with this patch, contradicting the crossed-out text. It was only an aside, and the main point of this patch still stands. (I have been using vis built with this patch without trouble.)
On Fri Nov 14, 2025 at 9:12 PM CET, James Cook wrote:
I would be happy to try updating this PR to do that, but first, do you have any other make implementations in mind?
Looking at https://github.com/martanne/vis/wiki/Distribution-Packages I think we are really talking about various Linuxes (which I suppose use all GNU Make), *BSD which use BSD Make, right? and Mac OS X with Homebrew (what do they use? Gemini told me that it is an ancient, and I mean ancient, from 2006, GNU Make, but Homebrew installs something more recent for its packages).
Matěj
-- http://matej.ceplovi.cz/blog/, @@.*** GPG Finger: 3C76 A027 CA45 AD70 98B5 BC1D 7920 5802 880B C9D8
No matter what happens in the kitchen, never apologize. -- Julia Child
On Fri Nov 14, 2025 at 9:14 PM CET, James Cook wrote:
(For clarity: I mean
${.CURDIR}is set on {Open,Net,Free}BSD's makes. Also I think the bug will affect all three of those platforms, when using base systemmakeinstead of GNU make, but I haven't tried.)
Another thought which I have had on back burner for a long time … do we really need two Makefiles? Couldn’t we somehow join them together?
Best,
Matěj
-- http://matej.ceplovi.cz/blog/, @@.*** GPG Finger: 3C76 A027 CA45 AD70 98B5 BC1D 7920 5802 880B C9D8
Afraid to die alone? Become a bus driver. -- alleged easter egg in notepad++
Also, what do you think about https://github.com/martanne/vis/pull/1270?
Also, what do you think about #1270?
I don't know much about CMake or how vis's configure script currently works, but I'll note two things:
- The current
./configureseems to work for me; this PR is just about a Makefile incompatibility. - vis currently builds just fine on NetBSD (probably other BSDs) if I simply make sure to use
gmake(GNU make) instead ofmake(from the BSD base system). The purpose of this pull request is to try to get it working (again?) with {Open,Net,maybe other}BSD's nativemaketools.
@mcepl I just realized GNUmakefile includes Makefile, so my change actually broke the build with GNU make.
I just pushed new changes tested with both GNU make and NetBSD's make. The assumption is anything that uses Makefile directly sets .CURDIR.
(Your suggestion to cd to $(.CURDIR) if set unfortunately doesn't work. I think the problem is each line of the build recipe is executed separately, and the effect of cd doesn't last from one to another. If you really want to go that way, we could add ; \ to the end of each shell command so the whole recipe gets executed as one big shell command.)
Sorry, I just force pushed a correction. If you happened to be taking a look in the past few minutes, please update.
On Fri Nov 28, 2025 at 4:44 PM CET, James Cook wrote:
falsifian left a comment (martanne/vis#1263)
Also, what do you think about #1270?
Ignore that reference, it was a moment of temporary insanity to even consider CMake. Of course, it is complete nonsense to even consider it (see my comments on #1270). If we want to ever move to anything more fancy (and I generally don’t), then we could think about mk-configure, but as long as we can live with nothing, I would stay with it.
BTW @mcepl GitHub is showing "1 requested change" by you (see attached screenshot), but I don't know what it's talking about and can't see any proposed changes. If that's real then please help me find the change you're requesting. Sorry, I don't have a lot of experience with GitHub.
I assume this is not a problem if obj doesn't exist? If that is the case this will be superseded by #1290 which will no longer generate temporary .o or .d files.