LC_COLLATE.
[p5sagit/p5-mst-13.2.git] / hints / os2.sh
index 1652cb7..f8df9d2 100644 (file)
 # Note that during the .obj compile you need to move the perl.dll file
 # to LIBPATH :-(
 
-bin_sh=`../UU/loc sh.exe /bin c:/bin d:/bin e:/bin f:/bin g:/bin h:/bin /bin`
-echo "####### Shell found at $bin_sh #############" >&4
+path_sep=\;
+
+if test -f $sh.exe; then sh=$sh.exe; fi
+
+startsh="#!$sh"
 
-#osname="OS/2"
 sysman=`../UU/loc . /man/man1 c:/man/man1 c:/usr/man/man1 d:/man/man1 d:/usr/man/man1 e:/man/man1 e:/usr/man/man1 f:/man/man1 f:/usr/man/man1 g:/man/man1 g:/usr/man/man1 /usr/man/man1`
 cc='gcc'
 usrinc='/emx/include'
@@ -38,6 +40,7 @@ exe_ext='.exe'
 i_dlfcn='define'
 
 aout_d_shrplib='undef'
+aout_useshrplib='false'
 aout_obj_ext='.o'
 aout_lib_ext='.a'
 aout_ar='ar'
@@ -52,10 +55,11 @@ aout_usedl='undef'
 aout_archobjs="os2.o dl_os2.o"
 
 # variable which have different values for aout compile
-used_aout='d_shrplib plibext lib_ext obj_ext ar plibext d_fork lddlflags ldflags ccflags use_clib usedl archobjs cppflags'
+used_aout='d_shrplib useshrplib plibext lib_ext obj_ext ar plibext d_fork lddlflags ldflags ccflags use_clib usedl archobjs cppflags'
 
 if [ "$emxaout" != "" ]; then
     d_shrplib="$aout_d_shrplib"
+    useshrplib="$aout_useshrplib"
     obj_ext="$aout_obj_ext"
     lib_ext="$aout_lib_ext"
     ar="$aout_ar"
@@ -69,15 +73,16 @@ if [ "$emxaout" != "" ]; then
     usedl="$aout_usedl"
 else
     d_shrplib='define'
+    useshrplib='true'
     obj_ext='.obj'
     lib_ext='.lib'
     ar='emxomfar'
     plibext='.lib'
     d_fork='undef'
-    lddlflags='-Zdll -Zomf -Zcrtdll'
+    lddlflags='-Zdll -Zomf -Zmt -Zcrtdll'
     # Recursive regmatch may eat 2.5M of stack alone.
-    ldflags='-Zexe -Zomf -Zcrtdll -Zstack 32000'
-    ccflags='-Zomf -DDOSISH -DOS2=2 -DEMBED -I. -DPACK_MALLOC -DDEBUGGING_MSTATS'
+    ldflags='-Zexe -Zomf -Zmt -Zcrtdll -Zstack 32000'
+    ccflags='-Zomf -Zmt -DDOSISH -DOS2=2 -DEMBED -I. -DPACK_MALLOC -DDEBUGGING_MSTATS'
     use_clib='c_import'
     usedl='define'
 fi
@@ -85,6 +90,8 @@ fi
 # To get into config.sh (should start at the beginning of line)
 # or you can put it into config.over.
 plibext="$plibext"
+# plibext is not needed anymore.  Just directly set $libperl.
+libperl="libperl${plibext}"
 
 #libc="/emx/lib/st/c_import$lib_ext"
 libc="$libemx/st/$use_clib$lib_ext"
@@ -99,10 +106,7 @@ fi
 libs='-lsocket -lm'
 archobjs="os2$obj_ext dl_os2$obj_ext"
 
-# Run files without extension with sh - feature of patched ksh
-# [???]
-# NOHASHBANG=sh
-# Same with newer ksh
+# Run files without extension with sh:
 EXECSHELL=sh
 
 cccdlflags='-Zdll'
@@ -142,6 +146,7 @@ nroff='nroff.cmd'
 # above will be overwritten otherwise, indented to avoid config.sh
   _nroff='nroff.cmd'
 
+# should be handled automatically by Configure now.
 ln='cp'
 # Will be rewritten otherwise, indented to not put in config.sh
   _ln='cp'
@@ -162,3 +167,35 @@ d_setprior='define'
 
 # Commented:
 #startsh='extproc ksh\\n#! sh'
+
+# Now install the external modules. We are in the ./hints directory.
+
+cd ../os2/OS2
+
+if ! test -d ../../ext/OS2 ; then
+   mkdir ../../ext/OS2
+fi
+
+cp -rfu * ../../ext/OS2/
+
+# Install tests:
+
+for xxx in * ; do
+       if $test -d $xxx/t; then
+               cp -uf $xxx/t/*.t ../../t/lib
+       else
+               if $test -d $xxx; then
+                       cd $xxx
+                       for yyy in * ; do
+                               if $test -d $yyy/t; then
+                                   cp -uf $yyy/t/*.t ../../t/lib
+                               fi
+                       done
+                       cd ..
+               fi
+       fi
+done
+
+
+# Now go back
+cd ../../hints