development version newLISP 8.9.4

Started by Lutz, August 16, 2006, 02:56:54 PM

Previous topic - Next topic

Lutz

* additions and bug fixes



for change notes and files see:



http://newlisp.org/downloads/development/">http://newlisp.org/downloads/development/



Lutz



ps: the UUID type 4 generation will still change (at least for UNIX), but type 1 is usable

HPW

#1
http://newlisp.org/downloads/development/CHANGES-8.9.0-4.txt">http://newlisp.org/downloads/developmen ... .9.0-4.txt">http://newlisp.org/downloads/development/CHANGES-8.9.0-4.txt



Minor: The change log starts with 8.9.3 instead of 8.9.1



Thanks again for the new releaese!
Hans-Peter

pjot

#2
Lutz,



There are some compile problems with Tru64 though:


Quote
peter> make

./build



Discovered True64 Unix, please read doc/TRU64BUILD

cc -ieee -xtaso -pedantic -c -O3 -DSOLARIS -DTRU64 -D_POSIX_PII_SOCKET newlisp.c

cc -ieee -xtaso -pedantic -c -O3 -DSOLARIS -DTRU64 -D_POSIX_PII_SOCKET nl-symbol.c

cc -ieee -xtaso -pedantic -c -O3 -DSOLARIS -DTRU64 -D_POSIX_PII_SOCKET nl-math.c

cc -ieee -xtaso -pedantic -c -O3 -DSOLARIS -DTRU64 -D_POSIX_PII_SOCKET nl-list.c

cc -ieee -xtaso -pedantic -c -O3 -DSOLARIS -DTRU64 -D_POSIX_PII_SOCKET nl-liststr.c

cc -ieee -xtaso -pedantic -c -O3 -DSOLARIS -DTRU64 -D_POSIX_PII_SOCKET nl-string.c

cc -ieee -xtaso -pedantic -c -O3 -DSOLARIS -DTRU64 -D_POSIX_PII_SOCKET nl-filesys.c

cc: Warning: nl-filesys.c, line 1899: In this statement, & before array "uuid->node" is ignored. (addrarray)

        memcpy(&uuid->node, (void *)nodeID, 6);

---------------^

cc: Warning: nl-filesys.c, line 1899: In this statement, & before array "uuid->node" is ignored. (addrarray)

        memcpy(&uuid->node, (void *)nodeID, 6);

---------------^

cc: Warning: nl-filesys.c, line 1906: In this statement, & before array "uuid->node" is ignored. (addrarray)

        memcpy(&uuid->node, node, 6);

---------------^

cc: Warning: nl-filesys.c, line 1906: In this statement, & before array "uuid->node" is ignored. (addrarray)

        memcpy(&uuid->node, node, 6);

---------------^

cc -ieee -xtaso -pedantic -c -O3 -DSOLARIS -DTRU64 -D_POSIX_PII_SOCKET nl-sock.c

cc -ieee -xtaso -pedantic -c -O3 -DSOLARIS -DTRU64 -D_POSIX_PII_SOCKET nl-import.c

cc -ieee -xtaso -pedantic -c -O3 -DSOLARIS -DTRU64 -D_POSIX_PII_SOCKET nl-xml.c

cc -ieee -xtaso -pedantic -c -O3 -DSOLARIS -DTRU64 -D_POSIX_PII_SOCKET nl-web.c

cc -ieee -xtaso -pedantic -c -O3 -DSOLARIS -DTRU64 -D_POSIX_PII_SOCKET nl-matrix.c

cc -ieee -xtaso -pedantic -c -O3 -DSOLARIS -DTRU64 -D_POSIX_PII_SOCKET nl-debug.c

cc -ieee -xtaso -pedantic -c -O3 -DSOLARIS -DTRU64 -D_POSIX_PII_SOCKET pcre.c

cc newlisp.o nl-symbol.o nl-math.o nl-list.o nl-liststr.o nl-string.o nl-filesys.o  nl-sock.o nl-import.o nl-xml.o nl-web.o nl-matrix.o nl-debug.o pcre.o -taso -lm -lrt -ldb -lbsd -o newlisp

ld:

Unresolved:

strtoll

*** Exit 1

Stop.

*** Exit 1

Stop.


The 'strtoll' is not recognized. What exactly are you expecting for 'long long'? Running 'types.c' on Tru64Unix:


Quote
peter> ./types

type      bytes

---------------

char      1

char *    8

void *    8

short int 2

int       4

long      8

long int  8

long long 8

float     4

double    8

wchar_t   4


It seems that 'long long' has the same size as 'long', therefore I propose to change 'strtoll' to strtol' when compiling for Tru64.



If I change it like that, and run 'qa-dot', all tests run successfull:


Quote
peter> ./qa-dot



Testing built-in functions ...



!              !=             $              %              &

*              +              -              /              <

<<             <=             =              >              >=

>>             NaN?           ^              abs            acos

add            address        amb            and            append

append-file    apply          args           array          array-list

array?         asin           assoc          atan           atan2

atom?          base64-dec     base64-enc     bayes-query    bayes-train

begin          beta           betai          binomial       case

catch          ceil           change-dir     char           chop

clean          close          command-line   cond           cons

constant       context        context?       copy-file      cos

count          cpymem         crc32          crit-chi2      crit-z

current-line   date           date-value     debug          dec

def-new        define         define-macro   delete         delete-file

device         difference     directory      directory?     div

do-until       do-while       dolist         dotimes        dotree         dump           dup            empty?

encrypt        ends-with      env            erf            error-event

error-number   error-text     eval           eval-string    exec

exit           exp            expand         explode        factor

fft            file-info      file?          filter         find

find-all       first          flat           float          float?

floor          flt            for            fork           format

fv             gammai         gammaln        get-char       get-float

get-int        get-integer    get-string     get-url        global

if             ifft           import         inc            index

int            integer        integer?       intersect      invert

irr            join           lambda?        last           legal?

length         let            letex          letn           list

list?          load           log            lookup         lower-case

macro?         main-args      make-dir       map            match

max            member         min            mod            mul

multiply       name           net-accept     net-close      net-connect

net-error      net-eval       net-listen     net-local      net-lookup

net-peek       net-peer       net-ping       net-receive    net-receive-from

net-receive-udp net-select     net-send       net-send-to    net-send-udp

net-service    net-sessions   new            nil?           normal

not            now            nper           npv            nth

nth-set        number?        open           or             pack

parse          peek           pipe           pmt            pop

post-url       pow            pretty-print   primitive?     print

println        prob-chi2      prob-z         process        push

put-url        pv             quote          quote?         rand

random         randomize      read-buffer    read-char      read-file

read-key       read-line      real-path      tested ok

ref

regex          remove-dir     rename-file    replace        replace-assoc

reset          rest           reverse        rotate         save

search         seed           seek           select         semaphore

sequence       series         set            set!           set-locale

set-nth        setq           sgn            share          signal

silent         sin            sleep          --- sleep duration: 1000 ---

slice          sort

source         sqrt           starts-with    string         string?

sub            swap           sym            symbol?        symbols

sys-error      sys-info       tan            throw          throw-error

time           time-of-day    timer          title-case     trace

trace-highlight transpose      trim           true?          unify

unique         unless         unpack         until          upper-case

uuid           wait-pid       while          write-buffer   write-char

write-file     write-line     xml-error      xml-parse      xml-type-tags

zero?          |              ~



Testing contexts as objects and scoping rules ...





ALL FUNCTIONS FINISHED SUCCESSFULL



total time: 5987

newLISP v.8.9.4 on Tru64Unix, execute 'newlisp -h' for more info.



> ring...




Peter

pjot

#3
Also in the file 'doc/TRU64BUILD' you still mention the file 'tru64.c':


Quote
Note that the tru64 version of newLISP limits the number of parameters in

(format fmt ...) to 32. This can be changed defining a different value for

MAX_FORMAT in tru64.c.


This part can be removed completely. There is no such limitation anymore.



Finally, the 'build' script mentions:


Quote
        OSF1)

                echo Discovered True64 Unix, please read doc/TRU64BUILD

                make -f makefile_tru64

                exit

                ;;


Please change to 'Discovered Tru64Unix' (without the 'e').



Many thanks!

Peter

newdep

#4
Hi Lutz,



I dont know how you manage it but the UUID I needed last week ;-)

(Therefor I create my own random ID generator but the uuid is nicer ;-)



I needed it for random file generation! very nice this enhancement..!



Thanks, Norman.



PS: compliments on the manual michael!
-- (define? (Cornflakes))

Lutz

#5
The & before the uuid->node definitely has to go, for some reason gcc did not complain about it on the systems I tried.



strtoll() was used, because I could not specify a long long (8 byte) hex constant, so I just converted from a string. Tru64 can probably specify the hex constant directly and you can get rid of the string conversion alltogether.



I made several other changes meanwhile, trying to stay closer to the spec when it comes to type 4 UUIDs, but still have to run tests on Win32.



Thanks for pointing out the things to change in some of the files for tru64, I will repost as 8.9.5 by the end of this week.



Lutz



to Norman: yes, UUIDs are very handy in many situations, file-ids, session-ids and zillions of other stuff. I am trying to get more DCE stuff into place, perhaps the next is an LDAP module?

pjot

#6
Many thanks! As soon as 8.9.5 is ready I'll check it out. :-)



Peter

starseed

#7
Quote from: "Lutz"to Norman: yes, UUIDs are very handy in many situations, file-ids, session-ids and zillions of other stuff. I am trying to get more DCE stuff into place, perhaps the next is an LDAP module?


And my nice gensym can be replaced by
(sym (uuid))

newdep

#8
>> perhaps the next is an LDAP module?



Instresting ;-) If youre able to build a module on this then a Module

for snmp-browsing or snmp-walk is very near ;-) (Which I like to

build in newlisp ;-)



Regards, Norman.
-- (define? (Cornflakes))

Lutz

#9
I was trying to compile OpenLDAP on OS X, but no luck for now, I will have a dedicated Linux/OpenBSD machine later this year, then I try again.



The API looks streight forward for implementing a lib-import module for in newLISP.



Lutz

Lutz

#10
Still problems with UUID generation, don't use it yet.



Lutz