This patch is a port of the patch on GnuWin32's libintl. It adds builtin relocation support for executables. With this patch all programs are relocatable without the need to add relocation code to the program.
Yes. My last patch is up to date. I think it is very useful. I ship wcd and dos2unix with a libintl dll with this patch. I also offer a standalone patched dll on my personal web site.
I think that Charles 'Chuck' Wilson is the maintainer of the libintl package. I could discuss with him if he wants to apply it. I could also do it. I have already a mgwport script ready.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I thought gettext was supposed to have relocation support built in. I'd really like to give Bruno an opportunity to comment on this.
I saw that somebody else packed gettext 0.18.3.1 for mingw,
Earnie did that, AFAIK.
and used a different packing method (not the mgwport that I'm used to), so I'm lost.
Why do you expect anyone to use a packaging tool which was never adopted as a project standard? Chuck dumped mgwport on us, for consideration. I gave him a critique, explaining why I considered it unacceptable. He disappeared.
My stance remains that mgwport is disaster central, and far from fit for purpose. It is dead in the water. Please do not use it.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
libintl is part of GNU gettext (the package); AIUI, that's supposed to support relocation OOTB. If that's not working properly, for the entire package, I'd rather have it fixed properly, upstream; persistently updating MinGW local patches, for each new released version, isn't productive use of our limited resources.
I liked mgwport.
It's underlying principles incorporated some good ideas. However, the package structure it advocates -- and forces me to adopt -- is seriously flawed. Furthermore, the implementation is just too disgusting for words ...
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
You don't get it. Please the the mail thread I pointed to. The programs in the gettext package are all relocatable, because relocation code is added to all the individual programs in the package.
This patch adds the relocation feature to the libintl library instead. That means that ALL programs who link to libintl become automagically relocatable. There is no need any more to add relocation to programs.
Kees Zeelenberg made the first version of this patch for the GnuWin32 project. I used GnuWin32 and found this automatic relocation support very useful, so I ported the patch to newer gettext versions for mingw. On Windows people unpack bin packages at random places. Therefore on Windows this feature is very handy. I'm using it for years now in my own binary distributions of dos2unix and wcd.
I have mailed Bruno Haible personally, and I have reported this to the gettext mailing list, but the upstream maintainers are not interested in this feature. They ignore it and don't even bother to give a response.
regards,
Erwin
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I do get it; you want to fork GNU gettext. I don't. Neither does Chuck. (Nor does anyone else here, apparently).
This patch adds the relocation feature to the libintl library instead. That means that ALL programs who link to libintl become automagically relocatable.
If by "relocatable", all you mean that message catalogue references follow an executable around in the file system, perhaps; you seem to be quite happy to blatantly ignore the fact that there may be -- possibly a great deal -- more to relocation than just that.
The programs in the gettext package are all relocatable, because relocation code is added to all the individual programs in the package.
Indeed. To satisfy your limited definition of relocatable, they all invoke bindtextdomain() thus:
I've no doubt that Bruno had sound technical reasons for implementing it thus -- reasons which it would certainly be nice, if he would share -- in addition to the extensive additional use he makes of his relocate() function, in a broader context than the limited scope of your concept of "relocatable".
I have mailed Bruno Haible personally, and I have reported this to the gettext mailing list, but the upstream maintainers are not interested in this feature. They ignore it and don't even bother to give a response.
Perhaps they would be more amenable, if your patch was formulated in terms of the relocation machinery which is already implemented, within the existing GNU gettext source, instead of relying on a third party implementation with a similar objective?
Last edit: Keith Marshall 2014-01-12
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
updated libintl relocation patch
Updated patch, to fix compilation on Unix/Linux/Cygwin.
If needed I'm willing to maintain this patch for MinGW. Also for future versions of gettext/libintl.
My goal is to get this patch in upstream gettext eventually.
Patch for gettext 0.18.1.1
I uploaded a new patch for gettext 0.18.1.1
This can be used in the mgwport script.
See also http://waterlan.home.xs4all.nl/libintl.html
Ticket moved from /p/mingw/patches/443/
Erwin is this still appropriate?
Hi,
Yes. My last patch is up to date. I think it is very useful. I ship wcd and dos2unix with a libintl dll with this patch. I also offer a standalone patched dll on my personal web site.
I think that Charles 'Chuck' Wilson is the maintainer of the libintl package. I could discuss with him if he wants to apply it. I could also do it. I have already a mgwport script ready.
At this point I elect you to complete this. Chuck has been MIA for a while now.
OK. I do that.
I have a patch now for gettext 0.18.3.1. See attachment.
I saw that somebody else packed gettext 0.18.3.1 for mingw, and used a different packing method (not the mgwport that I'm used to), so I'm lost.
I thought gettext was supposed to have relocation support built in. I'd really like to give Bruno an opportunity to comment on this.
Earnie did that, AFAIK.
Why do you expect anyone to use a packaging tool which was never adopted as a project standard? Chuck dumped mgwport on us, for consideration. I gave him a critique, explaining why I considered it unacceptable. He disappeared.
My stance remains that mgwport is disaster central, and far from fit for purpose. It is dead in the water. Please do not use it.
This is not about the gettext program, but about the libintl library. To refresh your memory have a look at http://mingw.5.n7.nabble.com/gettext-libintl-0-17-1-not-relocatable-2-td22227.html
I liked mgwport.
You can take the patch or leave it.
regards,
Erwin
libintl is part of GNU gettext (the package); AIUI, that's supposed to support relocation OOTB. If that's not working properly, for the entire package, I'd rather have it fixed properly, upstream; persistently updating MinGW local patches, for each new released version, isn't productive use of our limited resources.
It's underlying principles incorporated some good ideas. However, the package structure it advocates -- and forces me to adopt -- is seriously flawed. Furthermore, the implementation is just too disgusting for words ...
You don't get it. Please the the mail thread I pointed to. The programs in the gettext package are all relocatable, because relocation code is added to all the individual programs in the package.
This patch adds the relocation feature to the libintl library instead. That means that ALL programs who link to libintl become automagically relocatable. There is no need any more to add relocation to programs.
Kees Zeelenberg made the first version of this patch for the GnuWin32 project. I used GnuWin32 and found this automatic relocation support very useful, so I ported the patch to newer gettext versions for mingw. On Windows people unpack bin packages at random places. Therefore on Windows this feature is very handy. I'm using it for years now in my own binary distributions of dos2unix and wcd.
I have mailed Bruno Haible personally, and I have reported this to the gettext mailing list, but the upstream maintainers are not interested in this feature. They ignore it and don't even bother to give a response.
regards,
Erwin
I do get it; you want to fork GNU gettext. I don't. Neither does Chuck. (Nor does anyone else here, apparently).
If by "relocatable", all you mean that message catalogue references follow an executable around in the file system, perhaps; you seem to be quite happy to blatantly ignore the fact that there may be -- possibly a great deal -- more to relocation than just that.
Indeed. To satisfy your limited definition of relocatable, they all invoke bindtextdomain() thus:
I've no doubt that Bruno had sound technical reasons for implementing it thus -- reasons which it would certainly be nice, if he would share -- in addition to the extensive additional use he makes of his relocate() function, in a broader context than the limited scope of your concept of "relocatable".
Perhaps they would be more amenable, if your patch was formulated in terms of the relocation machinery which is already implemented, within the existing GNU gettext source, instead of relying on a third party implementation with a similar objective?
Last edit: Keith Marshall 2014-01-12
Since there is no interest, I'm going to close this ticket. This ticket was open for almost 3 years.
FYI: The MSYS2 project has accepted this patch in one day.
Thanks