gtk+/glib-1.2.8 xchat 1.57 and socketpair

Hi,
I’ve managed to hack together a port of gtk±1.2.8/glib-1.2.8
by jumping through a few loops, what I want to know is if
neutrino supports socketpair() or can I use pipes like
#if defines for OS/2 in xchat to get exec_cmd(s) working.

Here is how I ported glib/gtk±1.2.8 to qnx
1> copy from /usr/share/libtool config.guess, config.sub, ltconfig, ltmain.sh to dir where you
gzipped the source archive to.
2> remove configure from archive. Search for ‘fd_mask’ in configure.in and
change to ‘fd_set’
3> run autoconf to regenerate configure script
4> do normal ./configure, make, etc. for glib
5> when making gtk I needed to run configure with ‘–disable-nls’
6> in /usr/include/sys/platform.h I needed to comment out lines
90 to 98 where #if defined(_XOPEN_SOURCE) begins
and the last #endif after #error This POSIX_C_SOURCblah.blah.blah

prepare for bloat ;o)

I don’t know about step 5. perhaps I don’t have all the gnu stuff installed
Any suggestions?

To get xchat 1.57 runnable I needed to comment out all references
to socketpair() (e.g. exec_cmd) in outbound.c.

Hi,
I’ve managed to hack together a port of gtk±1.2.8/glib-1.2.8
by jumping through a few loops, what I want to know is if
neutrino supports socketpair() or can I use pipes like
#if defines for OS/2 in xchat to get exec_cmd(s) working.

Here is how I ported glib/gtk±1.2.8 to qnx
1> copy from /usr/share/libtool config.guess, config.sub, ltconfig,
ltmain.sh to dir where you
gzipped the source archive to.
2> remove configure from archive. Search for ‘fd_mask’ in configure.in
and change to ‘fd_set’
3> run autoconf to regenerate configure script
4> do normal ./configure, make, etc. for glib
5> when making gtk I needed to run configure with ‘–disable-nls’
6> in /usr/include/sys/platform.h I needed to comment out lines
90 to 98 where #if defined(_XOPEN_SOURCE) begins
and the last #endif after #error This POSIX_C_SOURCblah.blah.blah

prepare for bloat ;o)

I don’t know about step 5. perhaps I don’t have all the gnu stuff installed
Any suggestions?

To get xchat 1.57 runnable I needed to comment out all references
to socketpair() (e.g. exec_cmd) in outbound.c.

Hi Steven and readers.

please help an end user 8{

in relation to your step by step of how you managed to get a fully installed
GTK+ and Glib, i assume your useing a fully installed bog standard public
beta RTP .ISO in a (in my case 2gig) partion ?, rather than a pre-RTP
or augusta image.

these step by step type posts are very much apreciated by the end users
such as myself. please make many more .

i followed your post and indeed it seems that i managed to successfully
install glib, however it also seems that linux places the Glib files as
standard in /usr/local/* were as RTP doesn`t seem to be setup as standard
to know anything about /usr/local/ , this is i feel, stopping many end
users just wishing to try and ./install make a few freshmeat utils to
tide them over until the real coders hopefully begin to port these
linux and other apps to native NTO/Photon.

while iv grabbed the pre compiled versions (glib-gtk.tar.gz)of these libs for use by any of the pre compiled binarys that require them from qnxstart and after a LOT of messing around , moveing them (thank god i managed to get worker1.3.3 the Dopus4 linux port going) from thier untared /usr/nto/x86/usr/local/lib/ (whats all these dir about anyway ?)
to the more logical and apparently default RTP /lib dir and making
copys/renameing of them as some GTK apps didn`t like the default names
libgdk-1.2.0.so, libglib-1.2.0.so, libgmodule-1.2.0.so and
libgtk-1.2.0.so to *1.2.so.0

it seems that without a simple way to get these GTK and Glib dev
packages fully installed, and paths understood by a base RTP Install,
i`m not going to be able to ./configure make, many/any freshmeat apps
to tide me over ?.

perhaps in this one case, someone could create a repository of fully
working GTK/Glib/patched RTP base paths and place that on the qnx server
to help tide the (i feel many) end users trying to go through this
initial brick wall.

another point i find really hard to grasp, is the RTP file system layout,
for instance why doesnt RTP not know about /usr/local/ by default ?, im assuming its a linux thing , the thing id *really* like to see would be a simple this whatever-dir is for RTP lib files, this
whatever-dir is for user installed libs, this whatever-dir is a standard
linux lib dir, you can move these linux libs to the RTP whatever-dir
if you run a lot of Xphoton installed apps if you so wish, or permaently
add a Xphoton apps path dirs by editing whatever file it is ?`.

it probably sounds far to simplisic to you many long time code writers
reading, but this is the type of simple hand holding for us end users
i feel is the most effective way to help encurage new generations of
coders, at least IMO, YMMV.

so as it stands now, it seems i have Glib installed in /usr/local/ ,
the RTP cant find the glib-config in /usr/local/bin/ , set doesnt
seem to show any /usr/local/ variable installed as default and i
cant find were to add this /usr/local/ path too, cding to my /usr/temp/gtk+-1.2.8 dir and typeing ./configure without the -- disable-nls gives my a Memory fault (core Dumped)`

i have 64meg ram, i have 2 worker(Dopus4), 1 xterm, and 1 ped loaded,
but i also tryed with a clean boot to Photon and 1 xterm and it still
dumped so i assume its not lack of ram.

with the --disable-nls gives me

checking for extra flags to get ANSI library prototypes... configure: warning: No ANSI prototypes found in library. (-std1 didn't work.) checking for extra flags for POSIX compliance... configure: warning: Could not determine POSIX flag. (-posix didn't work.) checking for glib-config... (cached) /usr/bin/glib-config checking for GLIB - version >= 1.2.8... ./configure: /usr/bin/glib-config: not found ../configure: /usr/bin/glib-config: not found ../configure: /usr/bin/glib-config: not found ../configure: /usr/bin/glib-config: not found ../configure: /usr/bin/glib-config: not found no *** Could not run GLIB test program, checking why... *** The test program failed to compile or link. See the file config.log for the *** exact error that occured. This usually means GLIB was incorrectly installed *** or that you have moved GLIB since it was installed. In the latter case, you *** may want to edit the glib-config script: /usr/bin/glib-config configure: error: *** GLIB 1.2.8 or better is required. The latest version of GLIB *** is always available from ftp://ftp.gtk.org/. # ----------------------------------------------

iv seen several ./configures that say ANSI and POSIX didn`t work,
which i find rather strange given that RTP is indeed ANSI and
fully POSIX ?.

the next thing that i dont understand is given that i grabed both the
GTK±1.2.8 and the matching glib latest .gz from thier web page,
why is glib installing glib-config in /usr/local/bin/ and its
matching GTK+ si looking in /usr/bin/ ?.

as you can guess, i cant install GTK+ as iv hit that brick wall that im sure many more have hit since DL`ing RTP, many more
step by steps would be a very good thing right now 8}

perhaps someone can expain why i could compile UAE 0.7.6 before , it was
REALLY slow due to going through Xphoton , but i did get the exe to boot
into my WinUAE hardfile0.hdf with Piccasso4, alas i thought i`d saved that
exe somewere safe, I CANT FIND IT NOW ARRRRR, it must have been on
the older partition i just overwrote with this latest public beta RTP DOH!.

a thought that just hit me, if RTP is fully POSIX, and several linux apps
seem to be checking for POSIX compatability, does that mean that if i
give these apps the ./configure --build=POSIX or whatever command it
was, would that mean that app would be able to run in native RTP
rather than going through the really slow Xphoton layer ?, a long shot
i admit, but thought i`d ask anyway LOL.


<typed earlyer to try and get some understanding of why i could compile
UAE (without GUI due to no fully installed GTK/Glib) and many other little
things before but not now.>

i had already compiled this version of UAE from my old pre-RTP 26meg
install that all the Phx people had access to, i`m not a code
developer, mearly a user in this regard, trying to get some basic apps
compiled and correctly installed until the real coders begin porting
to native Photon, i really dont get why this newly installed
public .ISO wont compile this UAE wereas the old one did ?.

ill just drop to the older install and see if i can recompile this UAE again.

Hmmm, strange, now my old binary RTP file wont make this eather, the only thing i can think of is that i also had the old pre- public RTP.ISO installed were i now have this public one, and id ./configureed this old UAE after booting that, it would seem that at this point in time, the public Beta .ISO with its full repository installed isnt setup to allow people
such as myself with extreamly limited knowlage of Linux style filesystem
layouts to grasp were things should be or coped to to get a successful
compile and currect install.

make > /fs/hd0-dos-3/uaemake redirection to this this produces:

cd src && make
make[1]: Entering directory /usr/temp/uae-0.7.6/src' gcc -I. -I../src/include/ -c -O2 -fomit-frame-pointer -Wall -Wno-unused -Wno-format -W -Wmissing-prototypes -Wstrict-prototypes -DDONT_HAVE_ATTR_T -DGCCCONSTFUNC="__attribute__((const))" -fno-exceptions -DX86_ASSEMBLY -DUNALIGNED_PROFITABLE -fno-strength-reduce -DREGPARAM="__attribute__((regparm(3)))" -DUSE_ZFILE -D__inline__=inline -DSTATFS_NO_ARGS= -DSTATBUF_BAVAIL= -I/usr/X11R6/include -DSHM_SUPPORT_LINKS=0 main.c -o main.o make[1]: Leaving directory /usr/temp/uae-0.7.6/src’


shell says this:

make

cd src && make
make[1]: Entering directory /usr/temp/uae-0.7.6/src' gcc -I. -I../src/include/ -c -O2 -fomit-frame-pointer -Wall -Wno-unused -Wno-format -W -Wmissing-prototypes -Wstrict-prototypes -DDONT_HAVE_ATTR_T -DGCCCONSTFUNC="__attribute__((const))" -fno-exceptions -DX86_ASSEMBLY -DUNALIGNED_PROFITABLE -fno-strength-reduce -DREGPARAM="__attribute__((regparm(3)))" -DUSE_ZFILE -D__inline__=inline -DSTATFS_NO_ARGS= -DSTATBUF_BAVAIL= -I/usr/X11R6/include -DSHM_SUPPORT_LINKS=0 main.c -o main.o In file included from main.c:11: .../src/include/sysdeps.h:188: #error No 2 byte type, you lose. .../src/include/sysdeps.h:198: #error No 4 byte type, you lose. make[1]: *** [main.o] Error 1 make[1]: Leaving directory /usr/temp/uae-0.7.6/src’
make: *** [all] Error 2

make > /fs/hd0-dos-3/uaemake

In file included from main.c:11:
…/src/include/sysdeps.h:188: #error No 2 byte type, you lose.
…/src/include/sysdeps.h:198: #error No 4 byte type, you lose.
make[1]: *** [main.o] Error 1
make: *** [all] Error 2


checking for GTK - version >= 0.99.7… no
*** The gtk-config script installed by GTK could not be found
*** If GTK was installed in PREFIX, make sure PREFIX/bin is in
*** your path, or set the GTK_CONFIG environment variable to the
*** full path to gtk-config.
checking which target to use… X11
Did not find gtk+, disabling user interface
checking for GCC 2.7 or higher… yes
checking for glibc-2.0 or higher… no
You seem to be using a x86 CPU (UAE will require a 486 to run)
checking whether we are on an ELF system… yes
checking which sound system to use… sound not enabled
creating ./config.status
creating src/Makefile
creating Makefile
creating src/sysconfig.h
src/sysconfig.h is unchanged


There were 1 warnings. That is usually harmless, but read the output
from configure carefully if you run into problems.

make

cd src && make
make[1]: Entering directory /usr/temp/uae-0.7.6/src' gcc -I. -I../src/include/ -c -O2 -fomit-frame-pointer -Wall -Wno-unused -Wno-format -W -Wmissing-prototypes -Wstrict-prototypes -DDONT_HAVE_ATTR_T -DGCCCONSTFUNC="__attribute__((const))" -fno-exceptions -DX86_ASSEMBLY -DUNALIGNED_PROFITABLE -fno-strength-reduce -DREGPARAM="__attribute__((regparm(3)))" -DUSE_ZFILE -D__inline__=inline -DSTATFS_NO_ARGS= -DSTATBUF_BAVAIL= -I/usr/X11R6/include -DSHM_SUPPORT_LINKS=0 main.c -o main.o In file included from main.c:11: .../src/include/sysdeps.h:188: #error No 2 byte type, you lose. .../src/include/sysdeps.h:198: #error No 4 byte type, you lose. make[1]: *** [main.o] Error 1 make[1]: Leaving directory /usr/temp/uae-0.7.6/src’
make: *** [all] Error 2



Paul May, Manchester, UK
Team Phoenix Core

glib-gtk+ 1.2.8 is already ported under qnx rtp with some related GTK+ applications.

please visit http://qnx.org.ru

Steven Ponsford wrote:

Hi,
I’ve managed to hack together a port of gtk±1.2.8/glib-1.2.8
by jumping through a few loops, what I want to know is if
neutrino supports socketpair() or can I use pipes like
#if defines for OS/2 in xchat to get exec_cmd(s) working.

Here is how I ported glib/gtk±1.2.8 to qnx
1> copy from /usr/share/libtool config.guess, config.sub, ltconfig, ltmain.sh to dir where you
gzipped the source archive to.
2> remove configure from archive. Search for ‘fd_mask’ in configure.in and
change to ‘fd_set’
3> run autoconf to regenerate configure script
4> do normal ./configure, make, etc. for glib
5> when making gtk I needed to run configure with ‘–disable-nls’
6> in /usr/include/sys/platform.h I needed to comment out lines
90 to 98 where #if defined(_XOPEN_SOURCE) begins
and the last #endif after #error This POSIX_C_SOURCblah.blah.blah

prepare for bloat ;o)

I don’t know about step 5. perhaps I don’t have all the gnu stuff installed
Any suggestions?

To get xchat 1.57 runnable I needed to comment out all references
to socketpair() (e.g. exec_cmd) in outbound.c.

Paul May <paul@phinixi.com> wrote:

Hi,
I’ve managed to hack together a port of gtk±1.2.8/glib-1.2.8
by jumping through a few loops, what I want to know is if
neutrino supports socketpair() or can I use pipes like
#if defines for OS/2 in xchat to get exec_cmd(s) working.

You’re loggin in as root, aren’t you?

The PATH, and other environment variables are different from
a normal users. A normal user would have /usr/local/bin in
their path