I'd like to resume working on the Python->Parrot translator, and am
wondering where to put the PMCs I'll have to write.  I'm reluctant to
add them to classes/, because that's not going to scale.  So, how are
future Parrot-based languages going to be distributed?  

A fairly simple way might be to install a libparrot.{a,so} which
contains the Parrot interpreter.  (The Makefile already has a target
for libparrot.so, but doesn't install it.)  The distribution for my
language will then compile its PMCs and have a little main() program
that registers my PMCs, initializes the interpreter, and off it goes!
Seem reasonable?

The following bits, added to the Makefile, would install the headers
and library, but I don't know the configuration machinery well enough
to make them use the right paths.  Does someone want to fix this up
and add it to the Makefile.in?

--amk

INCL_DIR=/usr/local/include/parrot
INSTALL=/usr/bin/install -c
INSTALL_DATA= $(INSTALL) -m 644
INSTALL_SHARED= $(INSTALL) -m 555
DIRMODE=755

install: libinstall inclinstall

libinstall:
        $(INSTALL_SHARED) libparrot.so /usr/local/lib/


inclinstall:
        if test ! -d $(INCL_DIR) ; then \
                echo 'Creating directory $(INCL_DIR)'; \
                $(INSTALL) -d -m $(DIRMODE) $(INCL_DIR); \
        fi 
        for file in $(H_FILES) ; do \
                $(INSTALL_DATA) $$file $(INCL_DIR) ; \
        done 






Reply via email to