Sfoglia il codice sorgente

add system detection for freebsd

pull/1/head
10sr 11 anni fa
parent
commit
9732d0798d
1 ha cambiato i file con 13 aggiunte e 0 eliminazioni
  1. +13
    -0
      setup.sh

+ 13
- 0
setup.sh Vedi File

@@ -38,16 +38,25 @@ gen_common(){
__ismsys=false
__iscygwin=false
__iswindows=false

__isdarwin=false
__isfreebsd=false
__isbsd=false

__islinux=false

# $OSTYPE is another choice. which is better?
# sh on FreeBSD does not define OSTYPE
case `uname` in
(MINGW*) __ismsys=true ;;
(CYGWIN*) __iscygwin=true ;;
(Darwin*) __isdarwin=true ;;
(FreeBSD*) __isfreebsd=true ;;
(Linux*) __islinux=true ;;
esac
( $__ismsys || $__iscygwin ) && __iswindows=true
# is this true?
( $__isdarwin || $__freebsd ) && __isbsd=true

cat <<__EOC__ >"$__shrc_common"
#!/bin/sh
@@ -58,7 +67,11 @@ gen_common(){
ismsys=$__ismsys
iscygwin=$__iscygwin
iswindows=$__iswindows

isdarwin=$__isdarwin
isfreebsd=$__isfreebsd
isbsd=$__isbsd

islinux=$__islinux

__homelocal="$__homelocal"


Caricamento…
Annulla
Salva