Made cartconv and petcat tools buildable by themselves.
Versatile Commodore Emulator
Brought to you by:
blackystardust,
gpz
I thought I had that working, but it looks like it wouldn't work out-of-tree. Good catch on the LD_FLAGS vs LDFLAGS, not that that matters in this specific case (yet).
I wonder if:
Wouldn't be written better like:
In the other makefiles, the
cdcommands use simple relative paths. They don't use make variables.cd ../..;is consistent with those other makefiles.By the way, those tool Makefiles didn't work in-tree, either. (Note that
make cleandoesn't remove an old "svnversion.h". Therefore, your tests probably never had a truely "virgin" build environment.)You're right about the relative paths, so I'll keep that.
But the fact that
make cleandoesn't remove an old svnversion.h shouldn't matter I think, there should be a rule to remake svnversion.h whenever its dependencies change.Let me check out a fresh copy and check that assumption, for my own sanity.
Well, the patch makes standalone builds of petcat and cartconv work, either in-tree or out-of-tree. But
svnversion.hgets generated in trunk/vice/src/, not in any builddir, which feels wrong.Thanks for the patch, I've applied it in r39852.
Now I need to work on creating
svnversion.hinside $(top_builddir)src/, not $(top_srcdir)/src, since I feel any generated file should end up in the builddir, not the sourcedir.Last edit: compyx 2021-03-10
This is what I get:
"svn-vice" is the source tree.
"svn-vice-build" is the build tree.
"svnversion.h" is created in "svn-vice-build/src/"!
I have:
~/vice-trunk/vice -- sourcedir
~/vice-trunk/gtk3-build -- builddir
I run ./autogen.sh in vice/ and then cd into ../gtk3-build and run ./configure
(Running
make distcleaninside vice/ doesn't work, so that's clean)I run
rm vice/src/svnversion.hNo
svnversion.h.svnversion.h gets generated, but where?
So, where do we get the message?
That script takes $2 as the target path.
So we grep for the call to the script:
And there we go: $(srcdir)/svnversion.h, which appears to work differently on my box than yours?
You're right! I apologize; my patch was incomplete. I forgot about a fix that I did a long time ago:
I disagree with revision 39853. Two rules are used to build the header. The first rule should name the header in the same way that the second rule names it. There is no path in
That is the way that it should be; it's a local file (in the current directory).
Therefore, there should be no path at the end of the first rule's recipe.
You are correct. Changed in r39854.
Thanks for spotting that.
As far as I can tell, this now works correctly. So I suggest we close this.
No response. Closing.