DEADSOFTWARE

implement Kernel.Call for CPfront using libffi
[cpc.git] / make-all.sh
index eef57f20346373649e0464d36ec9ec1c69fe8f36..54294677e5deee81390cc17ba4a7e5dec5d049f5 100755 (executable)
@@ -39,11 +39,16 @@ usage() {
 #  echo "    -s os             Host operaion system"
   echo "Processors:"
   echo "    486               Intel 486+"
+  echo "    arm               ARM 32-bit"
   echo "Targets:"
   echo "    native            Native"
   echo "    cpfront           Generic C"
   echo "Operation systems:"
   echo "    linux             GNU/Linux"
+  echo "    cygwin            Cygwin"
+  echo "Environment variables:"
+  echo "    CC                C compiler binary"
+  echo "    CFLAGS            C compiler options"
   exit 2
 }
 
@@ -59,13 +64,17 @@ make_stage() {
   local _this_system="$4"
   shift 4
   "$_this/make.sh" -o "$_dir" -c "$_compiler" -l "$_linker" "$@" "$_this_cpu" "$_this_target" "$_this_system"
+  local _ext=
+  if [ "$_host_system" = "cygwin" ]; then
+    _ext=".exe"
+  fi
   if [ "$_target" = "cpfront" ]; then
-    _compiler="$_dir/cpfront"
+    _compiler="$_dir/cpfront${_ext}"
     _linker=
   else
     if [ "$_cpu" = "486" ]; then
-      _compiler="$_dir/cpc486"
-      _linker="$_dir/cpl486"
+      _compiler="$_dir/cpc486${_ext}"
+      _linker="$_dir/cpl486${_ext}"
     else
       error "unsupported cpu $_cpu"
     fi