[fdo-internals] RE: mkcatdefs/gencat message catalogue files on OSX

Greg Boone greg.boone at autodesk.com
Sat Feb 14 20:26:58 EST 2009


Right now the mkcatdefs issue is blocking progress. Jack/Traian, if you can provide any steps on how to build it on macosx, that would be appreciated.

Greg

From: fdo-internals-bounces at lists.osgeo.org [mailto:fdo-internals-bounces at lists.osgeo.org] On Behalf Of Traian Stanev
Sent: Saturday, February 14, 2009 2:43 PM
To: fdo-internals at lists.osgeo.org
Subject: [fdo-internals] RE: mkcatdefs/gencat message catalogue files on OSX


I *think* I recompiled mkcatdefs for OSX and generated the message file on my Mac. I forgot how I did it, but I can go through it again to retrace my steps. As far as I remember, it wasn't too painful.

At the time, I was actually going to complain about the whole process of generating the message catalog like that instead of having all the messages in a header of some sort... A related question, do FDO error messages from the generated catalog ever get localized to languages other than English?

Another thing that is really bad (at least on OSX) is that the Fdo/Nls code has header files which have the same names as standard C headers!! This was confusing the hell out of g++ since other standard C headers end up including those header files from FDO rather than from e.g. /usr/include.

I never really got FDO to compile cleanly on OSX, but admittedly I didn't spend too long on it.

Traian


From: fdo-internals-bounces at lists.osgeo.org [mailto:fdo-internals-bounces at lists.osgeo.org] On Behalf Of Greg Boone
Sent: Saturday, February 14, 2009 2:31 PM
To: fdo-internals at lists.osgeo.org
Subject: [fdo-internals] mkcatdefs/gencat message catalogue files on OSX

Hi All,

When generating our FDO message catalogue files on Linux we use the following Makefile.am specification which in turn relies on mkcatdefs and gencat. However on OSX, mkcatdefs is not available. Are there any suggestions out there on how we can modify the message catalogue compilation process to work with OSX?


AUTOMAKE_OPTIONS = foreign

EXTRA_DIST = FDOMessage.mc resource.h MessageStatic.rc

CATDIR = ../../nls/linux/en_US

CATALOGS = FDOMessage.mc

CATALOGS_CAT = $(patsubst %.mc,$(CATDIR)/%.cat,$(CATALOGS))

all: catalog_init $(CATALOGS_CAT)

clean:
                @rm -rf $(CATDIR)/*.cat
                @rm -rf *.msf

catalog_init::
                @if [ ! -d $(CATDIR) ]; then mkdir -p $(CATDIR); fi


$(CATALOGS_CAT) : $(CATDIR)/%.cat : %.msf
                @rm -f "../../Inc/$(basename $(notdir $<)).h"
                @echo "$(FDOTHIRDPARTY)/linux/mkcatdefs/mkcatdefs $(basename $(notdir $<)) $< | gencat $@"; \
                $(FDOTHIRDPARTY)/linux/mkcatdefs/mkcatdefs $(basename $(notdir $<)) $< > $(addsuffix .tmp, $(basename $(notdir $<))); \
                gencat $@ $(addsuffix .tmp, $(basename $(notdir $<))); \
                sed -e '/#include/d' -e '/MF_/s/"\(.*\)\.cat"/\1_cat/' \
                $(addsuffix _msg.h, $(basename $(notdir $<))) > \
                ../../Inc/$(addsuffix _msg.h, $(basename $(notdir $<)))
                @rm $(addsuffix _msg.h, $(basename $(notdir $<))) \
                $(addsuffix .tmp, $(basename $(notdir $<)))
                @mv ../../Inc/$(basename $(notdir $<))_msg.h ../../Inc/FdoMessage.h

%.msf : %.mc
                @../McToMsf/McToMsf $(basename $(notdir $<)).mc $(basename $(notdir $<)).msf "*" FDO


INSTALL_DIR  = $(prefix)/nls

#install data
install :
                @if [ ! -d $(INSTALL_DIR) ]; then mkdir -p $(INSTALL_DIR); fi
                @cp -u -f $(CATDIR)/FDOMessage.cat $(INSTALL_DIR)

uninstall :
                @rm -f $(INSTALL_DIR)/FDOMessage.cat

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/fdo-internals/attachments/20090214/1cd028a5/attachment.html


More information about the fdo-internals mailing list