-Wname=axiom

View: New views
2 Messages — Rating Filter:   Alert me  

-Wname=axiom

by Ralf Hemmecke :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Dear Peter,

in libaxiom.mk I found a line like

$(spad_ao_files): extra_ao_options:=-Wname=axiom -Mno-abbrev -Mpreview

If everything goes fine the -M options should be considered as optional,
but what does -Wname=axiom actually do?

   -W name=<name>  Compile file as if it was called <name>.as.

And more important... why have you written it there? I cannot figure out
why renaming during compilation (and this only for the axiom domains)
would have any influence on the resulting .ao file.

The command is:

   aldor $(extra_ao_options) -Y $(ALDOR_INT)/tmp \
     -L AxiomLib=axiom_$* -fao=$@ $(ALDOR_INT)/ap/$*.ap"

This extra_ao_options somehow distinguishes between the .ap files that
come from the Axiom library and the .ap files originating from axlit.as
axextend.as, lang.as, minimach.as etc.

Why is this difference?

Ralf

_______________________________________________
Aldor-l mailing list
Aldor-l@...
http://aldor.org/mailman/listinfo/aldor-l_aldor.org

Parent Message unknown Re: -Wname=axiom

by Ralf Hemmecke :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On 06/06/2008 01:58 PM, Peter Broadbery wrote:

> On Fri, Jun 6, 2008 at 12:29 PM, Ralf Hemmecke <ralf@...> wrote:
>> Dear Peter,
>>
>> in libaxiom.mk I found a line like
>>
>> $(spad_ao_files): extra_ao_options:=-Wname=axiom -Mno-abbrev -Mpreview
>>
>> If everything goes fine the -M options should be considered as optional, but
>> what does -Wname=axiom actually do?
>>
>>  -W name=<name>  Compile file as if it was called <name>.as.
>>
>> And more important... why have you written it there? I cannot figure out why
>> renaming during compilation (and this only for the axiom domains) would have
>> any influence on the resulting .ao file.
>>
>
> When aldor compiles a file that uses libaxiom to .lsp, it'll need to
> refer to both axiom and aldor types.  To distinguish them, the axiom
> ones all claim to come from a file called 'axiom'.  The interopability
> code (daase.lisp, probably) then treats these specially.
> It's not needed for compilation, but rather required if you want to
> have the result be useful in axiom.

Just a quick look into src/interp/daase.lisp shows the lines below. I
guess the ^^^^^ mark the place where -Wname=axiom correspond to, right?
But, hey, it also seems to show that I cannot move the code of axlit and
axextend into one file and have another name for it.

And what is runtime? I don't think that it is was in src_aldor3.tgz
http://sage.math.washington.edu/home/page/src_aldor3.tgz .

Should I take it from axllib?

Ralf

---BEGIN
; the variable NOPfuncall is a funcall-able object that is a dummy
; initializer for libaxiom asharp domains.
(defvar NOPfuncall (cons 'identity nil))

(defun create-initializers ()
;; since libaxiom is now built with -name=axiom following unnecessary
;; (dolist (con (|allConstructors|))
;;   (let ((sourcefile (getdatabase con 'sourcefile)))
;;     (if sourcefile
;;       (set (foam::axiomxl-file-init-name (pathname-name sourcefile))
;;             NOPfuncall))))
  (set (foam::axiomxl-file-init-name "axiom") NOPfuncall)
                                      ^^^^^
;; (set (foam::axiomxl-file-init-name "axclique") NOPfuncall)
  (set (foam::axiomxl-file-init-name "filecliq") NOPfuncall)
  (set (foam::axiomxl-file-init-name "attrib") NOPfuncall)
;; following needs to happen inside restart since $AXIOM may change
  (let ((asharprootlib (strconc (|getEnv| "AXIOM") "/aldor/lib/")))
    (set-file-getter (strconc asharprootlib "runtime"))
    (set-file-getter (strconc asharprootlib "lang"))
    (set-file-getter (strconc asharprootlib "attrib"))
    (set-file-getter (strconc asharprootlib "axlit"))
    (set-file-getter (strconc asharprootlib "minimach"))
    (set-file-getter (strconc asharprootlib "axextend"))))
---END

_______________________________________________
Aldor-l mailing list
Aldor-l@...
http://aldor.org/mailman/listinfo/aldor-l_aldor.org
LightInTheBox - Buy quality products at wholesale price