Skip to content

Commit

Permalink
Replace the symbolic link with an include.
Browse files Browse the repository at this point in the history
  • Loading branch information
jwurzer committed Oct 12, 2022
1 parent bb9d6c8 commit 4ecd1be
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
8 changes: 5 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,11 @@
Provide C functions and C++ functions to convert a SDL\_Event to a string for tracing (debug).

The functions to convert a SDL event to a string is located at the directory evt2str.
The directory evt2str includes the header and C-file. The CPP-file is only a symbolic link to the C-file.
For a C project simple copy the files from evt2str to your project.
For a C++ project copy the files from evt2str and rename the .c file to .cpp or use the symbolic link.
The directory evt2str includes the header and C-file. The CPP-file only includes the C-File.
For a C project simple copy the files from evt2str to your project. The CPP file can be deleted.
For a C++ project copy the files from evt2str and delte the .cpp file and rename the .c file to .cpp
or use the original cpp file. In this case the c file is also needed because
the original cpp file includes the c file.

The C++ version has additional functions which are only available at C++ (checked with
the macro `__cplusplus` which only exist at C++).
Expand Down
1 change: 0 additions & 1 deletion evt2str/sdl_event_to_string.cpp

This file was deleted.

3 changes: 3 additions & 0 deletions evt2str/sdl_event_to_string.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
// Include C file for C++ file.
// Using this trick instead of a sym link also works for Windows.
#include "sdl_event_to_string.c"

0 comments on commit 4ecd1be

Please sign in to comment.