#!/bin/sh # Set up the environment . set_aliases OLD_PATH=$PATH INIT_DIR=`pwd` EIFFEL_SRC=$EXPORT_DIR; export EIFFEL_SRC ISE_LIBRARY=$EXPORT_DIR; export ISE_LIBRARY ISE_EIFFEL=$FINAL_INSTALL_DIR; export ISE_EIFFEL INSTALL_DIR=$FINAL_INSTALL_DIR echo > $COMPILE_LOG if [ -z "$ISE_PLATFORM" ]; then remtrace Couldnt find environment variable ISE_PLATFORM CANCEL fi # Check everything's fine if [ ! -d $EXPORT_DIR ]; then remtrace Couldnt find the directory with the tgzs. CANCEL fi if [ -f ec_ent.tar.gz ]; then MULTIPLE_EDITIONS="True" else MULTIPLE_EDITIONS="" fi remtrace Compile C code of the libraries remtrace \"A tout seigneur tout honneur\", let\'s start with the run-time if [ ! -f c.tar.gz ]; then remtrace 'No.tar.gz for the C directory' CANCEL fi fullrd C gunzip -c c.tar.gz | tar -xf - if [ ! -d C ]; then remtrace No C directory CANCEL fi remtrace Compile a commercial run-time cd $EXPORT_DIR fullrd C gunzip -c c.tar.gz | tar -xf - cd C . quick_configure >> $COMPILE_LOG safe_md $EXPORT_DIR/runtimes cp run-time/*.so $EXPORT_DIR/runtimes cp run-time/*.a $EXPORT_DIR/runtimes if [ ! -f $EXPORT_DIR/runtimes/libwkbench.a ]; then remtrace Couldnt generate the run-time CANCEL else if [ ! -f $EXPORT_DIR/runtimes/libwkbench.so ]; then remtrace Couldnt generate the run-time CANCEL fi fi cd $EXPORT_DIR remtrace Extract the delivery if [ ! -f delivery.tar.gz ]; then remtrace 'No.tar.gz of the delivery' CANCEL else remtrace Delivery if [ -d $INSTALL_DIR ]; then fullrd $INSTALL_DIR fi safe_md $INSTALL_DIR if [ ! -d $INSTALL_DIR ]; then remtrace Cannot create $INSTALL_DIR CANCEL fi cd $INSTALL_DIR gunzip -c $EXPORT_DIR/delivery.tar.gz | tar -xf - fi cd $EXPORT_DIR #These directories should have been created by make_delivery. safe_md $INSTALL_DIR/studio/spec/unix/include safe_md $INSTALL_DIR/studio/spec/unix/bin mv $INSTALL_DIR/studio/spec/unix/*re* $INSTALL_DIR/studio/spec/unix/bin safe_md $INSTALL_DIR/studio/spec/unix/lib safe_md $INSTALL_DIR/studio/config/$ISE_PLATFORM fullrd $INSTALL_DIR/studio/spec/$ISE_PLATFORM safe_md $INSTALL_DIR/studio/spec/$ISE_PLATFORM move $INSTALL_DIR/studio/config/unix/* $INSTALL_DIR/studio/config/$ISE_PLATFORM move $INSTALL_DIR/studio/spec/unix/* $INSTALL_DIR/studio/spec/$ISE_PLATFORM mv $INSTALL_DIR/precomp/spec/platform $INSTALL_DIR/precomp/spec/$ISE_PLATFORM fullrd $INSTALL_DIR/studio/config/unix fullrd $INSTALL_DIR/studio/spec/unix cp C/run-time/lib*.a $INSTALL_DIR/studio/spec/$ISE_PLATFORM/lib mac_ranlib $INSTALL_DIR/studio/spec/$ISE_PLATFORM/lib/libmtfinalized.a mac_ranlib $INSTALL_DIR/studio/spec/$ISE_PLATFORM/lib/libmtwkbench.a mac_ranlib $INSTALL_DIR/studio/spec/$ISE_PLATFORM/lib/libfinalized.a mac_ranlib $INSTALL_DIR/studio/spec/$ISE_PLATFORM/lib/libwkbench.a cp C/run-time/lib*.so $INSTALL_DIR/studio/spec/$ISE_PLATFORM/lib fullrf $EXPORT_DIR/runtimes/libebench.a cp C/run-time/*.h $INSTALL_DIR/studio/spec/$ISE_PLATFORM/include cp C/config.sh $INSTALL_DIR/studio/spec/$ISE_PLATFORM/include remtrace "Put x2c in the new delivery" # It should already have been compiled by the configure of the run-time. cd $EXPORT_DIR/C/run-time if [ ! -f x2c ]; then echo Could not finalize a new x2c CANCEL fi move x2c $INSTALL_DIR/studio/spec/$ISE_PLATFORM/bin remtrace Recompile quick_finalize cd $EXPORT_DIR untgz_ccode quick_finalize move quick_finalize $INSTALL_DIR/studio/spec/$ISE_PLATFORM/bin remtrace "Put estudio in the new delivery" # It should already have been compiled by the configure of the run-time. cd $EXPORT_DIR/C/ipc/daemon if [ ! -f estudio ]; then echo Could not finalize a new estudio CANCEL fi move estudio $INSTALL_DIR/studio/spec/$ISE_PLATFORM/bin remtrace Then the Eiffel libraries cd $EXPORT_DIR if [ ! -f libs.tar.gz ]; then remtrace 'No.tar.gz for the library directory' CANCEL fi gunzip -c libs.tar.gz | tar -xf - if [ ! -d library ]; then remtrace No library directory CANCEL fi remtrace Then the C libraries if [ ! -f c_libs.tar.gz ]; then remtrace 'No.tar.gz for the C_library directory' CANCEL fi gunzip -c c_libs.tar.gz | tar -xf - if [ ! -d C_library ]; then remtrace No C_library directory CANCEL fi cd $EXPORT_DIR . compile_libraries cd $INSTALL_DIR . $EXPORT_DIR/compile_libraries remtrace Build move $INSTALL_DIR/build/spec/unix $INSTALL_DIR/build/spec/$ISE_PLATFORM cd $EXPORT_DIR/build untgz_ccode build cp build $INSTALL_DIR/build/spec/$ISE_PLATFORM/bin/ gzip build remtrace Vision2_tour cd $EXPORT_DIR/vision2_tour safe_md $INSTALL_DIR/vision2_tour/spec safe_md $INSTALL_DIR/vision2_tour/spec/$ISE_PLATFORM safe_md $INSTALL_DIR/vision2_tour/spec/$ISE_PLATFORM/bin untgz_ccode vision2_tour move vision2_tour $INSTALL_DIR/vision2_tour/spec/$ISE_PLATFORM/bin if [ "$MULTIPLE_EDITIONS" ]; then remtrace Recompile CD key validator cd $EXPORT_DIR untgz_ccode setup fi remtrace Recompile EiffelStudio cd $EXPORT_DIR safe_md $EXPORT_DIR/ecs remtrace GPL edition cp ec_gpl.tar.gz ec.tar.gz untgz_ccode ec gzip ec move ec.gz $EXPORT_DIR/ecs/ec_gpl.gz if [ -z "$MULTIPLE_EDITIONS" ]; then gunzip -c $EXPORT_DIR/ecs/ec_gpl.gz > $INSTALL_DIR/studio/spec/$ISE_PLATFORM/bin/ec else remtrace GPL edition cp ec_ent.tar.gz ec.tar.gz move ec_ent.tar.gz ec.tar.gz untgz_ccode ec gzip ec move ec.gz $EXPORT_DIR/ecs/ec_ent.gz fi cd $EXPORT_DIR . compile_wizards if [ ! -z "$MULTIPLE_EDITIONS" ]; then fullrf $INSTALL_DIR/studio/spec/$ISE_PLATFORM/lib/*.a fullrf $INSTALL_DIR/studio/spec/$ISE_PLATFORM/lib/*.so fi CANCEL