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 dist fails due to po file renames #1078

Closed
Athanasius opened this issue Oct 20, 2024 · 13 comments · Fixed by #1079
Closed

make dist fails due to po file renames #1078

Athanasius opened this issue Oct 20, 2024 · 13 comments · Fixed by #1079
Labels
type:bug Something's broken!

Comments

@Athanasius
Copy link

This is a development files issue, rather than in the fvwm program itself.

Expected Behaviour

That make dist (necessary to then move on to a Debian dpkg-buildpackage) should run without error and produce an appropriate archive file.

Actual Behaviour

make[4]: Entering directory '/usr/local/src/fvwm3.git/doc'
make[4]: Leaving directory '/usr/local/src/fvwm3.git/doc'
make[3]: Leaving directory '/usr/local/src/fvwm3.git/doc'
 (cd po && make  top_distdir=../fvwm3-1.1.1 distdir=../fvwm3-1.1.1/po \
     am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)
make[3]: Entering directory '/usr/local/src/fvwm3.git/po'
make  distdir-am
make[4]: Entering directory '/usr/local/src/fvwm3.git/po'
make[4]: *** No rule to make target 'fvwm3.ar.po', needed by 'distdir-am'.  Stop.
make[4]: Leaving directory '/usr/local/src/fvwm3.git/po'
make[3]: *** [Makefile:361: distdir] Error 2
make[3]: Leaving directory '/usr/local/src/fvwm3.git/po'
make[2]: *** [Makefile:639: distdir-am] Error 1
make[2]: Leaving directory '/usr/local/src/fvwm3.git'
make[1]: *** [Makefile:633: distdir] Error 2
make[1]: Leaving directory '/usr/local/src/fvwm3.git'
make: *** [Makefile:739: dist] Error 2

Extra Information

Presumably b92ecb292ec639dc2701c3d172d6891417858d8a didn't properly update everything for this file rename. I'll try to track down the minimum edit in order to get this working again. Last time I simply hardlinked the old names to the new names to get past it (Debian's build wasn't happy about symbolic links).

@Athanasius Athanasius added the type:bug Something's broken! label Oct 20, 2024
@Athanasius
Copy link
Author

I should have noted, my current git checkout is at:

fd67bc261 (HEAD -> main, origin/main) Implement Meson on main branch.

@somiaj
Copy link
Collaborator

somiaj commented Oct 20, 2024

Thanks, I hadn't tested make dist. Note this should be fixed, but are you trying to make a local .deb file, I do this and don't use make dist.

@Athanasius
Copy link
Author

It's entirely possible I'm not using the correct/optimal method in order to build a .deb file. Keep in mind I'm trying to do this in a manner that adheres to the Debian package (still based on 1.1.0) way of doing it, i.e. I'm using their debian/ directory of files, with necessary edits to still work given fvwm3 changes since they last updated.

When the dpkg-buildpackage is far enough along it complains if there's not a matching ../fvwm3-<version>+ds.orig.tar.gz file.

@Athanasius
Copy link
Author

I've found a minimum change that results in make dist working:

diff --git a/acinclude.m4 b/acinclude.m4
index 5848d2dac..7caa2eea6 100644
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -1051,7 +1051,7 @@ AC_DEFUN([AM_PO_SUBDIRS],
   DUMMYPOFILES=
   for lang in $ALL_LINGUAS; do
     for dom in $ALL_DOMAINS; do
-      POFILES="$POFILES $dom.$lang.po"
+      POFILES="$POFILES $lang.po"
       GMOFILES="$GMOFILES $dom.$lang.gmo"
       UPDATEPOFILES="$UPDATEPOFILES $dom.$lang.po-update"
       DUMMYPOFILES="$DUMMYPOFILES $dom.$lang.nop"

You can't just eliminate the whole for dom ... loop, because the .gmo files are still expected to be named with the "domain" prefix of fvwm3. by other parts of the build process.

@somiaj
Copy link
Collaborator

somiaj commented Oct 20, 2024

This patch fixes the issue for me.

diff --git a/po/Makefile.am b/po/Makefile.am
index c7d6cf696..930048110 100644
--- a/po/Makefile.am
+++ b/po/Makefile.am
@@ -2,7 +2,7 @@
 localedir = @LOCALEDIR@
 
 EXTRA_DIST = \
-       @POFILES@ @GMOFILES@ fvwm3.pot
+       @GMOFILES@ fvwm3.pot
 
 # This is the list of locale categories, beyond LC_MESSAGES, for which the
 # message catalogs shall be used.  It is usually empty.

No reason to include the .po files in the dist tarball at this moment because they aren't used in the build at all, instead the prebuilt .gmo files are just installed.

Note, I am the Debian maintainer, so here use this.

https://github.com/somiaj/fvwm3-debian/tree/fvwm3-git

Note the instructions have a -b in the dpkg-buildpackage call, this says just make a binary package, not a source package, so the tarball is no longer needed (do you have a reason to need the source package).

If you would like to test things, I have a meson branch too,

https://github.com/somiaj/fvwm3-debian/tree/meson

You will have to install meson from bookworm-backports to test this on bookworm. This is what I'm using to build the package.

@somiaj
Copy link
Collaborator

somiaj commented Oct 20, 2024

Ahh your patch works too, I didn't track this deeper, and it is probably better if someone did want the .po files (which I guess are used with meson). I'll apply that, thanks.

@Athanasius
Copy link
Author

Ahh your patch works too, I didn't track this deeper, and it is probably better if someone did want the .po files (which I guess are used with meson). I'll apply that, thanks.

Due to my fumbling with the debian build aspect I was keeping the .po files because there are patches that apply to them. I'll try out your fvwm3-git branch version of things now, thanks !

@somiaj
Copy link
Collaborator

somiaj commented Oct 20, 2024

Note, my git branch doesn't work with make dist as it isn't something I used. Just edit the debian/changelog and remove ~rc1 from the version, this was just me indicating that it isn't yet released, but I'll do these updates to make people using this other than me work better (I had someone else mention this to me but didn't quite understood what they meant at the time since I don't ever build the source package in testing).

@Athanasius
Copy link
Author

Note, my git branch doesn't work with make dist as it isn't something I used. Just edit the debian/changelog and remove ~rc1 from the version, this was just me indicating that it isn't yet released, but I'll do these updates to make people using this other than me work better (I had someone else mention this to me but didn't quite understood what they meant at the time since I don't ever build the source package in testing).

All working now, thanks. I've made some notes about all the necessary steps to ensure I'm using the up to date debian/ files.

Currently I'm having to build my own due to some things that affect the Steam Linux client menus. See #924 (comment) and onwards. I should really actually fork the fvwm3 repo, and make a PR for the changes I'm using.

@somiaj
Copy link
Collaborator

somiaj commented Oct 20, 2024

If you have a patch, you could use quilt and apply it in debian/patches of the my fvwm3-debian repo, this way you can just apply your patch on top of whatever version of fvwm you are building against vs having a fork. Though there are lots of ways to do this.

May I ask what patches you had that applied to the .po files. Currently translations in debian are out dated a bit, I'm not assuming anything relevant, but just wanted to check them out.

@Athanasius
Copy link
Author

May I ask what patches you had that applied to the .po files. Currently translations in debian are out dated a bit, I'm not assuming anything relevant, but just wanted to check them out.

Keep in mind I had been using the bookworm version of the debian/ files. They had some debian/patches/ files that touched the .po files. Now I've moved on to using your updated debian/ files it's moot.

@somiaj
Copy link
Collaborator

somiaj commented Oct 20, 2024

There are no patches against the .po file in bookworm source package of fvwm3 or fvwm. I think you have been carrying these around for a while. That is why I was interested in them, they are not something I've seen in my years of maintain the debian package, was just curious if there were some updated translations. Not a big deal anyways, I just just curious what they were.

@Athanasius
Copy link
Author

Ah, it's possible I'd managed to fumble such in during my attempts to otherwise get things to build. So a moot point now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug Something's broken!
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants