Jean-Marc Lasgouttes <[EMAIL PROTECTED]> writes:

>>>>>> "Lars" == Lars Gullik Bjønnes <[EMAIL PROTECTED]> writes:
>
| Lars> The relative path from going from builddir to sourcedir, they
| Lars> must be removed when generating the filenames in the pots.
>
| But when I do 
|   cd ${srcdir} ; awk 'blah' lib/ui/*.ui >foo.pot
| there is nothing related to build directory that should interfere.

But you cannot do just that. You must ouput the filename as well...
And you are not allowed to run in-place...

| Of course, it creates pot files in the src directory, and this may not
| be what you expected. But this is easy to fix.

Is it really... do your changes and try a "make distcheck"

| Lars> So, yes. I belive you are on to something. The awk that removs
| Lars> the prefix on the relative patch should most likely just remove
| Lars> ${top_srcdir}
>
| It may be a good idea indeed.

I add a arg to awk: -v top_srcdir="$(top_srcdir)"
then I add a function:
       function fixupfilename()
       {
               fna=FILENAME;
               sub(top_srcdir "/", ", fna);
               return fna;
       }

And use it in the call to printf.

This fixes stuff for the builddir != srcdir case. I have to check that
builddir == srcdir still works as expected as well.

-- 
        Lgb

Reply via email to