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

Simplify table building: remove .txt.in-file processing from autoconf #3

Open
arteme opened this issue Aug 6, 2015 · 2 comments
Open

Comments

@arteme
Copy link

arteme commented Aug 6, 2015

Hi,

I was in the process of adding a new table. I updated the local Makefile.am file and it took me a few minutes to figure out, why the .txt.in-file was not picked up. Of course I forgot to also modify confiure.ac!

I have two proposals to simplify the process of adding new tables:

1. Remove .txt.in-file processing from autoconf

Given that the main purpose (and currently, only purpose, it seems) to have .txt.in-files and subsequent conversion to .txt-files is to substitute @SCIM_ICONDIR@ to the correct directory, I would question if using autoconf for that purpose it a bit of an overkill. Sure, autoconf does the job right, however it is way more useful for substitution in Makefile.in files, which may have many different variables to substitute. Makefiles also don't increase in number throughout the lifetime of the project too much.

The .txt.in to .txt transform above is very easy to accomplish with a one-liner sed rule. That would remove the need of keeping the up-to-date list of .txt.in-files in configure.ac -- they are already listed in their respective Makefile.am-files.

2. Move common code of Makefile.in-files from tables/*/ into a common Makefile

The Makefile.in-files from the sub-directories of the tables directory are very repetitive! They only differ in "scim_tables_source = ..." line. The rest of the file (turning scim_tables_sources into scim_tables and scim_tables_bin_DATA, rules for building bin-files, etc) can be moved out into a single Makefile that all others can include.

This would greatly simplify the task of adding a table as that would mean adding a single filename to a single file.

Of course, I don't see scim-tables changing too often, so feel free to ignore my suggestion, but in case you're interested I could volunteer some pull-requests to accomplish the above.

@tzhuan
Copy link
Member

tzhuan commented Aug 10, 2015

Thank you very much for the suggestion. Any patches to make the things simpler and remove the duplicates are welcome. Please just do it!

@leggewie
Copy link
Member

leggewie commented Aug 1, 2017

@arteme are you working on this?

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

3 participants