]> git.uio.no Git - u/mrichter/AliRoot.git/blame - RALICE/scripts/mklibs.bat
09-jun-2001 NvE Script mklibs.bat modified to match its new location in the SCRIPTS
[u/mrichter/AliRoot.git] / RALICE / scripts / mklibs.bat
CommitLineData
5486ca8d 1@echo off
2rem ****************************************************************************
3rem * Script to create an MSVC++ LIB and relocatable DLL from *.cxx files
4rem *
5rem * Usage :
6rem * -------
7rem * mklibs export : ROOT loadable DLL and export LIB are created
8rem * mklibs full : ROOT loadable DLL and full LIB version are created
9rem *
10rem * Notes :
11rem * -------
12rem * 1) "mklibs export" is the default, enabling ROOT loadable library creation
13rem * via 'double clicking'.
14rem *
15rem * 2) Providing unsupported options results in displaying the help info.
16rem *
17rem * This script creates ralice.lib and ralice.dll from all .h and .cxx files
18rem * in the current directory.
19rem *
20rem * In view of the ROOTCINT processing, the following two standard files
21rem * are always required :
22rem *
23rem * RALICEHeaders.h : containing an include of all .h files
24rem * RALICELinkDef.h : containing the #pragma's to define all classes
25rem *
26rem * --- NvE 04-apr-2000 UU-SAP Utrecht
27rem ****************************************************************************
28
29echo .
30echo === Automatic ROOT library production of files ralice.lib and ralice.dll ===
31echo .
32
33rem --- The option strings for MSVC++ DLL compilation and linking ---
34set mscomp=/nologo /c /TP /Za /MD /I%ROOTSYS%\include
35set msdll=/nologo /TP /Za /MD /LD /GD /I%ROOTSYS%\include
36set mslink=/ENTRY:_DllMainCRTStartup@12 %ROOTSYS%\lib\*.lib
37
38if "%1" == "" goto export
39if "%1" == "export" goto export
40if "%1" == "full" goto full
41
42rem --- Displaying of the help info ---
43echo ****************************************************************************
44echo * Script to create an MSVC++ LIB and relocatable DLL from *.cxx files
45echo *
46echo * Usage :
47echo * -------
48echo * mklibs export : ROOT loadable DLL and export LIB are created
49echo * mklibs full : ROOT loadable DLL and full LIB version are created
50echo *
51echo * Notes :
52echo * -------
53echo * 1) "mklibs export" is the default, enabling ROOT loadable library creation
54echo * via 'double clicking'.
55echo * 2) Providing unsupported options results in displaying the help info.
56echo *
57echo * This script creates ralice.lib and ralice.dll from all .h and .cxx files
58echo * in the current directory.
59echo *
60echo * In view of the ROOTCINT processing, the following two standard files
61echo * are always required :
62echo *
63echo * RALICEHeaders.h : containing an include of all .h files
64echo * RALICELinkDef.h : containing the #pragma's to define all classes
65echo ****************************************************************************
66goto end
67
68:export
69echo *** Creation of ROOT loadable export libraries
70echo.
e0a93fae 71rem --- Set the RALICE source directory as working directory
72cd ..
5486ca8d 73rem --- Creation of ROOT dictionary ---
74rootcint zzzralicedict.cxx -c RALICEHeaders.h RALICELinkDef.h
75rem --- Compilation step ---
76cl %mscomp% *.cxx
77rem --- Creation of the export LIB ---
78bindexplib ralice *.obj > ralice.def
79lib /nologo /machine:IX86 *.obj /def:ralice.def /out:ralice.lib
80rem --- Creation of the DLL ---
81link /nologo /machine:IX86 /DLL *.obj ralice.exp %mslink% /OUT:ralice.dll
e0a93fae 82rem --- Move the created libs to the SCRIPTS subdirectory
83move ralice.lib .\scripts
84move ralice.dll .\scripts
5486ca8d 85rem --- Delete all intermediate files ---
86del .def
87del ralice.def
88del ralice.exp
89del zzzralicedict.h
90del zzzralicedict.cxx
91del *.obj
92echo.
93echo *** mklibs done.
94goto end
95
96:full
97echo *** Creation of ROOT loadable full version libraries
98echo.
e0a93fae 99rem --- Set the RALICE source directory as working directory
100cd ..
5486ca8d 101rem --- Creation of ROOT dictionary ---
102rootcint zzzralicedict.cxx -c RALICEHeaders.h RALICELinkDef.h
103rem --- Creation of the DLL ---
104cl %msdll% *.cxx /link %mslink% /OUT:ralice.dll
105rem --- Creation of the full version LIB ---
106lib /nologo /machine:IX86 *.obj /out:ralice.lib
e0a93fae 107rem --- Move the created libs to the SCRIPTS subdirectory
108move ralice.lib .\scripts
109move ralice.dll .\scripts
5486ca8d 110rem --- Delete all intermediate files ---
111del .def
112del zzzralicedict.h
113del zzzralicedict.cxx
114del *.obj
115echo.
116echo *** mklibs done.
117goto end
118
119:end
120rem --- End of script ---