freebsd-ports/games/crashtest/files/patch-src-crashtest_crashtest.cxx
Dmitry Marakasov 07b0efaea7 - Add games/crashtest
Crashtest simulates car crashes. This is an educational tool that
can be used to acquire much insight into this complex process. The
user can learn about the relation between speed, reaction-time and
stopping distance. Also, many physical properties can be studied.

WWW: http://www.stolk.org/crashtest/
2016-11-14 15:10:20 +00:00

16 lines
538 B
C++

--- src-crashtest/crashtest.cxx.orig 2009-02-15 22:08:24 UTC
+++ src-crashtest/crashtest.cxx
@@ -616,12 +616,7 @@ void seatbelt_cb(Fl_Widget *o)
int main(int argc, char *argv[])
{
char *bindirname = dirname(argv[0]);
- if (!strcmp(bindirname,"."))
- dirprefix="/usr/share/games/crashtest";
- else
- {
- dirprefix = dirname(bindirname) + std::string("/share/games/crashtest");
- }
+ dirprefix="%%DATADIR%%";
if (getenv("PLODE_DATADIR"))
dirprefix = getenv("PLODE_DATADIR");
modelmap = new ModelMap(dirprefix);