openapp implemented.

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/tools/make/trunk@2500 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
ovidiu 1997-10-13 23:30:17 +00:00
parent c913ee332a
commit fec2adfd3d
8 changed files with 137 additions and 13 deletions

9
.cvsignore Normal file
View file

@ -0,0 +1,9 @@
config.log
config.make
config.cache
which_lib
Makefile
GNUstep.sh
config.h
config.status
openapp

View file

@ -1,3 +1,12 @@
Mon Oct 13 16:06:12 1997 Ovidiu Predescu <ovidiu@net-community.com>
* openapp.in: New file.
* GNUstep.sh.in: Added $GNUSTEP_SYSTEM_ROOT/Tools to the PATH.
* Makefile.in: Install openapp in $GNUSTEP_SYSTEM_ROOT/Tools.
* configure.in: Create openapp.
* ld_lib_path.sh: Changed to export the library path for different
systems.
Mon Oct 13 12:21:59 1997 Ovidiu Predescu <ovidiu@net-community.com>
* configure.in: Check to see if a DPS directory exists inside the X11

View file

@ -46,6 +46,7 @@ export GNUSTEP_HOST GNUSTEP_HOST_CPU GNUSTEP_HOST_VENDOR GNUSTEP_HOST_OS
#
# Add the GNUstep tools directories to the path
#
PATH=$GNUSTEP_SYSTEM_ROOT/Tools:$PATH
PATH=$GNUSTEP_SYSTEM_ROOT/Tools/$GNUSTEP_HOST_CPU/$GNUSTEP_HOST_OS:$PATH
PATH=$GNUSTEP_LOCAL_ROOT/Tools/$GNUSTEP_HOST_CPU/$GNUSTEP_HOST_OS:$PATH
PATH=$GNUSTEP_USER_ROOT/Tools/$GNUSTEP_HOST_CPU/$GNUSTEP_HOST_OS:$PATH

View file

@ -44,6 +44,7 @@ GNUSTEP_TARGET_VENDOR := $(shell ./clean_vendor.sh $(GNUSTEP_TARGET_VENDOR))
GNUSTEP_TARGET_OS := $(shell ./clean_os.sh $(GNUSTEP_TARGET_OS))
makedir = $(prefix)/Makefiles
tooldir = $(prefix)/Tools
GNUSTEP_TARGET_DIR = $(GNUSTEP_TARGET_CPU)/$(GNUSTEP_TARGET_OS)
INSTALL = @INSTALL@
@ -59,11 +60,13 @@ install: all
$(srcdir)/mkinstalldirs $(prefix) $(makedir) \
$(makedir)/$(GNUSTEP_TARGET_CPU) \
$(makedir)/$(GNUSTEP_TARGET_DIR) \
$(tooldir) \
$(prefix)/share
$(INSTALL_PROGRAM) -m 755 which_lib $(makedir)/$(GNUSTEP_TARGET_DIR)
for f in config.guess config.sub install-sh mkinstalldirs *.sh; do \
$(INSTALL_PROGRAM) -m 755 $$f $(makedir); \
done
$(INSTALL_PROGRAM) -m 755 openapp $(tooldir); \
for f in aggregate.make application.make bundle.make clean.make \
common.make core.make library.make rules.make target.make \
tool.make test.make MediaBook.func; do \

4
configure vendored
View file

@ -1576,7 +1576,7 @@ done
ac_given_srcdir=$srcdir
ac_given_INSTALL="$INSTALL"
trap 'rm -fr `echo "config.h config.make Makefile GNUstep.sh config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
trap 'rm -fr `echo "config.h config.make openapp Makefile GNUstep.sh config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
EOF
cat >> $CONFIG_STATUS <<EOF
@ -1672,7 +1672,7 @@ EOF
cat >> $CONFIG_STATUS <<EOF
CONFIG_FILES=\${CONFIG_FILES-"config.h config.make Makefile GNUstep.sh"}
CONFIG_FILES=\${CONFIG_FILES-"config.h config.make openapp Makefile GNUstep.sh"}
EOF
cat >> $CONFIG_STATUS <<\EOF
for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then

View file

@ -108,4 +108,4 @@ AC_SUBST(ac_cv_library_combo)
#--------------------------------------------------------------------
# Produce the output files
#--------------------------------------------------------------------
AC_OUTPUT(config.h config.make Makefile GNUstep.sh)
AC_OUTPUT(config.h config.make openapp Makefile GNUstep.sh)

View file

@ -8,7 +8,7 @@
# Copyright (C) 1997 Free Software Foundation, Inc.
#
# Author: Scott Christley <scottc@net-community.com>
#
# Author: Ovidiu Predescu <ovidiu@net-community.com>
# This file is part of the GNUstep Makefile Package.
#
# This library is free software; you can redistribute it and/or
@ -23,17 +23,37 @@
#
# The first (and only) parameter to this script is the canonical
# operating system name
# operating system name. If the environment variable export_variable
# is not set to `yes' it prints the name of the variable whose
# value keeps the paths searched for libraries
# LD_LIBRARY_PATH is the default name
ld_lib_path="LD_LIBRARY_PATH"
last_path_part=Libraries/$GNUSTEP_HOST_CPU/$GNUSTEP_HOST_OS/$library_combo
case "$1" in
host_os=$GNUSTEP_HOST_OS
*nextstep4*)
ld_lib_path="DYLD_LIBRARY_PATH"
;;
if [ -z "$host_os" ]; then
host_os=$1
fi
esac
case "$host_os" in
echo $ld_lib_path
*nextstep4*)
ld_lib_path="DYLD_LIBRARY_PATH"
DYLD_LIBRARY_PATH="$GNUSTEP_USER_ROOT/$last_path_part:$GNUSTEP_LOCAL_ROOT/$last_path_part:$GNUSTEP_SYSTEM_ROOT/$last_path_part:$DYLD_LIBRARY_PATH"
export DYLD_LIBRARY_PATH;;
*solaris*)
ld_lib_path="LD_LIBRARY_PATH"
LD_LIBRARY_PATH="$GNUSTEP_USER_ROOT/$last_path_part;$GNUSTEP_LOCAL_ROOT/$last_path_part;$GNUSTEP_SYSTEM_ROOT/$last_path_part;$LD_LIBRARY_PATH"
export LD_LIBRARY_PATH;;
*)
ld_lib_path="LD_LIBRARY_PATH"
LD_LIBRARY_PATH="$GNUSTEP_USER_ROOT/$last_path_part:$GNUSTEP_LOCAL_ROOT/$last_path_part:$GNUSTEP_SYSTEM_ROOT/$last_path_part:$LD_LIBRARY_PATH"
export LD_LIBRARY_PATH;;
esac
if [ "$export_variable" != yes ]; then
echo $ld_lib_path
fi

82
openapp.in Executable file
View file

@ -0,0 +1,82 @@
#!/bin/sh
#
# Copyright (C) 1997 Free Software Foundation, Inc.
#
# Author: Ovidiu Predescu <ovidiu@net-community.com>
# Date: October 1997
#
# This file is part of the GNUstep Makefile Package.
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# You should have received a copy of the GNU General Public
# License along with this library; see the file COPYING.LIB.
# If not, write to the Free Software Foundation,
# 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
# Try to execute the application passed as argument. The application is
# searched through the GNUstep directories if a complete or relative path name
# is not specified.
if [ -z "$1" ]; then
echo usage: `basename $0` [--library-combo=...] application
exit 1
fi
library_combo=@ac_cv_library_combo@
while [ -n "$*" ]; do
case $1 in
--library-combo=*) library_combo=`echo $1 | sed 's/--library-combo=//'`;;
*) app=$1;;
esac
shift
done
case $app in
/*) # An absolute path.
full_appname=$app;;
*/*) # A relative path
full_appname=`(cd $app; pwd)`;;
*) # A path that should be searched into the GNUstep paths
SPATH=.:$GNUSTEP_USER_ROOT/Apps:$GNUSTEP_LOCAL_ROOT/Apps:$GNUSTEP_SYSTEM_ROOT/Apps:$PATH
IFS=:
for dir in $SPATH; do
if [ -d $dir/$app ]; then
full_appname=`(cd $dir/$app; pwd)`
break;
fi
done;;
esac
appname=`echo $app | sed 's/\.[a-z]*$//'`
export_variable=yes . $GNUSTEP_SYSTEM_ROOT/Makefiles/ld_lib_path.sh
if [ "$library_combo" = nx_nx_nx_nil -a $GNUSTEP_HOST_OS = nextstep4 ]; then
if [ ! -d $full_appname/$appname ]; then
echo "$full_appname application does not have a binary for this kind of machine and operating system."
exit 1
fi
exec $full_appname/$appname
else
# Determine if the application has a binary for this operating system
if [ ! -d $full_appname/$GNUSTEP_HOST_CPU/$GNUSTEP_HOST_OS ]; then
echo "$full_appname application does not have a binary for this kind of machine and operating system."
exit 1
fi
if [ ! -d $full_appname/$GNUSTEP_HOST_CPU/$GNUSTEP_HOST_OS/$library_combo ]; then
echo "$full_appname application does not have a binary for this combination of libraries ($library_combo)."
exit 1
fi
exec $full_appname/$GNUSTEP_HOST_CPU/$GNUSTEP_HOST_OS/$library_combo/$appname
fi
echo "Cannot exec the specified application!"