From: Götz Lindenmaier Date: Tue, 5 Nov 2002 16:48:54 +0000 (+0000) Subject: moved to dir firmjnk X-Git-Url: http://nsz.repo.hu/git/?a=commitdiff_plain;h=132d4be41c2f47bdd4ce3d8eba70dbf8c5e128ef;p=libfirm moved to dir firmjnk [r515] --- diff --git a/tools/Makefile b/tools/Makefile deleted file mode 100644 index b2563370f..000000000 --- a/tools/Makefile +++ /dev/null @@ -1,40 +0,0 @@ - - - -LIBNAME = libfirmjni.so - -.PHONY: default all clean realclean depend - - - -MEMBERS = Firm.m Firm.m Firm_common.m Dbginfo.m Ident.m Tv.m \ - Type.m Entity.m Type_or_entity.m Tpop.m Mangle.m \ - Irprog.m Irgraph.m Irnode.m Irmode.m Irop.m Ircons.m Ircgcons.m Irflag.m Irvrfy.m \ - Irdump.m Iropt.m Irgopt.m Ircgopt.m \ - Irouts.m Irdom.m Irloop.m Cgana.m \ - Irgwalk.m Irgmod.m Typewalk.m Typegmod.m - -OFILES = $(MEMBERS:.m=.o) -HFILES = $(MEMBERS:.m=.h) - -all: lib - -%.class: %.java - javac $< - -%.h: %.class - javah $(<:.class=) - -cp Firm_0005fcommon.h Firm_common.h - -cp Type_0005for_0005fentity.h Type_or_entity.h - -%.o: %.c %.h - gcc $(CPPFLAGS) -c $< -o $@ - -lib: $(HFILES) $(OFILES) - gcc -shared -fPIC -o $(LIBNAME) *.o /ben/goetz/proj/libfirm/i686/libfirm.a - -clean: -# rm -f *.class $(JHFILES) *.o $(JCFILES) $(JOFILES) $(CLSFILES) $(JFILES) - -realclean: clean -# rm -f *~ libfirmjni.a libfirmjni.so *.vcg diff --git a/tools/build_firm_jni b/tools/build_firm_jni deleted file mode 100755 index f8f285577..000000000 --- a/tools/build_firm_jni +++ /dev/null @@ -1,136 +0,0 @@ -#!/bin/sh - -# Project: FIRM -# File name: script/build_firm_jni -# Purpose: skript to build a java native interface for the public headers of firm. -# Author: Goetz Lindenmaier -# Modified by: -# Created: 30.10.2002 -# CVS-ID: $Id$ -# Copyright: (c) 2002 Universität Karlsruhe -# Licence: - - -############################################################################### -# Set this variable to the directory which shall contain the JNI implementation -FIRM_JNI_DIR=/ben/goetz/proj/libfirm/firm-jni/ - -# Set these directories to point to a libfirm installation: - -FIRM_INCLUDE_DIR=/ben/goetz/proj/libfirm/i686/include -FIRM_LIB_DIR=/ben/goetz/proj/libfirm/i686 -FIRM_JNI_TOOLS_DIR=/ben/goetz/proj/libfirm/firm-jni/tools - -# Set this directory to a directory with sufficient space. -WORK_DIR=/ben/goetz/proj/libfirm/firm-jni/tmp - -# This is the list of firm headers a JNI interface is generated for -FIRM_HEADERS="firm.h firm_common.h dbginfo.h ident.h tv.h - type.h entity.h type_or_entity.h tpop.h mangle.h - irprog.h irgraph.h irnode.h irmode.h irop.h ircons.h ircgcons.h irflag.h irvrfy.h - irdump.h iropt.h irgopt.h ircgopt.h - irouts.h irdom.h irloop.h cgana.h - irgwalk.h irgmod.h typewalk.h typegmod.h" - -############################################################################### - -CURRENT_DIR=$PWD -SOURCE_DIR=sources -PUREC_DIR=purec - -MACHINE=`uname -m` -SYS_OS=`uname -s` -ARCH_DIR=$MACHINE-$SYS_OS - -LOG_FILE=compile-log.txt - -REMOVE_CPP_COMMANDS=$FIRM_JNI_TOOLS_DIR/remove_cpp_comands.perl - -# -# shell initialization -# -source /afs/info.uni-karlsruhe.de/public/tools/Modules/init/sh - -# -# flags -# -verbose="" - -# -# set up directories -# -rm -rf $WORK_DIR -mkdir -p $WORK_DIR -cd $WORK_DIR - -############################################################################### - -analargs () { - while [ $# -gt 0 ]; do - case $1 in - --verbose) verbose="y";; - *) echo "Unknown option "$1;; - esac - shift - done -} - -analargs $* - -############################################################################### - - -############################################################################### -# Get all the necessary Firm headers. -cd $WORK_DIR - -mkdir $PUREC_DIR -mkdir $SOURCE_DIR - -for file in $FIRM_HEADERS; do - cp $FIRM_INCLUDE_DIR/$file $SOURCE_DIR -done; - -cd $SOURCE_DIR - - -############################################################################### -# Remove C preprocessor commands. Overwrite the header files. -# This part should be removed if crecoder integrates the preprocessor. - -rm -f firm_typedefs.h -for file in $FIRM_HEADERS; do - perl $REMOVE_CPP_COMMANDS $file -done; - -for file in $FIRM_HEADERS; do - gcc -E -C -P $file -o ../$PUREC_DIR/$file -done; - -cd ../$PUREC_DIR - - -############################################################################### -# Call crecoder to construct from each header a .java file specifying the -# java native interface. Further crecoder constructs an implementation of -# the java native interface in C calling the real libfirm functions. -# For a file "file.h" files "File.java" and "File.c" are generated. - -module add jdk-1.3.1-sun -export CLASSPATH=$FIRM_JNI_TOOLS_DIR/crecoder.jar:$CLASSPATH -for file in $FIRM_HEADERS; do - java crecoder/tools/jniBuilder/BuildJNI $file -done; - -# Remove the C headers which are no more needed. They contain -# nonsense no C compiler ever should see ;-) -rm -f $FIRM_HEADERS -# Make the JNI Implementation - -export CPPFLAGS="-I. -I/usr/public2/java/jdk1.3-sun/include/ -I/usr/public2/java/jdk1.3-sun/include/linux/ -I$FIRM_INCLUDE_DIR" -export LDFLAGS="-L$FIRM_LIB_DIR" - -make -f $FIRM_JNI_TOOLS_DIR/Makefile -mv libfirmjni.so $FIRM_JNI_DIR - -#mv *.java *.class $FIRM_JNI_DIR diff --git a/tools/crecoder.jar b/tools/crecoder.jar index 945092155..d74d66ab7 100644 Binary files a/tools/crecoder.jar and b/tools/crecoder.jar differ