Home My Page Projects Code Snippets Project Openings SML/NJ
Summary Activity Forums Tracker Lists Tasks Docs Surveys News SCM Files

SCM Repository

[smlnj] Annotation of /config/trunk/ml-build.bat
ViewVC logotype

Annotation of /config/trunk/ml-build.bat

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2680 - (view) (download) (as text)

1 : blume 2088 @echo off
2 :    
3 : blume 2680 set flags=
4 :     set setup=
5 : blume 2503
6 :     :DOFLAGS
7 :    
8 :     if %1 == -D goto FOUNDFLAG
9 :     if %1 == -U goto FOUNDFLAG
10 :     if %1 == -C goto FOUNDFLAG
11 :     if %1 == -S goto FOUNDSETUP
12 :     goto DONEFLAGS
13 :    
14 :     :FOUNDFLAG
15 :    
16 : blume 2507 set flags=%flags% %1%2
17 : blume 2503 shift
18 :     shift
19 :     goto DOFLAGS
20 :    
21 :     :FOUNDSETUP
22 :    
23 :     set setup=%2
24 :     shift
25 :     shift
26 :     goto DOFLAGS
27 :    
28 :     :DONEFLAGS
29 :    
30 :     set root=%1
31 :     set main=%2
32 :     set heap=%3
33 :    
34 : blume 2088 set smlfile=XYZ_XXX_smlfile.sml
35 :     set cmfile=XYZ_XXX_cmfile.cm
36 :     set listfile=XYZ_XXX_BOOTLIST
37 :     set linkargsfile=XYZ_XXX_LINKARGS
38 :    
39 :     set rare=XYZ_XXX_0123
40 :    
41 :     echo structure %rare% = struct val _ = SMLofNJ.exportFn ("%heap%", %main%) end >"%smlfile%"
42 :    
43 :     echo Group structure %rare% is $/basis.cm "%root%" %smlfile% >%cmfile%
44 :    
45 : blume 2503 %COMSPEC% /C "%SMLNJ_HOME%\bin\sml.bat %flags% %setup% @CMbuild %root% %cmfile% %heap% %listfile% %linkargsfile%"
46 :     if ERRORLEVEL 1 goto ERR
47 :     if NOT EXIST %linkargsfile% goto END
48 : blume 2088 "%SMLNJ_HOME%\bin\.run\run.x86-win32.exe" @SMLboot=%listfile%
49 :     del %linkargsfile%
50 : blume 2503 goto END
51 : blume 2088
52 :     :ERR
53 :     echo Compilation failed with error.
54 :    
55 :     :END
56 : blume 2503 rem more cleaning up
57 : blume 2088 del %smlfile%
58 :     del %cmfile%
59 :     del %listfile%
60 :     del .cm\GUID\%smlfile%
61 :     del .cm\SKEL\%smlfile%
62 :     del .cm\x86-win32\%smlfile%

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0