1. Building struct branch fails

I am trying to build 4.1 on a test machine running Fedora 19 (64-bit) and I get the following error.

I was specifically trying to build the struct branch but it also happens in the default branch.

I currently have the old 2011 struct eubins installed, which I got from here: http://openeuphoria.org/forum/m/124845.wc

$ hg clone https://scm.openeuphoria.org/hg/euphoria euphoria 
http authorization required 
realm: 
user: ghaberek 
password: 
requesting all changes 
adding changesets 
adding manifests 
adding file changes 
added 6281 changesets with 21044 changes to 1982 files (+17 heads) 
updating to branch default 
789 files updated, 0 files merged, 0 files removed, 0 files unresolved 
 
$ cd euphoria/ 
$ hg update struct 
[greg@localhost euphoria]$ hg update struct 
55 files updated, 0 files merged, 0 files removed, 0 files unresolved 
 
$ cd source/ 
$ ./configure 
Writing configuration to ./config.gnu... 
Getting version string... 
VERSION=4.1.0 
Writing Makefile... 
Writing eu.cfg to /home/greg/Projects/euphoria/source/build/eu.cfg... 
 
$ make 
[...] 
Translating eui.ex to create 
rm -f /home/greg/Projects/euphoria/source/build/intobj/{*.c,*.o} 
(cd /home/greg/Projects/euphoria/source/build/intobj;eui -i /home/greg/Projects/euphoria/include   /home/greg/Projects/euphoria/source/euc.ex  -nobuild -i /home/greg/Projects/euphoria/include -gcc    \ 
        -arch ix86_64 -c "/home/greg/Projects/euphoria/source/build/eu.cfg" \ 
        -c /home/greg/Projects/euphoria/source/eu.cfg /home/greg/Projects/euphoria/source/eui.ex ) 
/home/greg/Projects/euphoria/source/scanner.e:1038 
<0074>:: Errors resolving the following references: 
    'MAXCHK2' has not been declared. 
    'MAXCHK8' has not been declared. 
    'MAXCHK10' has not been declared. 
    'MAXCHK16' has not been declared. 
 
            maxchk = MAXCHK16 
                             ^ 
 
 
Press Enter 

-Greg

new topic     » topic index » view message » categorize

2. Re: Building struct branch fails

What this boils down to is, I ran across a bug where ".e" is incorrectly parsed as part of an exponent (e.g. 6.022e+23). So any memstruct member that starts with "e" (or "E" or "_e" or "_E") crashes immediately.

I was planning to file a bug report, but I at least wanted to verify the bug still existed in the current struct branch. Should I file a bug report about the missing MAXCHK constants first?

memstruct test_t 
    long a 
    long b 
    long c 
    long d 
    long e 
end memstruct 
 
atom ptr = allocate( sizeof(test_t) ) 
 
ptr.test_t.a = 1 
ptr.test_t.b = 2 
ptr.test_t.c = 3 
ptr.test_t.d = 4 
ptr.test_t.e = 5 -- crashes 
 
free( ptr ) 

-Greg

new topic     » goto parent     » topic index » view message » categorize

3. Re: Building struct branch fails

???

 
-- struct.ex 
 
include std/machine.e 
 
memstruct test_t  
    long a  
    long b  
    long c  
    long d  
    long e  
end memstruct  
  
atom ptr = allocate( sizeof(test_t) )  
  
ptr.test_t.a = 1  
ptr.test_t.b = 2  
ptr.test_t.c = 3  
ptr.test_t.d = 4  
ptr.test_t.e = 5 
  
printf(1,"\n\tptr.test_t.e = %d\n", ptr.test_t.e) 
 
free( ptr )  

[$]: eui -v; eui struct.ex  
Euphoria Interpreter v4.1.0 development 
   64-bit Linux, Using System Memory 
   Revision Date: 2015-01-18 16:51:09, Id: 6273:511ab308da2e 
 
ptr.test_t.e = 5 
 

new topic     » goto parent     » topic index » view message » categorize

4. Re: Building struct branch fails

ghaberek said...

What this boils down to is, I ran across a bug where ".e" is incorrectly parsed as part of an exponent (e.g. 6.022e+23). So any memstruct member that starts with "e" (or "E" or "_e" or "_E") crashes immediately.

I was planning to file a bug report, but I at least wanted to verify the bug still existed in the current struct branch. Should I file a bug report about the missing MAXCHK constants first?

-Greg

no crash, windows built struct branch yesterday with old 3/2012 eu4.x

a 4.1 that old could have a problem, try newer 4.0 or 4.1 for building 64 bit

new topic     » goto parent     » topic index » view message » categorize

5. Re: Building struct branch fails

You can download it here: http://openeuphoria.org/eubins/linux/4.1.0/64-bit/

new topic     » goto parent     » topic index » view message » categorize

6. Re: Building struct branch fails

cargoan said...

This seems to have done the trick. I was able to build both the default and struct branches. Once I built and installed the struct eubins, my exponent error went away.

Now I can get back to what I was actually working on. Thanks! smile

-Greg

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu