Question & Answer
Question
How do you change the default IBM Rational Rhapsody rhapsody.exe.ini for multiple users?
Cause
Each time you start Rational Rhapsody, the ~/.mw directory is created. This directory contains the rhapsody.exe.ini file which in turn contains specific settings for the running instance of Rhapsody.
Occasionally an administrator may need to alter this file.
To do this, it is necessary to look more closely at how Rhapsody is started on Linux.
Answer
The rhp_env script:
When you execute RhapsodyInCpp, RhapsodyInC..., the rhp_env script is called just before starting Rhapsody.
This script checks if the ~/.mw directory exists (as well as setting up several aspects of the Linux and mainwin environment).
If the script determines the directory does not exist, it creates the directory and the rhapsody.exe.ini file and defines the main body of the ini file.
Any changes made here will precipitate to each user of this server.
Example rhp_env script:
# If you don't have a windows/rhapsody.exe.ini
# Create one with a port for Animation in it!!
echo "[General]" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
echo "#OMROOT=$RHPDIR" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
echo "RY_LICENSE_FILE=$RHPDIR/flexlm/license.dat" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
echo "ProjectsDirectory=$RHPDIR" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
echo "AdditinalPath=" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
echo "OMHELPROOT=$OMHELPROOT" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
echo "OMDOCROOT=$OMDOCROOT" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
# Make up a unique socket number for animation"
# ID=`/xpg4/bin/id -u`
ID=0
ID=`expr $ID + 6423` # 6423 is our standard socket..
echo "AnimationPortNumber=$ID" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
echo "DefaultEdition=Developer" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
echo "DefaultLanguage=C++" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
echo "#RY_LICENSE_STR=" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
echo "[RER]" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
echo "RER_ENABLED=TRUE" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
echo "RER_DIR=$RER_DIR" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
echo "[Tip]" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
echo "StartUp=1" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
if [ $IsEclipseSelected = "TRUE" ]
then
echo "[IDE]" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
echo "EclipsePath=/usr/eclipse/eclipse" >>$HOME/$MWUSERDIR/rhapsody.exe.ini
fi
The helper scripts:
Each Rhapsody add-on is defined in the helper section by individual helper scripts.
if [ $IsXMIToolkitSelected = "TRUE" ]
then
sh $RHPDIR/Sodius/XMI_Toolkit/addHelpers.sh
fi
if [ $IsGatewaySelected = "TRUE" ]
then
pushd $RHPDIR/Gateway/bin.pclinux
perl add_gateway_helper.pl
popd
fi
if [ $IsTCSelected = "TRUE" ]
then
sh $RHPDIR/TestConductor/adapt_ini.sh $RHPDIR
fi
These subsequent scripts can also be edited to alter the finished rhapsody.exe.ini file.
Product Synonym
Rational Rhapsody
Was this topic helpful?
Document Information
Modified date:
27 May 2022
UID
swg21391638