diff options
author | Patric Stout <truebrain@openttd.org> | 2019-03-19 22:23:09 +0100 |
---|---|---|
committer | Patric Stout <truebrain@openttd.org> | 2019-03-19 23:22:51 +0100 |
commit | 72c5f2b3eed77120d86ecf636e07c71eb23b4bd5 (patch) | |
tree | 12c5cf8d3445bfa072f90aec5d7de92c6be8056b /config.lib | |
parent | 559d4e833560bfd0a62ea65f5556920122a4930d (diff) | |
download | openttd-72c5f2b3eed77120d86ecf636e07c71eb23b4bd5.tar.xz |
Remove: DOS support
In 10 years there was no active development on DOS. Although it
turned out to still work, the FPS was very bad. There is little
interest in the current community to look into this.
Further more, we like to switch to c++11 functions for threads,
which are not implemented by DJGPP, the only current compiler
for DOS.
Additionally, DOS is the only platform which does not support
networking. It is the reason we have tons of #ifdefs to support
disabling networking.
By removing DOS support, we can both use c++11 functions for threads,
and remove all the code related to disabling network. Sadly, this
means we have to see DOS go.
Of course, if you feel up for the task, simply revert this commit,
and implement stub c++11 functions for threads and stub functions
for networking. We are more than happy to accept such Pull Request.
Diffstat (limited to 'config.lib')
-rw-r--r-- | config.lib | 36 |
1 files changed, 14 insertions, 22 deletions
diff --git a/config.lib b/config.lib index bab1ca4ea..18ea119c4 100644 --- a/config.lib +++ b/config.lib @@ -553,10 +553,10 @@ check_params() { # Check if all params have valid values - # OS only allows DETECT, UNIX, OSX, FREEBSD, DRAGONFLY, OPENBSD, NETBSD, HAIKU, SUNOS, CYGWIN, MINGW, OS2, and DOS - if [ -z "`echo $os | egrep '^(DETECT|UNIX|OSX|FREEBSD|DRAGONFLY|OPENBSD|NETBSD|HPUX|HAIKU|SUNOS|CYGWIN|MINGW|OS2|DOS)$'`" ]; then + # OS only allows DETECT, UNIX, OSX, FREEBSD, DRAGONFLY, OPENBSD, NETBSD, HAIKU, SUNOS, CYGWIN, MINGW, and OS2 + if [ -z "`echo $os | egrep '^(DETECT|UNIX|OSX|FREEBSD|DRAGONFLY|OPENBSD|NETBSD|HPUX|HAIKU|SUNOS|CYGWIN|MINGW|OS2)$'`" ]; then log 1 "configure: error: invalid option --os=$os" - log 1 " Available options are: --os=[DETECT|UNIX|OSX|FREEBSD|DRAGONFLY|OPENBSD|NETBSD|HPUX|HAIKU|SUNOS|CYGWIN|MINGW|OS2|DOS]" + log 1 " Available options are: --os=[DETECT|UNIX|OSX|FREEBSD|DRAGONFLY|OPENBSD|NETBSD|HPUX|HAIKU|SUNOS|CYGWIN|MINGW|OS2]" exit 1 fi # cpu_type can be either 32 or 64 @@ -623,7 +623,7 @@ check_params() { detect_sse_capable_architecture if [ "$enable_static" = "1" ]; then - if [ "$os" = "MINGW" ] || [ "$os" = "CYGWIN" ] || [ "$os" = "DOS" ]; then + if [ "$os" = "MINGW" ] || [ "$os" = "CYGWIN" ]; then enable_static="2" else enable_static="0" @@ -633,8 +633,8 @@ check_params() { if [ "$enable_static" != "0" ]; then log 1 "checking static... yes" - if [ "$os" != "MINGW" ] && [ "$os" != "CYGWIN" ] && [ "$os" != "OSX" ] && [ "$os" != "DOS" ]; then - log 1 "WARNING: static is only known to work on Windows, DOS, and MacOSX" + if [ "$os" != "MINGW" ] && [ "$os" != "CYGWIN" ] && [ "$os" != "OSX" ]; then + log 1 "WARNING: static is only known to work on Windows, and MacOSX" log 1 "WARNING: use static at your own risk on this platform" sleep 5 @@ -644,7 +644,7 @@ check_params() { fi if [ "$enable_unicode" = "1" ]; then - if [ "$os" = "MINGW" ] || [ "$os" = "CYGWIN" ] || [ "$os" = "DOS" ]; then + if [ "$os" = "MINGW" ] || [ "$os" = "CYGWIN" ]; then enable_unicode="2" else enable_unicode="0" @@ -784,10 +784,7 @@ check_params() { log 1 "checking console application... enabled" fi - if [ "$enable_network" = "1" ] && [ "$os" = "DOS" ]; then - log 1 "checking network... DOS, skipping" - enable_network=0 - elif [ "$enable_network" != "0" ]; then + if [ "$enable_network" != "0" ]; then log 1 "checking network... found" else log 1 "checking network... disabled" @@ -1023,10 +1020,6 @@ check_params() { grfcodec="" fi - if [ "$os" = "DOS" ]; then - with_threads="0" - fi - if [ "$os" != "OSX" ] && [ "$with_application_bundle" != "0" ]; then if [ "$with_application_bundle" = "1" ]; then with_application_bundle="0" @@ -1129,7 +1122,7 @@ check_params() { fi if [ "$personal_dir" = "1" ]; then - if [ "$os" = "MINGW" ] || [ "$os" = "CYGWIN" ] || [ "$os" = "DOS" ] || [ "$os" = "HAIKU" ]; then + if [ "$os" = "MINGW" ] || [ "$os" = "CYGWIN" ] || [ "$os" = "HAIKU" ]; then personal_dir="OpenTTD" elif [ "$os" = "OSX" ]; then personal_dir="Documents/OpenTTD" @@ -1603,11 +1596,11 @@ make_cflags_and_ldflags() { fi fi - if [ "$os" != "CYGWIN" ] && [ "$os" != "HAIKU" ] && [ "$os" != "OPENBSD" ] && [ "$os" != "MINGW" ] && [ "$os" != "OSX" ] && [ "$os" != "DOS" ] && [ "$os" != "OS2" ]; then + if [ "$os" != "CYGWIN" ] && [ "$os" != "HAIKU" ] && [ "$os" != "OPENBSD" ] && [ "$os" != "MINGW" ] && [ "$os" != "OSX" ] && [ "$os" != "OS2" ]; then LIBS="$LIBS -lpthread" fi - if [ "$os" != "CYGWIN" ] && [ "$os" != "HAIKU" ] && [ "$os" != "MINGW" ] && [ "$os" != "DOS" ]; then + if [ "$os" != "CYGWIN" ] && [ "$os" != "HAIKU" ] && [ "$os" != "MINGW" ]; then LIBS="$LIBS -lc" fi @@ -2328,7 +2321,7 @@ detect_awk() { detect_os() { if [ "$os" = "DETECT" ]; then - # Detect UNIX, OSX, FREEBSD, DRAGONFLY, OPENBSD, NETBSD, HPUX, SUNOS, CYGWIN, MINGW, OS2, and DOS + # Detect UNIX, OSX, FREEBSD, DRAGONFLY, OPENBSD, NETBSD, HPUX, SUNOS, CYGWIN, MINGW, and OS2 # Try first via dumpmachine, then via uname os=`echo "$host" | tr '[A-Z]' '[a-z]' | $awk ' @@ -2345,7 +2338,6 @@ detect_os() { /cygwin/ { print "CYGWIN"; exit} /mingw/ { print "MINGW"; exit} /os2/ { print "OS2"; exit} - /dos/ { print "DOS"; exit} '` if [ -z "$os" ]; then @@ -2369,7 +2361,7 @@ detect_os() { if [ -z "$os" ]; then log 1 "detecting OS... none detected" log 1 "I couldn't detect your OS. Please use --os=OS to force one" - log 1 "Allowed values are: UNIX, OSX, FREEBSD, DRAGONFLY, OPENBSD, NETBSD, HPUX, HAIKU, SUNOS, CYGWIN, MINGW, OS2, and DOS" + log 1 "Allowed values are: UNIX, OSX, FREEBSD, DRAGONFLY, OPENBSD, NETBSD, HPUX, HAIKU, SUNOS, CYGWIN, MINGW, and OS2" exit 1 fi @@ -3453,7 +3445,7 @@ showhelp() { echo " --os=OS the OS we are compiling for [DETECT]" echo " DETECT/UNIX/OSX/FREEBSD/DRAGONFLY/OPENBSD/" echo " NETBSD/HPUX/SUNOS/CYGWIN/" - echo " MINGW/OS2/DOS/HAIKU" + echo " MINGW/OS2/HAIKU" echo "" echo "Paths:" echo " --prefix-dir=dir specifies the prefix for all installed" |