gcl-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gcl-devel] gcl using mingw


From: Camm Maguire
Subject: Re: [Gcl-devel] gcl using mingw
Date: 23 Jan 2002 18:02:15 -0500

Greetings!

"Billinghurst, David (CRTS)" <address@hidden> writes:

> OK.  I managed to get a build.  Testing will have to wait for a few =
> days.
> 
> The problem with the gmp files is that they are symbolically linked, and =
> 
> therefore do not exist for non-cygwin apps such as the mingw gcc.  Can
> work around this by editing gmp/configure and changing the "ln -s" at
> line 5154 to either ln or cp.
> 

Yeah -- I tried something equivalent, but in the main configure.in

> The threshold in the NULL_OR_ON_C_STACK macro depends on the compiler
> version.  I was using gcc-2.95.2 and it didn't work.  Upgrading to
> mingw-1.0.1-20010726 fixed it.  I just don't understand this bit.
> Are you sure about the values you give below.  Your tarball has
> #define NULL_OR_ON_C_STACK(y) (((unsigned int)(y)) < 0x230000 )
> and that worked.
> 

If you could provide me some logic here, we could put it into a
configure.in test too.  Can you post some pseudo-code that would spit
out this macro given observed local stack, static, and malloc
addresses?   Right now, as you probably know, configure.in checks one
CSTACK address, and then uses this if you leave the macro undefined:

#ifndef NULL_OR_ON_C_STACK


#if (CSTACK_ADDRESS > 0)
#define NULL_OR_ON_C_STACK(x) ((x)==0 || ((unsigned int)x) > (unsigned 
int)(pagetochar(MAXPAGE+1)))
#else
#define NULL_OR_ON_C_STACK(x) ((int)x <= 0)     
#endif


Perhaps you could propose an equivalent when the stack comes first?
Sounds like we should just get a STATIC address variable, and use
(x)<STATIC if STATIC<DBEGIN, or something.

Take care,

> 
> -----Original Message-----
> From: Dan Stanger [mailto:address@hidden
> Sent: Wednesday, 23 January 2002 2:55=20
> To: Billinghurst, David (CRTS)
> Subject: Re: [Gcl-devel] gcl using mingw
> 
> 
> I didn't.  I am copying my build to www.diac.com/~dxs now.  BTW,  there =
> is a file bug.txt
> which is the trace back from testing maxima-pre59.  It seems to have a =
> problem loading.
> Also, I am suprised to see that DBEGIN is defined as 0.
> Therefor I am proposing:
> 1 Fix the configure, and put missing files back into cvs from attic.
> 2 Take a close look at memory allocation.  Maybe we need to change from =
> microsoft malloc
> to gnu malloc.  Also, maybe make DBEGIN a variable set by brk or sbrk.
> Dan
> 
> "Billinghurst, David (CRTS)" wrote:
> 
> > Did you have a problem with mingfile.o?  It gets into my makefiles =
> from h/mingw.defs, and I can't see how to build it.
> >
> > -----Original Message-----
> > From: address@hidden [mailto:address@hidden
> > Sent: Saturday, 19 January 2002 8:01
> > To: address@hidden
> > Subject: [Gcl-devel] gcl using mingw
> >
> > I got gcl built using mingw.  Heres what it took:
> > copy files from gmp/generic to gmp, as configure didnt do this.
> > get a old copy of minglacks from a previous release.
> > fix NULL_OR_ON_C_STACK macro.
> > I will get the maxima cvs on my box and try to build.  Otherwise,
> > I followed the directions in readme.mingw.  My environment is
> > w2k, service pack 1.  The results of my test program which shows
> > memory locations is:
> >
> > $ ./a.exe
> > address of i was 22ff5c e was 403000
> > macro of i was 1 e was
> > 0
> > address of i was 22ff3c
> > address of malloc was 3f2488
> >
> > #define NULL_OR_ON_C_STACK(y) (((void *)(y)) < ((void *)0x400000))
> >
> > int e;
> > main()
> > {
> >    int i;
> >    printf("address of i was %x e was %x\n",&i,&e);
> >    printf("macro of i was %x e was
> > %x\n",NULL_OR_ON_C_STACK(&i),NULL_OR_ON_C_STACK(&e));
> >    x();
> > }
> > x()
> > {
> >    int i;
> >    printf("address of i was %x\n",&i);
> >    printf("address of malloc was %x\n",malloc(100));
> > }
> >
> > Notice that the address of malloc is below the address of the static =
> area.
> > Dan
> >
> > _______________________________________________
> > Gcl-devel mailing list
> > address@hidden
> > http://mail.gnu.org/mailman/listinfo/gcl-devel
> 
> 
> _______________________________________________
> Gcl-devel mailing list
> address@hidden
> http://mail.gnu.org/mailman/listinfo/gcl-devel
> 
> 

-- 
Camm Maguire                                            address@hidden
==========================================================================
"The earth is but one country, and mankind its citizens."  --  Baha'u'llah



reply via email to

[Prev in Thread] Current Thread [Next in Thread]