Date: Sat, 1 May 2004 00:07:32 EST-10EDT,10,-1,0,7200,3,-1,0,7200,3600 Subject: [Ux2bs_Archive] No. 313 ************************************************** Friday 30 April 2004 Number 313 ************************************************** Subjects for today 1 Re: Any success? : Anton Monroe 2 Re: Any success? : John Poltorak 3 Re: Any success? : Anton Monroe 4 Re: Any success? : John Poltorak **= Email 1 ==========================** Date: Fri, 30 Apr 2004 04:03:18 -0500 From: Anton Monroe Subject: Re: Any success? On Fri, Apr 16, 2004 at 10:40:49AM +0100, John Poltorak wrote: > > CCCMD = gcc -DPERL_CORE -c -Zomf -Zmt -DDOSISH -DOS2=2 -DEMBED -I. -DEMX_BAD_SBRK -D_EMX_CRT_REV_=image -O2 -fomit-frame-pointer -malign-loops=2 -malign-jumps=2 -malign-functions=2 -s -Wall > > malloc.c: In function `Perl_sbrk': > > malloc.c:2548: `SYSTEM_ALLOC_ALIGNMENT' undeclared (first use in this function) > > This is from my perl.log:- > > [C:\unixos2\workdir\perl-5.8.3]make > GNUmakefile:1250: warning: overriding commands for target `TAGS' > GNUmakefile:1242: warning: ignoring old commands for target `TAGS' > `sh cflags "optimize='-O2 -fomit-frame-pointer -malign-loops=2 -malign-jumps=2 -malign-functions=2 -s'" malloc.obj` -Zdll malloc.c > CCCMD = gcc -DPERL_CORE -c -Zomf -Zmt -DDOSISH -DOS2=2 -DEMBED -I. -D_EMX_CRT_REV_=64 -O2 -fomit-frame-pointer -malign-loops=2 -malign-jumps=2 -malign-functions=2 -s -Wall I spent hours trying to figure out why I got that error. I got hopelessly lost in a maze of configuration scripts, but I think I found at least part of the problem. The clue was this, from the perl.log: Any additional cc flags? [-Zomf -Zmt -DDOSISH -DOS2=2 -DEMBED -I. -DEMX_BAD_SBRK -D_EMX_CRT_REV_=image] "image" doesn't look like a valid version number! It looks like something in the build process calls hints\os2.sh, which calls "emxrev.cmd -f emxlibcm" and picks out the 5th word from whatever it returns. It should return EMXLIBCM.DLL : revision = 64 but instead it gives Logic error: no startup image which seems a very uninformative way of saying it can't find EMXLIBCM.DLL. At any rate, it looks like the configuration script needs to be told (somehow) to look for libraries in /unixos2/dll. The compile error I got was actually because of the erroneous "-DEMX_BAD_SBRK" flag, but that's just a byproduct of the failure to get the EMXCRT revision number. Anton _______________________________________________ UX2BS mailing list UX2BS at os2ports.com http://os2ports.com/mailman/listinfo/ux2bs **= Email 2 ==========================** Date: Fri, 30 Apr 2004 10:27:08 +0100 From: John Poltorak Subject: Re: Any success? On Fri, Apr 30, 2004 at 04:03:18AM -0500, Anton Monroe wrote: > On Fri, Apr 16, 2004 at 10:40:49AM +0100, John Poltorak wrote: > > > CCCMD = gcc -DPERL_CORE -c -Zomf -Zmt -DDOSISH -DOS2=2 -DEMBED -I. -DEMX_BAD_SBRK -D_EMX_CRT_REV_=image -O2 -fomit-frame-pointer -malign-loops=2 -malign-jumps=2 -malign-functions=2 -s -Wall > > > malloc.c: In function `Perl_sbrk': > > > malloc.c:2548: `SYSTEM_ALLOC_ALIGNMENT' undeclared (first use in this function) > I spent hours trying to figure out why I got that error. At least you figured out what the actual error was - that can be quite tricky sometimes, but at least it's good experience for tackling other problems. > I got > hopelessly lost in a maze of configuration scripts Perl is one of the hardest apps to build - I spent several weeks trying to come up with something reliable. One of the things which kept throwing me was the was the way the supplied build script determined if it was running on OS/2. It looked for the directory 'C:\OS2'!!! Which meant you could never build it if you installed OS/2 somewhere else. This drove me nuts before I worked out whatwas going on. > At any rate, it looks like the configuration script needs to be told > (somehow) to look for libraries in /unixos2/dll. The compile error I > got was actually because of the erroneous "-DEMX_BAD_SBRK" flag, but > that's just a byproduct of the failure to get the EMXCRT revision > number. The configuration script should work fine if UX2BS has installed correctly. What happens if you run '\unixos2\lib\build' and then emxrev from that shell? It sounds as though there must be some error in your installation as BEGINLIBPATH should point to \unixos2\dll. Could you post the contents of \unixos2\lib\ux2_env.cmd ? > Anton -- John _______________________________________________ UX2BS mailing list UX2BS at os2ports.com http://os2ports.com/mailman/listinfo/ux2bs **= Email 3 ==========================** Date: Fri, 30 Apr 2004 07:40:00 -0500 From: Anton Monroe Subject: Re: Any success? On Fri, Apr 30, 2004 at 10:27:08AM +0100, John Poltorak wrote: > What happens if you run '\unixos2\lib\build' and then emxrev from that > shell? > Could you post the contents of \unixos2\lib\ux2_env.cmd ? > \unixos2\lib\build.cmd without parameters gives "not defined in build table". \unixos2\lib\ux2_env.cmd is: set path=M:/unixos2\bin;H:\os2; set beginlibpath=M:/unixos2\dll; env | sed "/^\/k/d;s/^/set /;s/=.*$/=/" >zap_env.cmd call zap_env.cmd set osrt=H: set uxrt=M: set bldrt=M: set bld_home=M:/unixos2 set repository=M:/unixos2/archives/source set workdir=M:/unixos2/workdir set buildlogs=M:/unixos2/logs set CONFIG_SITE=M:/unixos2/lib/config.site set C_INCLUDE_PATH=M:/usr/include;M:/unixos2/emx/include set CPLUS_INCLUDE_PATH=M:/usr/include/cpp;M:/usr/include;M:/unixos2/emx/include/cpp;M:/unixos2/emx/inŠ set LIBRARY_PATH=M:/usr/lib;M:/unixos2/emx/lib set beginlibpath=M:\usr\lib;M:\unixos2\dll; set PATH=M:\usr\bin;M:\unixos2\emx\bin;M:\usr\local\bin;M:\unixos2\bin;H:\os2; set DPATH=H:\os2\system set TMP=M:\tmp set HOME=M:/home/root set ETC=M:\etc set TERM=ansi-color-3 set OS2_SHELL=H:\os2\cmd.exe set COMSPEC=H:\os2\cmd.exe set PAGER=less set HOSTNAME=localhost When I run it, I get the expected environment. Then I type "emxrev.cmd" and the session ends. I suppose that is because emxrev.cmd sometimes ends with an "exit" command. "cmd.exe /c emxrev.cmd" gives the 'no startup image' message. I added some lines to /hints/os2.sh to save the environment when it runs. I.e., "set >> \set.out". It looks like sh doesn't have anything called $BEGINLIBPATH. It does have $LIBRARY_PATH and a lot of others. I'm confused; maybe this makes more sense to you. I'll work on it some more later. Anton _______________________________________________ UX2BS mailing list UX2BS at os2ports.com http://os2ports.com/mailman/listinfo/ux2bs **= Email 4 ==========================** Date: Fri, 30 Apr 2004 14:05:42 +0100 From: John Poltorak Subject: Re: Any success? On Fri, Apr 30, 2004 at 07:40:00AM -0500, Anton Monroe wrote: > On Fri, Apr 30, 2004 at 10:27:08AM +0100, John Poltorak wrote: > > Could you post the contents of \unixos2\lib\ux2_env.cmd ? > set CPLUS_INCLUDE_PATH=M:/usr/include/cpp;M:/usr/include;M:/unixos2/emx/include/cpp;M:/unixos2/emx/inŠ Has something gone wrong there? It shouldn't make any difference to Perl though... > When I run it, I get the expected environment. Then I type "emxrev.cmd" > and the session ends. I suppose that is because emxrev.cmd sometimes > ends with an "exit" command. "cmd.exe /c emxrev.cmd" gives the 'no > startup image' message. What do you get when you run emxrev in the session started up whe you run 'build'? > > I added some lines to /hints/os2.sh to save the environment when it > runs. I.e., "set >> \set.out". It looks like sh doesn't have anything > called $BEGINLIBPATH. It does have $LIBRARY_PATH and a lot of others. > I'm confused; maybe this makes more sense to you. I'll work on it some > more later. The current environment is displayed at the end of the log file for the app currently being built > Anton -- John _______________________________________________ UX2BS mailing list UX2BS at os2ports.com http://os2ports.com/mailman/listinfo/ux2bs