Re: wxWidgets 2.9 build

Поиск
Список
Период
Сортировка
От Dave Page
Тема Re: wxWidgets 2.9 build
Дата
Msg-id AANLkTimkBVyY2dBwojs09Do1-8dZwNGFaJdZCPwY+SS8@mail.gmail.com
обсуждение исходный текст
Ответ на Re: wxWidgets 2.9 build  (Peter Geoghegan <peter.geoghegan86@gmail.com>)
Ответы Re: wxWidgets 2.9 build  (Peter Geoghegan <peter.geoghegan86@gmail.com>)
Список pgadmin-hackers
On Mon, Jan 17, 2011 at 11:56 PM, Peter Geoghegan
<peter.geoghegan86@gmail.com> wrote:
> Hmmm....seem to be getting a weird linker error when I build OGL (from
> the independent package) against 2.9:
>
> /usr/bin/ld: ogl_dll_composit.o: relocation R_X86_64_32 against
> `wxDivisionControlPoint::ms_classInfo' can not be used when making a
> shared object; recompile with -fPIC
> ogl_dll_composit.o: could not read symbols: Bad value
> collect2: ld returned 1 exit status
>
> I take it that you didn't see this Dave? I built it against 2.9, which
> was itself built using a shell script that's the same as
> ./xtra/build-wxgtk, except that I removed the contrib stuff.

No, I didn't. FYI, I was building on Mac which tends to have it's own
unique set of issues due to the Universal Binaries the platform uses.

> Should -fPIC be in our CXXFLAGS? If so, why wouldn't it be?

I don't know - should it? We're not building any shared libraries, so
does it matter?

That reminds me of another issue that needs fixing at some point; the
build system confuses CPPFLAGS and CXXFLAGS.

>> I imagine that makes for a big (and ugly) patch - the main reason we
>> use c_str() is so we can pass wxStrings to variadics.
>
> Maybe we should consider using an alternative to conventional variadic
> functions. There are lots of things to not like about them.
> Boost.format is a good alternative . It may not actually be worth
> pursuing, but it's worth noting.

That would be a huge patch - and it would need some serious
justification for us to consider moving away from the wxWidgets way of
doing things.

> Find attached latest error output. All miscellaneous issues have been
> resolved. I'm only missing these object files now:
>
> g++: pgAdmin3.o: No such file or directory
> g++: ctlSQLBox.o: No such file or directory
> g++: explainCanvas.o: No such file or directory
> g++: explainShape.o: No such file or directory
> g++: frmQuery.o: No such file or directory
> g++: parser.tab.o: No such file or directory
>
> I believe that the only things standing between us and a rough 2.9 build are:
>
> 1. The linker problem above. OGL compiles acceptably.

That'll probably fix explainCanvas and explainShape.

> 2. The problem with pgsParser.yy. This is probably exceedingly simple,
> but I haven't managed to fix it yet.
> 3. The problem with wx2stc() above. I could have fixed this by copying
> and pasting the tiny function which only appears in private.h in 2.9,
> but it that would violate the wxWindows licence.


<grumble>. So we need to convert from a wxString to a UCS2 char array.
http://docs.wxwidgets.org/stable/wx_wxmbconvutf16.html#wxmbconvutf16
seems like it might do the trick.

> I have had to do one or two things that I'm not overjoyed with to get
> to this point, including using a const_cast to cast away constness
> from a handle (wxChar*) to the internal buffer used by wxString.

Urgh.

--
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

В списке pgadmin-hackers по дате отправления:

Предыдущее
От: Peter Geoghegan
Дата:
Сообщение: Re: wxWidgets 2.9 build
Следующее
От: Peter Geoghegan
Дата:
Сообщение: Re: wxWidgets 2.9 build