/* REXX utility to create an emx folder an appropriate program objects. Special Thanks to Eberhard Mattes, for making emx possible. emx 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, or (at your option) any later version. emx is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with emx; see the file COPYING. If not, write to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA */ SAY "" SAY "Copyright (c) James Cannon, Bangkok OS/2 User Group" SAY "" /* Query user to find install path for emx: */ SAY "Which drive did you install to (C:\emx, D:\dev\emx, etc.)?" SAY "" PARSE PULL drive SAY "You entered: " drive SAY "" IF drive = " " THEN DO SAY "Invalid entry" SAY "" SAY "Valid choices: C:\..\ or D:\..\ ... " SAY "" END ELSE /* Required calls to create objects: */ call RxFuncAdd 'SysLoadFuncs', 'RexxUtil', 'SysLoadFuncs' call SysLoadFuncs /* Create the emx folder on the OS/2 Desktop: */ title = "emx C/C++"||"0a"x||"Programming" class = "WPFolder" Location = "" SetupString =, "OBJECTID=;" ||, "ICONVIEW=FLOWED;" ||, "WORKAREA=YES;" ||, "OPEN=ICON;" rc = SysCreateObject(class, title, Location, SetupString, "update") IF (rc == 0) THEN SAY "**** emx Folder create failed! ****" ELSE SAY "emx Folder successfully created." /* Create the emx Command Window: */ title = "emx Command"||"0a"x||"Window" class = "WPProgram" Location = "" SetupString =, "PROGTYPE=WINDOWABLEVIO;" ||, "EXENAME=*;" ||, "PARAMETERS=/k "||drive||"\emx.cmd;" ||, "STARTUPDIR="||drive||";" rc = SysCreateObject(class, title, Location, SetupString, "update") IF (rc == 0) THEN SAY "**** emx Command Window create failed! ****" ELSE SAY "emx Command Window successfully created." /* Create the emx Code Editor: */ title = "emx Code"||"0a"x||"Editor" class = "WPProgram" Location = "" SetupString =, "PROGTYPE=PM;" ||, "EXENAME=EPM.EXE;" ||, "STARTUPDIR="||drive||";" ||, "ASSOCFILTER=*.C,*.CC,*.H,*.RC;" rc = SysCreateObject(class, title, Location, SetupString, "update") IF (rc == 0) THEN SAY "**** emx Code Editor create failed! ****" ELSE SAY "emx Code Editor successfully created." /* Create the emx Runtime User's Guide: */ title = "Users Guide to"||"0a"x||"the emx Runtime" class = "WPProgram" Location = "" SetupString =, "PROGTYPE=PM;" ||, "EXENAME=VIEW.EXE;" ||, "PARAMETERS="||drive||"\book\emxrt.inf;" ||, "STARTUPDIR="||drive||"\book;" rc = SysCreateObject(class, title, Location, SetupString, "update") IF (rc == 0) THEN SAY "**** emx Runtime Guide create failed! ****" ELSE SAY "emx Runtime Guide successfully created." /* Create emx Library reference: */ title = "emx 0.9c C"||"0a"x||"Library Reference" class = "WPProgram" Location = "" SetupString =, "PROGTYPE=PM;" ||, "EXENAME=VIEW.EXE;" ||, "PARAMETERS="||drive||"\book\emxlib.inf;" ||, "STARTUPDIR="||drive||"\book;" rc = SysCreateObject(class, title, Location, SetupString, "update") IF (rc == 0) THEN SAY "**** emx Library Reference create failed! ****" ELSE SAY "emx Library Reference successfully created." /* Create GNU Development Tools Information: */ title = "GNU Development"||"0a"x||"Tools Information" class = "WPProgram" Location = "" SetupString =, "PROGTYPE=PM;" ||, "EXENAME=VIEW.EXE;" ||, "PARAMETERS="||drive||"\book\emxgnu.inf;" ||, "STARTUPDIR="||drive||"\book;" rc = SysCreateObject(class, title, Location, SetupString, "update") IF (rc == 0) THEN SAY "**** GNU Development Tools Information create failed! ****" ELSE SAY "GNU Development Tools Information successfully created." /* Create emx Application Developers Guide" */ title = "emx 0.9c Application"||"0a"x||"Developers Guide" class = "WPProgram" Location = "" SetupString =, "PROGTYPE=PM;" ||, "EXENAME=VIEW.EXE;" ||, "PARAMETERS="||drive||"\book\emxdev.inf;" ||, "STARTUPDIR="||drive||"\book;" rc = SysCreateObject(class, title, Location, SetupString, "update") IF (rc == 0) THEN SAY "**** emx 0.9c Application Developers Guide create failed! ****" ELSE SAY "emx 0.9c Application Developers Guide successfully created." /* Create BSD Libraries Documentation: */ title = "BSD Libraries"||"0a"x||"Information" class = "WPProgram" Location = "" SetupString =, "PROGTYPE=PM;" ||, "EXENAME=VIEW.EXE;" ||, "PARAMETERS="||drive||"\book\emxbsd.inf;" ||, "STARTUPDIR="||drive||"\book;" rc = SysCreateObject(class, title, Location, SetupString, "update") IF (rc == 0) THEN SAY "**** BSD Libraries Information Guide create failed! ****" ELSE SAY "BSD Libraries Information Guide successfully created." SAY "" SAY "END REXX SCRIPT" SAY "******************************************************" EXIT