Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
256 commits
Select commit Hold shift + click to select a range
4e0b10a
cleanup
vaporstack Mar 21, 2018
281f253
removed loose third party code in favor of libwcm
vaporstack Mar 22, 2018
e2e410b
fuckup wcm in the wrong place
vaporstack Mar 22, 2018
25c32f7
what labyrinths we weave
vaporstack Mar 22, 2018
998d7b9
common
vaporstack Mar 22, 2018
e202ae5
fucking bullshit
vaporstack Mar 22, 2018
c5ad27a
cleanup and consistency
vaporstack Mar 22, 2018
24cb464
idk fuck you
vaporstack Mar 23, 2018
a55b4c3
stuff
vaporstack Mar 23, 2018
8791592
stupid shit
vaporstack Mar 24, 2018
068b26a
idk stuff
vaporstack Mar 29, 2018
7c6d83e
demo stubs
vaporstack Apr 1, 2018
8e63a80
demo.c for init
vaporstack Apr 1, 2018
e2df463
important fix for w_sequence
vaporstack Apr 2, 2018
ed755e7
I guess I did some work on the demo
vaporstack Apr 3, 2018
cc6048d
demo infra
vaporstack Apr 5, 2018
aed7f13
demo infra
vaporstack Apr 5, 2018
2c4ff0a
Demo infra
vaporstack Apr 6, 2018
cf7ab5c
ignore cleanup
vaporstack Apr 6, 2018
05e6bdc
sim stuff
vaporstack Apr 6, 2018
9afe97f
cleanup
vaporstack Apr 6, 2018
4dbd5e7
Removed submodules, switching to cmake conditional compilation to kee…
vaporstack Apr 6, 2018
e771212
merge
vaporstack Apr 6, 2018
9cd4ded
cmake and test infra
vaporstack Apr 6, 2018
54dea39
ci stub
vaporstack Apr 6, 2018
06d89a2
Adding test to ci
vaporstack Apr 6, 2018
8370f37
ci lulz
vaporstack Apr 6, 2018
799b0fe
ci ftl
vaporstack Apr 6, 2018
8a2a837
lol I put in everything but make
vaporstack Apr 6, 2018
02ddb1c
the test needs to link against m even though the lib can compile with…
vaporstack Apr 6, 2018
59a1176
our tests are minimial, please don't clone the gcc image twice yikes
vaporstack Apr 6, 2018
b9b4d6f
cmake tweaks
vaporstack Apr 6, 2018
105f4ad
Refactoring serialization to have a bottleneck. as it should
vaporstack Apr 6, 2018
884e406
Added toplevel wsh declarator
vaporstack Apr 7, 2018
da9ab90
put wcm back in
vaporstack Apr 7, 2018
ad1f95b
Demo infra
vaporstack Apr 7, 2018
0645873
demo infra
vaporstack Apr 7, 2018
5a15e17
renamed demo files
vaporstack Apr 7, 2018
baceaae
test build by default to fix CI
vaporstack Apr 7, 2018
9328755
text support
vaporstack Apr 7, 2018
b297cba
text
vaporstack Apr 7, 2018
da929b2
minor improvements to sequence, bounds calculation and cleanup
vaporstack Apr 7, 2018
ee06f41
some more methods for scaling and moving
vaporstack Apr 7, 2018
223f323
cleanup, memory leak
vaporstack Apr 7, 2018
213b787
ops file
vaporstack Apr 8, 2018
96559fb
Fixes
vaporstack Apr 8, 2018
9c1156b
Demo improvements
vaporstack Apr 8, 2018
250220e
Cleanup and some build fixes
vaporstack Apr 8, 2018
f1f292a
Neat things
vaporstack Apr 8, 2018
1713e64
Demo improvements
vaporstack Apr 10, 2018
51b2a0e
Playback tweaks and some bugfixes
vaporstack Apr 11, 2018
91728c2
memory fixes
vaporstack Apr 11, 2018
261e17f
Cmake fixes
vaporstack Apr 12, 2018
b31b179
demo stuff
vaporstack Apr 12, 2018
f8a0423
session infra
vaporstack Apr 12, 2018
11c6f04
session stuff
vaporstack Apr 13, 2018
e361920
idk
vaporstack Apr 13, 2018
492c6dd
stuff
vaporstack Apr 13, 2018
22e24eb
wash tool defs
vaporstack Apr 13, 2018
b0b9c82
infra for diffs
vaporstack Apr 13, 2018
59e350f
tool deltas
vaporstack Apr 13, 2018
76eaaec
Demo and tool descriptor infra
vaporstack Apr 13, 2018
c9425d3
ops demo infra and tool infra
vaporstack Apr 13, 2018
c3c62a8
ops demo infra
vaporstack Apr 13, 2018
6047c0b
operations tweaks
vaporstack Apr 13, 2018
19c3e0d
va_args in core libraries
vaporstack Apr 14, 2018
5ef2ab1
ftgl as submodule for now
vaporstack Apr 14, 2018
e4f862a
Trivial line ops fix
vaporstack Apr 15, 2018
a2d36c0
xcode
vaporstack Apr 15, 2018
4ff8063
deleted ftgl
vaporstack Apr 15, 2018
20d2c5c
submodule fix
vaporstack Apr 15, 2018
1a3baf6
stuff and junk
vaporstack Apr 16, 2018
e3f656b
bugfixes, hilarious memory leak fix
vaporstack Apr 16, 2018
330a077
xcode update, serialization bugs
vaporstack Apr 17, 2018
059c1d4
gitignore
vaporstack Apr 17, 2018
80f5e37
serial fixes and other stuff
vaporstack Apr 18, 2018
9b1b8aa
Merge branch 'master' of https://github.com/rumin4nt/wsh
vaporstack Apr 18, 2018
5017a44
Fix to document schema
vaporstack Apr 18, 2018
863afe8
Merge branch 'master' of github.com:rumin4nt/wsh
vaporstack Apr 18, 2018
dba0a49
Fixed big ol' memory leak
vaporstack Apr 19, 2018
d03e18c
Removed spurious prints
vaporstack Apr 19, 2018
3bbf2c8
spurious commit to test new irc announcement integration
vaporstack Apr 19, 2018
b06cdf8
spurious commit to test new irc announcement integration
vaporstack Apr 19, 2018
fd9cac6
spurious commit to test new irc announcement integration
vaporstack Apr 19, 2018
a22f3a3
spurious commit to test new irc announcement integration
vaporstack Apr 19, 2018
85e38f8
spurious commit etc
vaporstack Apr 19, 2018
b79d591
spurious commit etc
vaporstack Apr 19, 2018
3c3bb0d
spurious commit etc
vaporstack Apr 19, 2018
9b2b011
spurious commit etc
vaporstack Apr 19, 2018
f9783ae
spurious commit etc
vaporstack Apr 19, 2018
c9e6a37
spurious commit etc
vaporstack Apr 19, 2018
ce52526
spurious TEST
vaporstack Apr 19, 2018
e49f46c
spurious TEST
vaporstack Apr 19, 2018
e121a03
spurious TEST2
vaporstack Apr 19, 2018
47dffa1
spurious TEST2
vaporstack Apr 19, 2018
696435e
header cleanup
vaporstack Apr 19, 2018
a6d2184
Removing printf for debug ( should do nice macro later )
vaporstack Apr 19, 2018
a064d26
tiny scheme fix
vaporstack Apr 20, 2018
6883bba
neverending scheme stuff
vaporstack Apr 24, 2018
c98652c
Tiny fix for w_object
vaporstack Apr 26, 2018
f1fec3a
slicer and line ops support
vaporstack Apr 30, 2018
ba7304a
more convenience methods for stuff
vaporstack May 2, 2018
4b7adcb
Some minor niceties
vaporstack May 2, 2018
87c1666
serial tweaks
vaporstack May 3, 2018
02f7494
meta tweak
vaporstack May 7, 2018
2ea5a87
serial fixes
vaporstack May 8, 2018
43b7469
stuff
vaporstack May 8, 2018
157d3ae
Tweaks
vaporstack May 8, 2018
3f843cd
Merge branch 'master' of github.com:rumin4nt/wsh
vaporstack May 10, 2018
6e448a4
tweak
vaporstack May 10, 2018
1a6beaf
Build system fixes
vaporstack May 11, 2018
77be704
Merge
vaporstack May 11, 2018
b388064
merge
vaporstack May 11, 2018
306a71f
Work on making wcm optional.
vaporstack May 11, 2018
04847a3
rotation infrastructrure(still buggy)
vaporstack May 11, 2018
346df8e
bugfixes for point and formatting
vaporstack May 11, 2018
52a3807
cmake fixes
vaporstack May 14, 2018
b20a67e
tiny fix for w_transform
vaporstack May 14, 2018
8d951b8
moved wash-demo to wsh-demo
vaporstack May 15, 2018
16ca25d
Fixed xcode projects to be wsh-demo, added placeholder for mapping demo
vaporstack May 15, 2018
f2c581c
hella name refactor to conform wsh_ instead of w_
vaporstack May 15, 2018
11f6dd7
purging w_ in favor of wsh_
vaporstack May 15, 2018
9274119
Finally fixed demo to have wcm be an optional build
vaporstack May 15, 2018
b4078e2
build systems are hell
vaporstack May 15, 2018
e73b383
do not build demo if glfw not found, duh
vaporstack May 15, 2018
4377b2b
cmaaaaake
vaporstack May 15, 2018
fc702fd
drw name refactor
vaporstack May 15, 2018
500e3fa
demo tweaks and bugfixes
vaporstack May 15, 2018
6936530
i suck at math
vaporstack May 16, 2018
5a31db2
Untangling
vaporstack May 16, 2018
41e2e0f
Merge branch 'master' of github.com:rumin4nt/wsh
vaporstack May 16, 2018
13a5c50
refactor fixes and panning
vaporstack May 16, 2018
fd15ed2
demo and infra
vaporstack May 17, 2018
542f875
assign default first frame in sequence creation
vaporstack May 17, 2018
63f04d7
linux fixes
vaporstack May 18, 2018
08a9875
idk lol
vaporstack May 18, 2018
846c8cc
Linuxy fixity
vaporstack May 21, 2018
81203cd
Linux fixes
vaporstack May 21, 2018
3a8762c
maintenance
vaporstack May 23, 2018
e0de1d3
tiny line api improvements
vaporstack May 24, 2018
a2b82cb
fixes
vaporstack May 26, 2018
3ae7d69
language fixes
vaporstack May 29, 2018
8be15a9
Merge branch 'master' of github.com:rumin4nt/wsh
vaporstack May 30, 2018
b0811a9
project tweak
vaporstack May 30, 2018
962cb4b
tweks
vaporstack May 31, 2018
53649d2
workspace stuff
vaporstack Jun 7, 2018
3e02856
infra for tiling demo
vaporstack Jun 12, 2018
e433d3f
Demo infra.
vaporstack Jun 14, 2018
2bfb971
header compatibility
vaporstack Jun 14, 2018
18be250
tweaks
vaporstack Jun 14, 2018
79c164f
resolve conflicts
vaporstack Jun 15, 2018
54a11c9
wsh bugfixes
vaporstack Jun 15, 2018
95e934c
Automatic commit (hasty!)
vaporstack Jun 15, 2018
6dc1e78
svg (cairo) infra
vaporstack Jun 18, 2018
f478c9e
SVG cleanup
vaporstack Jun 18, 2018
b415ba2
svg tweaking
vaporstack Jun 18, 2018
c796b59
tweaks for svg
vaporstack Jun 19, 2018
7e3f5cf
fuck git jfc
vaporstack Jun 19, 2018
d8c0800
stuff
vaporstack Jun 19, 2018
8b61262
ops idk
vaporstack Jun 21, 2018
aa12b48
serial fixes
vaporstack Jun 22, 2018
54d8702
Automatic commit (hasty!)
vaporstack Jun 22, 2018
329752b
project cleanup
vaporstack Jun 27, 2018
51e90a8
Slight modifications for feature parity with other conventions
vaporstack Jun 28, 2018
d77407b
proper version strings
vaporstack Jun 28, 2018
ace606c
merge
vaporstack Jun 28, 2018
1ab57bb
json thing maybe
vaporstack Jun 29, 2018
5d2bee6
some infra hacks on normalization
vaporstack Jul 2, 2018
6855410
idk something in lines
vaporstack Jul 6, 2018
1cb5014
merge fix
vaporstack Jul 7, 2018
1a0f9cd
normal fixes maybe
vaporstack Jul 9, 2018
7794fb6
primitives and shit
vaporstack Jul 15, 2018
1326147
fixes for wsh_object
vaporstack Jul 25, 2018
9a94a5e
ptrimitives and stuff
vaporstack Aug 1, 2018
19c6c3f
Added wash player and some infra improvements
vaporstack Aug 24, 2018
25d6d56
player infra
vaporstack Aug 24, 2018
52586c0
added palette stubs
vaporstack Aug 25, 2018
55f3f58
palette and infra
vaporstack Aug 27, 2018
a753c5d
some name fixes maybe
vaporstack Sep 5, 2018
dc6cd99
Some line ops infra and bugfixes
vaporstack Sep 20, 2018
afe41e1
line infra
vaporstack Sep 25, 2018
1d508b6
buncha logging stuff
vaporstack Nov 19, 2018
8f4dbb7
fucky xcode files
vaporstack Nov 19, 2018
0c33e08
logging
vaporstack Nov 24, 2018
5d5a6ee
fixes
vaporstack Nov 30, 2018
38c0c6a
merge
vaporstack Nov 30, 2018
faf9815
cjson will be the death of me
vaporstack Dec 4, 2018
6fdb1af
wsh_math.h separation of concerns
vaporstack Dec 6, 2018
c09ad2c
moving gpc functionality into a compile time wash extension
vaporstack Dec 11, 2018
aae4283
Tweaks and fixes, endless tweaks and fixes
vaporstack Dec 12, 2018
5edc6fc
work on tool registry and parameter tracking
vaporstack Dec 12, 2018
ac21af0
tool registry infra
vaporstack Dec 12, 2018
3eb9fea
bugfixes
vaporstack Dec 13, 2018
6c2a867
wsh tool tweaks
vaporstack Dec 13, 2018
15f52df
bugfixes
vaporstack Dec 13, 2018
5ade6b4
build fixes for gpc ext
vaporstack Dec 14, 2018
163242f
ftgl demo fixes
vaporstack Dec 16, 2018
d073b55
scheme fixes
vaporstack Dec 25, 2018
26047cb
xcode fuckery
vaporstack Dec 26, 2018
ed76633
jfc xcode wtf
vaporstack Dec 26, 2018
21dedbd
xcode fuckery
vaporstack Dec 28, 2018
5825f5c
including gpc in build
vaporstack Jan 6, 2019
66161aa
work on v2 of the pen'
vaporstack Jan 7, 2019
9554f67
stub for new ops to center all frames
vaporstack Jan 10, 2019
6ac8752
clangformat isn't without its drawbacks sigh
vaporstack Jan 22, 2019
c7f83fc
added stub for repair utility
vaporstack Jan 22, 2019
7b746a4
fixes to document and player
vaporstack Jan 26, 2019
80f62e1
fixes and cjson
vaporstack Jan 31, 2019
9ec6c69
rpi fixes maybe
vaporstack Jan 31, 2019
f8000cb
rpi fixes maybe
vaporstack Jan 31, 2019
ea78c0d
submodules
vaporstack Jan 31, 2019
290f799
big ol messes when you use two vcs at once lol
vaporstack Feb 1, 2019
1ae4b73
unstupid stupid merge
vaporstack Feb 1, 2019
1d45f84
serial and gitignore
vaporstack Feb 8, 2019
f033c34
removed xcuserdata AGAIN
vaporstack Feb 19, 2019
d1d7263
moved logging to its own file, added simple json based tag database u…
vaporstack Feb 22, 2019
bdc7dae
renaming and refactoring
vaporstack Feb 22, 2019
a19f849
Cleanup and some more serial infra
vaporstack Feb 24, 2019
36ccb15
untangling
vaporstack Feb 25, 2019
a54d806
some fixes for line ops or maybe just formatting
vaporstack Mar 12, 2019
124078b
added a width parameter to wsh_line even though its in the opposite d…
vaporstack Mar 19, 2019
dd15a3f
removed have_fill and have_stroke from the core, switch fill and stro…
vaporstack Mar 19, 2019
2d2eb98
wsh_object tweak, not sure what
vaporstack Mar 21, 2019
8718bfc
wsh_object tweak
vaporstack Mar 21, 2019
f685e94
serial and data fixes
vaporstack Mar 23, 2019
9ed5991
bringing git up to date with r4
vaporstack Apr 2, 2019
7e62c1f
removed parent from wsh_object
vaporstack Apr 4, 2019
dec0b57
serial and sequence ods
vaporstack Apr 6, 2019
2f49c4f
work on serialixation and transport
vaporstack Apr 15, 2019
42e783b
work on ops
vaporstack Apr 19, 2019
c18a826
tweaks for line ops
vaporstack Apr 24, 2019
bbaec4c
built lib for macos for oF
vaporstack Apr 28, 2019
f81b33e
tweaks
vaporstack May 10, 2019
8458088
serial tweaks
vaporstack May 13, 2019
21e8fe1
fixes and generalization for of integration
vaporstack May 31, 2019
d9cd5ba
stuff
vaporstack May 31, 2019
9efb032
tweaks for serial
vaporstack Jun 3, 2019
a7f5cac
tweaks.
vaporstack Jun 7, 2019
13ba785
tvos project and refactors
vaporstack Jun 20, 2019
cd14cae
fixes
vaporstack Jun 24, 2019
82f3753
merging stash
vaporstack Jun 24, 2019
a615b63
operators and tvos project
vaporstack Jun 24, 2019
ccada38
Merge branch 'master' of github.com:rumin4nt/wsh
vaporstack Jun 24, 2019
b8f71bc
merge
vaporstack Jul 3, 2019
4ad1b63
resolve cmakelists
vaporstack Jul 8, 2019
c2fc53d
project fixes
vaporstack Jul 10, 2019
6683110
merge
vaporstack Jul 10, 2019
ae3561d
upstream merge
vaporstack Jul 19, 2019
e669b50
collinearity check for wsh_line_ops
vaporstack Jul 24, 2019
54c63f6
tweaks
vaporstack Aug 16, 2019
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -52,4 +52,13 @@ Mkfile.old
dkms.conf

build/
docs/

.DS_Store

*UserInterfaceState.xcuserstate
*xcdebugger*
*xcshareddata*
vs.xcuserdatad

*.xcuserdatad
38 changes: 38 additions & 0 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# This file is a template, and might need editing before it works on your project.
# use the official gcc image, based on debian
# can use verions as well, like gcc:5.2
# see https://hub.docker.com/_/gcc/
image: gcc
before_script:
- apt-get update --yes
- apt-get install --yes cmake
build:
stage: build
# instead of calling g++ directly you can also use some build toolkit like make
# install the necessary build tools when needed
# before_script:
# - apt update && apt -y install make autoconf
script:
#- git submodule init
#- git submodule update
- mkdir build
- cd build
- cmake ..
- make
- ./test/test_wsh

artifacts:
paths:
- build/libwsh.a
- build/test/test_wsh
# depending on your build setup it's most likely a good idea to cache outputs to reduce the build time
cache:
paths:
- "*.o"

# run tests using the binary built before
#test:
# stage: test
# script:
# - ./build/test/test_wsh

3 changes: 0 additions & 3 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
[submodule "cJSON"]
path = cJSON
url = https://github.com/DaveGamble/cJSON
[submodule "contrib/cjson"]
path = contrib/cjson
url = https://github.com/DaveGamble/cJSON
Expand Down
202 changes: 177 additions & 25 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,39 +1,191 @@
cmake_minimum_required (VERSION 3.0)
cmake_minimum_required(VERSION 3.0)


project(wsh)
set(project_name wsh)

project(${project_name})

set (${project_name}_VERSION_MAJOR 0)
set (${project_name}_VERSION_MINOR 0)
set (${project_name}_VERSION_PATCH 1)

option(BuildLibrary "Build ${project_name} static library" ON)
option(BuildDocumentation "BuildDocumentation" OFF)
option(BuildDemo "BuildDemo" OFF)
option(BuildTest "BuildTest" ON)
option(EnableGPC "EnableGPC" OFF)

macro(use_c99)
if (CMAKE_VERSION VERSION_LESS "3.1")
if (CMAKE_C_COMPILER_ID STREQUAL "GNU")
set (CMAKE_C_FLAGS "-std=gnu99 ${CMAKE_C_FLAGS}")
endif ()
else ()
set (CMAKE_C_STANDARD 99)
endif ()
if(CMAKE_VERSION VERSION_LESS "3.1")
if(CMAKE_C_COMPILER_ID STREQUAL "GNU")
set(CMAKE_C_FLAGS "-std=gnu99 ${CMAKE_C_FLAGS}")
endif()
else()
set(CMAKE_C_STANDARD 99)
endif()
endmacro(use_c99)

set (wsh_VERSION_MAJOR 0)
set (wsh_VERSION_MINOR 0)
set (wsh_VERSION_PATCH 1)
use_c99()


if(${BuildTest})
add_subdirectory(test)
endif()

set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_CURRENT_SOURCE_DIR}/cmake/Modules/")

if(CMAKE_BUILD_TYPE)
if (${CMAKE_BUILD_TYPE} STREQUAL "release")
set(BuildDocumentation ON)
else()
set(CMAKE_BUILD_TYPE "debug")
endif()
else()
set(CMAKE_BUILD_TYPE "debug")
endif()

message("CMAKE build type:" ${CMAKE_BUILD_TYPE})

message(${project_name})

if (CMAKE_BUILD_TYPE EQUAL "debug")

else()

endif ()

if (${have_r4_environment})
message("Enabling the JSON backend?")
add_definitions(-DWSH_ENABLE_SERIAL_BACKEND_JSON)

set(EnableGPC ON)

endif()


if(BuildLibrary)
message("Adding library target.")
if (EnableGPC)
set(ext_src src/ext/*.c)
else()
set(ext_src src/ext/wsh_player.c)
endif()

file(GLOB sources wsh.c ${ext_src} src/core/*.c src/geo/*.c src/io/*.c src/serial/*.c src/session/*.c src/util/*.c contrib/cjson/cJSON.c)
add_library(${project_name} STATIC ${sources})
# add_library(wsh SHARED ${sources})
endif()


if ( ${have_r4_environment} )
message("Building within r4 lib structure.")

target_include_directories(${project_name} PUBLIC
${CMAKE_CURRENT_SOURCE_DIR}/contrib
/opt/X11/include)
else()
message("Building standalone.")
target_include_directories(${project_name} PUBLIC
${CMAKE_CURRENT_SOURCE_DIR}/contrib
/opt/X11/include)

macro(use_c99)
if (CMAKE_VERSION VERSION_LESS "3.1")
if (CMAKE_C_COMPILER_ID STREQUAL "GNU")
set (CMAKE_C_FLAGS "-std=gnu99 ${CMAKE_C_FLAGS}")
endif ()
else ()
set (CMAKE_C_STANDARD 99)
endif ()
endmacro(use_c99)

# add_subdirectory(contrib/cjson)
# add_subdirectory(contrib/glfw)
# set(build_demo YES)

find_package(Doxygen)
option(BUILD_DOCUMENTATION "Create and install the HTML based API
documentation (requires Doxygen)" ${DOXYGEN_FOUND})


if(BUILD_DOCUMENTATION)
if(BuildDocumentation)
if (${CMAKE_BUILD_TYPE} STREQUAL "release")
set(BuildDoc YES)
endif()
endif()
endif()

endif()


find_package(LibGLFW )
include_directories(${LibGLFW_INCLUDE_DIRS})
set(LIBS ${LIBS} ${LibGLFW_LIBRARIES})

if (GLFW_FOUND)
if (${CMAKE_BUILD_TYPE} STREQUAL "release")
set(BuildDemo YES)
endif()

else()
message("Did not find GLFW, cannot build demo.")
set(BuildDemo NO)

endif()



find_package(LibFTGL )
include_directories(${LibGLFW_INCLUDE_DIRS})
set(LIBS ${LIBS} ${LibGLFW_LIBRARIES})

if (FTGL_FOUND)
add_definitions(-DWSH_DEMO_ENABLE_FTGL)
else()
message("Did not find FTGL.")
endif()


find_package(LibWCM )
include_directories(${LibWCM_INCLUDE_DIRS})
set(LIBS ${LIBS} ${LibGWCM_LIBRARIES})

if (WCM_FOUND)
add_definitions(-DWSH_DEMO_ENABLE_WCM)
else()
message("Did not find WCM.")
endif()

if (${BuildDemo})
message("Adding demo to build targets.")
add_subdirectory(demo)
endif()

if (${BuildDoc})
message("Adding documentation to build targets.")

file(GLOB sources *.c src/core/*.c src/geo/*.c src/io/*.c src/serial/*.c src/session/*.c src/util/*.c)
set(doxyfile_in ${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile)
set(doxyfile ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile)

add_library(wsh SHARED STATIC ${sources})
# add_library(wsh SHARED ${sources})
configure_file(${doxyfile_in} ${doxyfile} @ONLY)

if ( ${have_r4_environment} MATCHES "yes")
message("Doxygen build started.")
add_custom_target(
doc ALL
COMMAND ${DOXYGEN_EXECUTABLE} ${doxyfile_in}
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
COMMENT "Generating API documentation with Doxygen"
VERBATIM)
endif()

else(${have_r4_environment})
add_subdirectory(contrib/cjson)
add_subdirectory(contrib/glfw)
endif(${have_r4_environment})

add_subdirectory(demo)
target_include_directories (${project_name} PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/..
${CMAKE_CURRENT_SOURCE_DIR}/contrib)

add_custom_command(TARGET ${project_name} POST_BUILD # Adds a post-build event to MyTest
COMMAND ${CMAKE_COMMAND} -E copy_if_different # which executes "cmake - E copy_if_different..."
"${CMAKE_BINARY_DIR}/libs/${project_name}/lib${project_name}${CMAKE_STATIC_LIBRARY_SUFFIX}" # <--this is in-file
${CMAKE_CURRENT_SOURCE_DIR}/lib/osx) # <--this is out-file path

target_include_directories (${project_name} PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/..)
target_include_directories (${project_name} PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/../../contrib/include)
target_include_directories (${project_name} PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/../../contrib)
target_include_directories (${project_name} PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/../../contrib/deps)

13 changes: 8 additions & 5 deletions Doxyfile
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ PROJECT_LOGO =
# entered, it will be relative to the location where doxygen was started. If
# left blank the current directory will be used.

OUTPUT_DIRECTORY = ../../docs/wsh
OUTPUT_DIRECTORY = docs

# If the CREATE_SUBDIRS tag is set to YES then doxygen will create 4096 sub-
# directories (in 2 levels) under the output directory of each output format and
Expand Down Expand Up @@ -889,7 +889,10 @@ EXCLUDE_SYMLINKS = NO
# Note that the wildcards are matched against the file with absolute path, so to
# exclude all test directories for example use the pattern */test/*

EXCLUDE_PATTERNS =
EXCLUDE_PATTERNS = */contrib/*
EXCLUDE_PATTERNS += */build/*
EXCLUDE_PATTERNS += */demo/*
EXCLUDE_PATTERNS += */test/*

# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names
# (namespaces, classes, functions, etc.) that should be excluded from the
Expand Down Expand Up @@ -1581,7 +1584,7 @@ SEARCHENGINE = YES
# setting. When disabled, doxygen will generate a PHP script for searching and
# an index file used by the script. When EXTERNAL_SEARCH is enabled the indexing
# and searching needs to be provided by external tools. See the section
# "External Indexing and Searching" for details.
# "External Indexing and app_extensions.enable_audio" for details.
# The default value is: NO.
# This tag requires that the tag SEARCHENGINE is set to YES.

Expand All @@ -1597,7 +1600,7 @@ SERVER_BASED_SEARCH = NO
# (doxysearch.cgi) which are based on the open source search engine library
# Xapian (see: http://xapian.org/).
#
# See the section "External Indexing and Searching" for details.
# See the section "External Indexing and app_extensions.enable_audio" for details.
# The default value is: NO.
# This tag requires that the tag SEARCHENGINE is set to YES.

Expand All @@ -1609,7 +1612,7 @@ EXTERNAL_SEARCH = NO
# Doxygen ships with an example indexer (doxyindexer) and search engine
# (doxysearch.cgi) which are based on the open source search engine library
# Xapian (see: http://xapian.org/). See the section "External Indexing and
# Searching" for details.
# app_extensions.enable_audio" for details.
# This tag requires that the tag SEARCHENGINE is set to YES.

SEARCHENGINE_URL =
Expand Down
1 change: 0 additions & 1 deletion cJSON
Submodule cJSON deleted from 6f264b
72 changes: 72 additions & 0 deletions cmake/Modules/FindLibFTGL.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
# Find FTGL 3
#
# FTGL_LIBRARIES
# FTGL_INCLUDE_DIRS.
# FTGL_FOUND

IF(NOT UNIX)
IF(NOT FTGL_ROOT)
MESSAGE("ERROR: FTGL_ROOT must be set!")
ENDIF(NOT FTGL_ROOT)

FIND_PATH(FTGL_INCLUDE_DIRS DOC "Path to FTGL include directory."
NAMES FTGL/ftgl.h
PATHS ${FTGL_ROOT}/include)

IF(MSVC15)
FIND_LIBRARY(FTGL_LIBRARIES DOC "Absolute path to FTGL library."
NAMES ftgl.lib
PATHS ${FTGL_ROOT}/lib-vc2015)
ELSEIF(MSVC13)
FIND_LIBRARY(FTGL_LIBRARIES DOC "Absolute path to FTGL library."
NAMES ftgl.lib
PATHS ${FTGL_ROOT}/lib-vc2013)
ELSEIF(MSVC12)
FIND_LIBRARY(FTGL_LIBRARIES DOC "Absolute path to FTGL library."
NAMES ftgl.lib
PATHS ${FTGL_ROOT}/lib-vc2012)
ELSEIF(MSVC10)
FIND_LIBRARY(FTGL_LIBRARIES DOC "Absolute path to FTGL library."
NAMES ftgl.lib
PATHS ${FTGL_ROOT}/lib-vc2010)
ELSEIF(MINGW)
IF(CMAKE_CL_64)
FIND_LIBRARY(FTGL_LIBRARIES DOC "Absolute path to FTGL library."
NAMES ftgl.dll
PATHS ${FTGL_ROOT}/lib-mingw-w64)
ELSE(CMAKE_CL_64)
FIND_LIBRARY(FTGL_LIBRARIES DOC "Absolute path to FTGL library."
NAMES ftgl.dll
PATHS ${FTGL_ROOT}/lib-mingw)
ENDIF(CMAKE_CL_64)
ELSE(MINGW)
# Default to latest version of VC libs
FIND_LIBRARY(FTGL_LIBRARIES DOC "Absolute path to FTGL library."
NAMES ftgl.lib
PATHS ${FTGL_ROOT}/lib-vc2015)
ENDIF(MSVC15)
ELSE(NOT UNIX)
FIND_PATH(FTGL_INCLUDE_DIRS DOC "Path to FTGL include directory."
NAMES FTGL/ftgl.h
PATHS
/usr/include
/usr/local/include
/usr/target/include
/sw/include
/opt/local/include)

FIND_LIBRARY(FTGL_LIBRARIES DOC "Absolute path to FTGL library."
NAMES ftgl.dll ftgl.dylib libftgl.dylib libftgl.a
PATHS
/usr/local/lib
/usr/lib
/lib
contrib/ftgl/build
/usr/lib/arm-linux-gnueabihf)

ENDIF(NOT UNIX)

include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(FTGL DEFAULT_MSG FTGL_LIBRARIES FTGL_INCLUDE_DIRS)

mark_as_advanced(FTGL_INCLUDE_DIRS FTGL_LIBRARIES)
Loading