1
0
mirror of https://github.com/SoftEtherVPN/SoftEtherVPN.git synced 2025-07-06 15:54:57 +03:00

Replace hand-written Makefiles with CMake (#518)

* src: remove makefiles

* .gitignore: remove CMakeLists.txt

* README.md: add CMake to the required packages

* debian: add CMake to the dependencies

* Travis CI: specify Makefile directory

* Replace hand-written Makefiles with CMake
This commit is contained in:
Davide Beatrici
2018-05-22 22:20:41 +02:00
committed by Moataz Elmasry
parent 5b60892d5d
commit f65ae2bf7d
17 changed files with 264 additions and 4682 deletions

96
configure vendored
View File

@ -17,96 +17,12 @@ echo
echo 'Welcome to the corner-cutting configure script !'
echo
OS=""
case "`uname -s`" in
Linux)
OS="linux"
;;
FreeBSD)
OS="freebsd"
;;
SunOS)
OS="solaris"
;;
Darwin)
OS="macos"
;;
OpenBSD)
OS="openbsd"
;;
*)
echo 'Select your operating system below:'
echo ' 1: Linux'
echo ' 2: FreeBSD'
echo ' 3: Solaris'
echo ' 4: Mac OS X'
echo ' 5: OpenBSD'
echo
echo -n 'Which is your operating system (1 - 5) ? : '
read TMP
echo
if test "$TMP" = "1"
then
OS="linux"
fi
if test "$TMP" = "2"
then
OS="freebsd"
fi
if test "$TMP" = "3"
then
OS="solaris"
fi
if test "$TMP" = "4"
then
OS="macos"
fi
if test "$TMP" = "5"
then
OS="openbsd"
fi
if [ ! -d "tmp" ]; then
mkdir tmp
fi
if test "$OS" = ""
then
echo "Wrong number."
exit 1
fi
;;
esac
(cd tmp && cmake .. || exit 1)
CPU=""
case "`uname -m`" in
x86_64|amd64|aarch64|arm64|armv8*|mips64|ppc64|sparc64|alpha|ia64)
CPU=64bit
;;
i?86|x86pc|i86pc|armv4*|armv5*|armv6*|armv7*)
CPU=32bit
;;
*)
echo 'Select your CPU bits below:'
echo ' 1: 32-bit'
echo ' 2: 64-bit'
echo
echo -n 'Which is the type of your CPU (1 - 2) ? : '
read TMP
echo
if test "$TMP" = "1"
then
CPU="32bit"
fi
if test "$TMP" = "2"
then
CPU="64bit"
fi
echo ""
if test "$CPU" = ""
then
echo "Wrong number."
exit 1
fi
;;
esac
cp src/makefiles/${OS}_${CPU}.mak Makefile
echo "The Makefile is generated. Run 'make' to build SoftEther VPN."
echo "The Makefile is generated. Run 'make -C tmp' to build SoftEther VPN."