Compare commits
605 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
81fc70e33b | ||
|
4d597f3e2f | ||
|
3b6ffeaca7 | ||
|
176a795920 | ||
|
c58055adeb | ||
|
093a3fe5bb | ||
|
7581b642af | ||
|
6c4c45b0f9 | ||
|
4954e4970c | ||
|
32e849ebc9 | ||
|
e99816df7f | ||
|
7a280da946 | ||
|
b672545674 | ||
|
5c09f8e016 | ||
|
9070a59fce | ||
|
370101f340 | ||
|
9ed6494b47 | ||
|
50258e776a | ||
|
56689b2700 | ||
|
05aa616d6d | ||
|
dc858f4c5a | ||
|
e6afb53983 | ||
|
0d0c99de4d | ||
|
7a033414d5 | ||
|
f40644350e | ||
|
2eacd0b872 | ||
|
e525fd6ad2 | ||
|
f48cb55d33 | ||
|
15b2583e69 | ||
|
0da0275c18 | ||
|
b66f375869 | ||
|
6d1e872b4d | ||
|
e44b0af456 | ||
|
224f48fa0e | ||
|
18c066908f | ||
|
8ce97bc90b | ||
|
97f3782bb0 | ||
|
f87817bc03 | ||
|
9f984417b1 | ||
|
dace4784d1 | ||
|
c4fa1c2c62 | ||
|
e6ae74fd42 | ||
|
ea3193f52e | ||
|
bf961e3c29 | ||
|
d3dadd2392 | ||
|
d76b39abf1 | ||
|
7c441da0d1 | ||
|
e59839c8c2 | ||
|
c13de40280 | ||
|
4cf17e1c04 | ||
|
d1d3e057ca | ||
|
6662fe6313 | ||
|
9775fa6110 | ||
|
0c63f2f8b9 | ||
|
cfece3ef2e | ||
|
b0d96eb753 | ||
|
478ad1d19e | ||
|
1a0dfc1bfd | ||
|
59edf905b1 | ||
|
92345dc222 | ||
|
baaacd4683 | ||
|
ff2bd6ef48 | ||
|
8cc8a6925d | ||
|
cbdcce0d64 | ||
|
f114566d01 | ||
|
4d901cde7c | ||
|
650efe05be | ||
|
2a4611e19f | ||
|
472634fa06 | ||
|
2b3e2b780d | ||
|
06bc0a59fa | ||
|
89029d3342 | ||
|
624f732fb4 | ||
|
e4780e5287 | ||
|
25dfc507be | ||
|
f542b7bbf1 | ||
|
31211c6cfe | ||
|
2df785d7f1 | ||
|
61887a4ade | ||
|
9f2d973602 | ||
|
0f358da3e3 | ||
|
4eaaf9d812 | ||
|
952886f056 | ||
|
2dad173d8b | ||
|
712879c808 | ||
|
4e1bc39a81 | ||
|
2b73a1d19f | ||
|
0e9fe060f3 | ||
|
f63101c984 | ||
|
b09447ed89 | ||
|
7a59f4ce9f | ||
|
f2a88e54e8 | ||
|
c5ec75471a | ||
|
44fae8b193 | ||
|
810b672ff3 | ||
|
ec7c343f23 | ||
|
acc909a893 | ||
|
7755fe829e | ||
|
bda0b631c8 | ||
|
6cfc06f00d | ||
|
10ce324694 | ||
|
1209c1b923 | ||
|
465e686173 | ||
|
0577ae8ca4 | ||
|
9bcfd6f649 | ||
|
0fdbd10b91 | ||
|
e22105a97c | ||
|
77a11d3df1 | ||
|
400af1bcf6 | ||
|
5da3dfdf08 | ||
|
3b1a2e5158 | ||
|
731c9b5bc0 | ||
|
a8232603a0 | ||
|
0c5a6d479b | ||
|
b3d20c7f46 | ||
|
96fffdc609 | ||
|
5c20836e0d | ||
|
09f30297f4 | ||
|
ad03c23449 | ||
|
0a40a30da5 | ||
|
a20cce397a | ||
|
9f951ebc44 | ||
|
0f0f0c06d1 | ||
|
51663cb434 | ||
|
b6826918fe | ||
|
8613985b2a | ||
|
decdee7d3f | ||
|
06e06389ea | ||
|
4e66868ad7 | ||
|
a061150b0b | ||
|
1ef277c369 | ||
|
4b3d6eb1d2 | ||
|
09a4804444 | ||
|
ac0cdacd09 | ||
|
471b22dea3 | ||
|
eadea5ea03 | ||
|
24542bc056 | ||
|
5200cc4aa3 | ||
|
f838dac48b | ||
|
404c893694 | ||
|
0a8630615d | ||
|
3a4a396251 | ||
|
f79b19a17e | ||
|
640d5fe219 | ||
|
dbe54d10f9 | ||
|
4dba155d8e | ||
|
fcfda0392f | ||
|
4d9733588f | ||
|
2a79a1aeb4 | ||
|
20ef5652b7 | ||
|
fe1d4d6cff | ||
|
291fced1e6 | ||
|
a699468165 | ||
|
51db017972 | ||
|
483ce1bd89 | ||
|
b4327ba8df | ||
|
a148c938b0 | ||
|
8013367c92 | ||
|
b443d53628 | ||
|
a8b5267725 | ||
|
851f870162 | ||
|
e3cb774f2e | ||
|
89aebdea8d | ||
|
168077a6dc | ||
|
d96fd48ee5 | ||
|
7dd37838f7 | ||
|
8f16a18454 | ||
|
1dd28279c8 | ||
|
cde381c4e2 | ||
|
10f55672df | ||
|
aff1875311 | ||
|
bb2cf06962 | ||
|
946e65b9c5 | ||
|
7fbac3c240 | ||
|
2fb5823d31 | ||
|
ce73cfd073 | ||
|
4208cf1872 | ||
|
b3eab8efc3 | ||
|
5299b92ba1 | ||
|
41aa3c3d5d | ||
|
f9ac4dc9ab | ||
|
ebcbd82410 | ||
|
45b9409aa4 | ||
|
d673da182b | ||
|
f411f94fac | ||
|
383c6c9fb2 | ||
|
8511408796 | ||
|
c894a5fdfc | ||
|
6dd6e5c758 | ||
|
f9f740d6b0 | ||
|
564c82b4f2 | ||
|
16c93d97eb | ||
|
ef9a9362ae | ||
|
8022338566 | ||
|
f3495b0139 | ||
|
6fe58c66d9 | ||
|
45d0af05b9 | ||
|
197cddcfc9 | ||
|
424392e0d8 | ||
|
eca0539260 | ||
|
326b3e283a | ||
|
bf7b2cebbe | ||
|
72523826de | ||
|
7a1b96cb98 | ||
|
3b2af789dd | ||
|
aa7b761d4c | ||
|
9d420e021d | ||
|
d102153bc0 | ||
|
baed683824 | ||
|
d5cdd12a38 | ||
|
3bae95c8a2 | ||
|
17d16f7887 | ||
|
fa53efefc3 | ||
|
9c86076b21 | ||
|
4af9e8a8b7 | ||
|
b070046674 | ||
|
2a8d1e7bcf | ||
|
71c089e99b | ||
|
2915f0b590 | ||
|
e7b01db7c4 | ||
|
a1565817f1 | ||
|
0e5ef9264f | ||
|
63dbfc04f8 | ||
|
c2bf27a6fb | ||
|
ecf4f17cb8 | ||
|
6e728f3b5c | ||
|
0d0481c787 | ||
|
b2134621cc | ||
|
a0ad45bf9a | ||
|
997e128f88 | ||
|
be70005cb5 | ||
|
9c189bd8dc | ||
|
1475265b58 | ||
|
e841c38c71 | ||
|
579f2938a8 | ||
|
f73c584ceb | ||
|
a3d4053c15 | ||
|
10c5aa00b0 | ||
|
953d87f32c | ||
|
681f3919f0 | ||
|
4a6d278356 | ||
|
434ffc0909 | ||
|
62ef08dfc8 | ||
|
d4507e82ba | ||
|
bc9a61ec69 | ||
|
ff1541f179 | ||
|
8878d0ecce | ||
|
f0cddd16eb | ||
|
c9c7286e56 | ||
|
e2e0498b17 | ||
|
416022a12f | ||
|
320a322080 | ||
|
43d3f6d8d8 | ||
|
4d19a2c5e7 | ||
|
ee5befae97 | ||
|
30f5e1a74b | ||
|
91764a8f6d | ||
|
e2a37a80f6 | ||
|
a965c45b2d | ||
|
ee905e847d | ||
|
0391af0aa1 | ||
|
964e27d91c | ||
|
d26375e22c | ||
|
dc6ae350f3 | ||
|
15173be5c9 | ||
|
be86ba90c4 | ||
|
6b8f3bdc36 | ||
|
95f8c6082d | ||
|
dd6b34fda4 | ||
|
9bba178dce | ||
|
1beb58d745 | ||
|
f204ec4c37 | ||
|
75378f50ea | ||
|
4945db69e5 | ||
|
7bbccb5f4e | ||
|
d94bed0e26 | ||
|
0b622d670d | ||
|
3f317e7d0c | ||
|
871dcdc201 | ||
|
dd115e1227 | ||
|
73ddbb9acc | ||
|
b969ebe7cf | ||
|
7c3ef2f752 | ||
|
ebc369da1d | ||
|
df18769ea6 | ||
|
caf231b050 | ||
|
2ec85268a1 | ||
|
1be4179947 | ||
|
bf95447514 | ||
|
c8c250a59d | ||
|
8b1441e374 | ||
|
a8122531ce | ||
|
922da0a825 | ||
|
5f4bd4d4d2 | ||
|
bd6a845441 | ||
|
bbbca107a2 | ||
|
d07a6c39cf | ||
|
d1d68ce714 | ||
|
c4a2f61e57 | ||
|
0f5ea4b5f8 | ||
|
b88b0cf7fc | ||
|
3c1624950a | ||
|
4e283d3379 | ||
|
e146ef9a93 | ||
|
d30895f5da | ||
|
fe4fc02d7b | ||
|
90b858262b | ||
|
95ae6ebb1b | ||
|
41ce5887ad | ||
|
88e55ec7ef | ||
|
d877e61038 | ||
|
ede89abcb9 | ||
|
b2bafb33a9 | ||
|
ece3f95012 | ||
|
c58b30780a | ||
|
c381fda2d6 | ||
|
f4dee9bb20 | ||
|
73594f7248 | ||
|
3a5a656c15 | ||
|
0d5880e11a | ||
|
949c9b7f28 | ||
|
8e5fb5eabc | ||
|
3a9b5dc86a | ||
|
6a24c6ded9 | ||
|
1f7f5a900f | ||
|
778cd66786 | ||
|
27ba9c6006 | ||
|
e8e26df06c | ||
|
14cb22a1a4 | ||
|
8d795b5130 | ||
|
b1c5466550 | ||
|
e620e2857f | ||
|
b357dcc225 | ||
|
84bd25527c | ||
|
5da005403b | ||
|
aea33d0ab8 | ||
|
a2f76b15f1 | ||
|
fb0b05319f | ||
|
935069d23d | ||
|
14ea8abd0a | ||
|
4aaadad7bc | ||
|
49e5d23824 | ||
|
46f4a251a0 | ||
|
d0aafb064b | ||
|
3202bf1e9e | ||
|
ef444297f5 | ||
|
4897e58dcd | ||
|
70ca46fecc | ||
|
d2edda76a9 | ||
|
c204d492ae | ||
|
a165f00280 | ||
|
099f351396 | ||
|
c10703215e | ||
|
7b3aef359f | ||
|
15b9dfc95d | ||
|
849c137461 | ||
|
5c7744eaef | ||
|
71d8ccc753 | ||
|
1ae83f5727 | ||
|
6b5b9abf8b | ||
|
7f3bf449a9 | ||
|
c45fefa76e | ||
|
02974a19c6 | ||
|
3065019c99 | ||
|
84caaf81a0 | ||
|
4e785ab59b | ||
|
1f9fb70723 | ||
|
f1fb0901d6 | ||
|
e5d7e24960 | ||
|
aa75c0cf9d | ||
|
1ce0716bb1 | ||
|
21a2b7ccf4 | ||
|
26d9c83516 | ||
|
e7879c5796 | ||
|
413b1c1a97 | ||
|
fe0d928d97 | ||
|
3bffef5524 | ||
|
1ede545fef | ||
|
150ed3d5ef | ||
|
0766573201 | ||
|
8b1e055f0b | ||
|
87b48b40c6 | ||
|
45396f870c | ||
|
dde6883382 | ||
|
3fe9ce0edd | ||
|
742cc8b01d | ||
|
f3ec3b372c | ||
|
1593b4eeab | ||
|
94afca11a0 | ||
|
e5b8456d5b | ||
|
0deb6f045f | ||
|
5185b1617a | ||
|
2613378e60 | ||
|
1a7ece8f23 | ||
|
afa6834bcd | ||
|
4eb65ae9ee | ||
|
60273f7774 | ||
|
3a17b16845 | ||
|
ae54125247 | ||
|
2cc873e2a2 | ||
|
5146b5baa3 | ||
|
bf3220cfc5 | ||
|
e91a710c7e | ||
|
032881f4fb | ||
|
b47bcd7ea7 | ||
|
5a0fc7ce60 | ||
|
2ba9eb3059 | ||
|
7cb2f40993 | ||
|
3e05329c4c | ||
|
89a929ea26 | ||
|
4ad142d9cb | ||
|
521b0d7f81 | ||
|
520cde8769 | ||
|
c885cfda24 | ||
|
deb02f8655 | ||
|
c58b1b6257 | ||
|
9016c8bd2e | ||
|
3cb0f659d8 | ||
|
3db69e4133 | ||
|
57fbfb8e7b | ||
|
d5514578e8 | ||
|
8cea17de84 | ||
|
a4785842e4 | ||
|
bb526112b1 | ||
|
3475df12a6 | ||
|
82cf4904ea | ||
|
e2d7642f14 | ||
|
6d0e6be5a2 | ||
|
d509e5a43f | ||
|
6887652ac6 | ||
|
cde2e2f0ca | ||
|
2e5139af6b | ||
|
d01ed5fdd1 | ||
|
458e3c0deb | ||
|
c6f530b8d9 | ||
|
30c1ef75af | ||
|
990ab183dd | ||
|
a85215df86 | ||
|
79cbd2cf60 | ||
|
be3752526f | ||
|
66cce03ae5 | ||
|
4c6b4bc75a | ||
|
07ef8bdfa2 | ||
|
01b5b3df55 | ||
|
1aee6c8210 | ||
|
056072196c | ||
|
59ec40f804 | ||
|
0f1deae3b4 | ||
|
fb66bb2892 | ||
|
c65f82013b | ||
|
56091b56ac | ||
|
758bacbb66 | ||
|
ce0594b85e | ||
|
4aa09e317f | ||
|
b2fbf11a4f | ||
|
b647266461 | ||
|
28cab3768f | ||
|
536a3cb80c | ||
|
593dfe97ea | ||
|
60adbe67f2 | ||
|
f7991731de | ||
|
a7cc4fdd0d | ||
|
c4684140fb | ||
|
693c4bbe60 | ||
|
6482df8152 | ||
|
fd59283a7b | ||
|
1d92133e83 | ||
|
fbad941bd4 | ||
|
8109385697 | ||
|
4f51d9d704 | ||
|
dcc1741921 | ||
|
caee72a96e | ||
|
3eabbe1b4e | ||
|
3ba87fdb66 | ||
|
745c138678 | ||
|
782467fd42 | ||
|
576e306647 | ||
|
04be500328 | ||
|
8009d0702c | ||
|
d52651755e | ||
|
6fe96f8416 | ||
|
8072aba1ae | ||
|
f2474958ef | ||
|
9cc4e7e2db | ||
|
f9ba5c4ddd | ||
|
2831708b17 | ||
|
a47d34efa9 | ||
|
284c923864 | ||
|
5bbe7380bd | ||
|
9bf3ef8355 | ||
|
e4ff2bbb05 | ||
|
f767cea690 | ||
|
3672371654 | ||
|
dfb3bdd43a | ||
|
29627b4cdb | ||
|
7ccf8676cf | ||
|
a13f2dc486 | ||
|
21a8e27535 | ||
|
d7b1999736 | ||
|
45d5cbf836 | ||
|
913295d5dd | ||
|
9c1519c4c5 | ||
|
6f21399c0d | ||
|
9d1bf7ae05 | ||
|
1b9f5d9504 | ||
|
907fb7a5e0 | ||
|
9d671cd1b0 | ||
|
bd80ecfa61 | ||
|
747db83cdd | ||
|
6728599615 | ||
|
f117cc5a81 | ||
|
67e26cc101 | ||
|
77a6c8313f | ||
|
473cddc1d9 | ||
|
854e0d4a27 | ||
|
f84bf635f0 | ||
|
1ec75a485b | ||
|
c1609fbea6 | ||
|
91d9637224 | ||
|
be5c360207 | ||
|
83b0f13a58 | ||
|
52db475165 | ||
|
93dc7934db | ||
|
34e4e9f26e | ||
|
a3d2cb2425 | ||
|
4b445d1848 | ||
|
b819ae67ce | ||
|
c574faecb9 | ||
|
b0fbc5796a | ||
|
625e195819 | ||
|
402cfabc21 | ||
|
1e7ac41bf8 | ||
|
77887d30d8 | ||
|
b94d48585b | ||
|
50d06d8fcf | ||
|
5ae6e53dec | ||
|
41e08b4df8 | ||
|
a002d297f7 | ||
|
f2b6318110 | ||
|
7d46a9ed8b | ||
|
88d533be65 | ||
|
6b52f1253e | ||
|
38c2acd423 | ||
|
55fb31dae4 | ||
|
882e1d11aa | ||
|
871776ea38 | ||
|
09eca2b5b3 | ||
|
5501f9a946 | ||
|
e64622331f | ||
|
264abd72f2 | ||
|
e5260e1dfa | ||
|
e1c1b6b9f4 | ||
|
f02e43eb35 | ||
|
0911d065ff | ||
|
3d370858dd | ||
|
3e6a4cd02a | ||
|
38f24151f6 | ||
|
4613a51fd4 | ||
|
aa1b48c7dd | ||
|
18151f1aa1 | ||
|
15a954deb5 | ||
|
8d0b864941 | ||
|
c9de149dec | ||
|
a1530ab1b8 | ||
|
c59fcd1186 | ||
|
b7b2f85ac1 | ||
|
8e509b0ba1 | ||
|
a9b51f4977 | ||
|
5951a08873 | ||
|
5950d7816e | ||
|
7856b126b0 | ||
|
3a507ddb47 | ||
|
79997052f1 | ||
|
b55bd02353 | ||
|
246c7a7554 | ||
|
4b5857d330 | ||
|
04cd0c6dda | ||
|
e13e5f39c5 | ||
|
a139a35380 | ||
|
eaffb01e7e | ||
|
3e64931da5 | ||
|
92788bf4bb | ||
|
360f800be8 | ||
|
7f56eba8cd | ||
|
299e0ab98f | ||
|
b8f67cc236 | ||
|
8b9a309b48 | ||
|
3f1eb0abf9 | ||
|
016e595986 | ||
|
83da37b115 | ||
|
6143f12f36 | ||
|
9a9a3edfd8 | ||
|
02fd709bbb | ||
|
4680293609 | ||
|
a0bb29e79e | ||
|
46bd680a25 | ||
|
3321f6847d | ||
|
f7ac9097ee | ||
|
601b1c8d56 | ||
|
309bad284d | ||
|
79981d14cc | ||
|
f0bf70e8cc | ||
|
8f8398f6e4 | ||
|
94074ec660 | ||
|
9d034c3730 |
3
.gitattributes
vendored
@@ -37,6 +37,9 @@
|
|||||||
*.vrml eol=lf
|
*.vrml eol=lf
|
||||||
*.md eol=lf
|
*.md eol=lf
|
||||||
*.natvis eol=lf
|
*.natvis eol=lf
|
||||||
|
*.fs eol=lf
|
||||||
|
*.vs eol=lf
|
||||||
|
*.glsl eol=lf
|
||||||
FILES eol=lf
|
FILES eol=lf
|
||||||
PACKAGES eol=lf
|
PACKAGES eol=lf
|
||||||
EXTERNLIB eol=lf
|
EXTERNLIB eol=lf
|
||||||
|
1
.gitignore
vendored
@@ -49,6 +49,7 @@ Release
|
|||||||
/*.m4
|
/*.m4
|
||||||
/*.ac
|
/*.ac
|
||||||
/*.sh
|
/*.sh
|
||||||
|
/codeblocks.bat
|
||||||
/custom.bat
|
/custom.bat
|
||||||
/autom4te.cache
|
/autom4te.cache
|
||||||
/build_configure
|
/build_configure
|
||||||
|
269
CMakeLists.txt
@@ -24,13 +24,24 @@ endif()
|
|||||||
|
|
||||||
if ("${BUILD_LIBRARY_TYPE}" STREQUAL "Shared")
|
if ("${BUILD_LIBRARY_TYPE}" STREQUAL "Shared")
|
||||||
set (BUILD_SHARED_LIBS ON)
|
set (BUILD_SHARED_LIBS ON)
|
||||||
|
|
||||||
|
if (NOT DEFINED BUILD_SHARED_LIBRARY_NAME_POSTFIX)
|
||||||
|
set (BUILD_SHARED_LIBRARY_NAME_POSTFIX "" CACHE STRING "${BUILD_SHARED_LIBRARY_NAME_POSTFIX_DESCR}" FORCE)
|
||||||
|
endif()
|
||||||
else()
|
else()
|
||||||
unset (BUILD_SHARED_LIBS)
|
unset (BUILD_SHARED_LIBS)
|
||||||
|
message (STATUS "Info: Only 3rdparty's header files are used for building of static OCCT libraries")
|
||||||
|
unset (BUILD_SHARED_LIBRARY_NAME_POSTFIX)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# the name of the project
|
# the name of the project
|
||||||
project (OCCT)
|
project (OCCT)
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
add_definitions(-DUNICODE)
|
||||||
|
add_definitions(-D_UNICODE)
|
||||||
|
endif()
|
||||||
|
|
||||||
# include occt macros
|
# include occt macros
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/occt_macros")
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/occt_macros")
|
||||||
|
|
||||||
@@ -46,6 +57,9 @@ set_property (GLOBAL PROPERTY OCC_VERSION_MAINTENANCE ${OCC_VERSION_MAINTENANCE}
|
|||||||
|
|
||||||
set (INSTALL_TEST_CASES OFF CACHE BOOL "${INSTALL_TEST_CASES_DESCR}")
|
set (INSTALL_TEST_CASES OFF CACHE BOOL "${INSTALL_TEST_CASES_DESCR}")
|
||||||
|
|
||||||
|
# Regeneration of OCCT resource files
|
||||||
|
set (BUILD_RESOURCES OFF CACHE BOOL "${BUILD_RESOURCES_DESCR}")
|
||||||
|
|
||||||
# single-configuration generator
|
# single-configuration generator
|
||||||
set (SINGLE_GENERATOR OFF)
|
set (SINGLE_GENERATOR OFF)
|
||||||
if (CMAKE_BUILD_TYPE)
|
if (CMAKE_BUILD_TYPE)
|
||||||
@@ -59,9 +73,16 @@ if (DEFINED CMAKE_BUILD_TYPE AND NOT CMAKE_BUILD_TYPE) # single-configuration ge
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
# enable extended messages of many OCCT algorithms
|
# enable extended messages of many OCCT algorithms
|
||||||
set (BUILD_WITH_DEBUG OFF CACHE BOOL "${BUILD_WITH_DEBUG_DESCR}")
|
if (((SINGLE_GENERATOR AND "${CMAKE_BUILD_TYPE}" STREQUAL "Debug") OR NOT SINGLE_GENERATOR) AND (NOT "${CMAKE_SYSTEM_NAME}" STREQUAL "WindowsStore"))
|
||||||
|
if (NOT BUILD_WITH_DEBUG)
|
||||||
|
set (BUILD_WITH_DEBUG OFF CACHE BOOL "${BUILD_WITH_DEBUG_DESCR}")
|
||||||
|
endif()
|
||||||
|
else()
|
||||||
|
OCCT_CHECK_AND_UNSET (BUILD_WITH_DEBUG)
|
||||||
|
endif()
|
||||||
|
|
||||||
if (BUILD_WITH_DEBUG)
|
if (BUILD_WITH_DEBUG)
|
||||||
add_definitions (-DOCCT_DEBUG)
|
set_property(DIRECTORY APPEND PROPERTY COMPILE_DEFINITIONS $<$<CONFIG:DEBUG>:OCCT_DEBUG>)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# copy samples to install directory
|
# copy samples to install directory
|
||||||
@@ -272,13 +293,20 @@ if (NOT DEFINED INSTALL_DIR_CMAKE)
|
|||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
# include occt macros
|
||||||
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/occt_resources")
|
||||||
|
|
||||||
# install LICENSE_LGPL_21.txt and OCCT_LGPL_EXCEPTION.txt files
|
# install LICENSE_LGPL_21.txt and OCCT_LGPL_EXCEPTION.txt files
|
||||||
if ("${INSTALL_DIR_LAYOUT}" STREQUAL "Unix")
|
if ("${INSTALL_DIR_LAYOUT}" STREQUAL "Unix")
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("LICENSE_LGPL_21.txt" "${INSTALL_DIR}/${INSTALL_DIR_DOC}")
|
OCCT_INSTALL_FILE_OR_DIR ("LICENSE_LGPL_21.txt" "${INSTALL_DIR_DOC}")
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("OCCT_LGPL_EXCEPTION.txt" "${INSTALL_DIR}/${INSTALL_DIR_DOC}")
|
OCCT_INSTALL_FILE_OR_DIR ("OCCT_LGPL_EXCEPTION.txt" "${INSTALL_DIR_DOC}")
|
||||||
else()
|
else()
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("LICENSE_LGPL_21.txt" "${INSTALL_DIR}")
|
OCCT_INSTALL_FILE_OR_DIR ("LICENSE_LGPL_21.txt" ".")
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("OCCT_LGPL_EXCEPTION.txt" "${INSTALL_DIR}")
|
OCCT_INSTALL_FILE_OR_DIR ("OCCT_LGPL_EXCEPTION.txt" ".")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if(APPLE)
|
||||||
|
set (INSTALL_NAME_DIR "" CACHE STRING "install_name library suffix on OS X (e.g. @executable_path/../Frameworks)")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# a directory recognized as a 'patch' for OCCT
|
# a directory recognized as a 'patch' for OCCT
|
||||||
@@ -292,6 +320,15 @@ if (MSVC)
|
|||||||
set (BUILD_MODULE_MfcSamples OFF CACHE BOOL "${BUILD_MODULE_MfcSamples_DESCR}")
|
set (BUILD_MODULE_MfcSamples OFF CACHE BOOL "${BUILD_MODULE_MfcSamples_DESCR}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
# uwp sample
|
||||||
|
if (MSVC)
|
||||||
|
if ("${CMAKE_SYSTEM_NAME}" STREQUAL "WindowsStore")
|
||||||
|
set (BUILD_MODULE_UwpSample OFF CACHE BOOL "${BUILD_MODULE_UwpSample_DESCR}")
|
||||||
|
else()
|
||||||
|
unset (BUILD_MODULE_UwpSample)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
# whether use optional 3rdparty or not
|
# whether use optional 3rdparty or not
|
||||||
if (APPLE)
|
if (APPLE)
|
||||||
set (USE_GLX OFF CACHE BOOL "${USE_GLX_DESCR}")
|
set (USE_GLX OFF CACHE BOOL "${USE_GLX_DESCR}")
|
||||||
@@ -301,6 +338,17 @@ if (WIN32)
|
|||||||
set (USE_D3D OFF CACHE BOOL "${USE_D3D_DESCR}")
|
set (USE_D3D OFF CACHE BOOL "${USE_D3D_DESCR}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
# Enable/Disable the floating point exceptions (FPE) during runtime.
|
||||||
|
if (NOT BUILD_ENABLE_FPE_SIGNAL_HANDLER)
|
||||||
|
set (BUILD_ENABLE_FPE_SIGNAL_HANDLER OFF CACHE BOOL "${BUILD_ENABLE_FPE_SIGNAL_HANDLER_DESCR}" FORCE)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (BUILD_ENABLE_FPE_SIGNAL_HANDLER)
|
||||||
|
set (BUILD_ENABLE_FPE_SIGNAL_HANDLER 1)
|
||||||
|
else()
|
||||||
|
set (BUILD_ENABLE_FPE_SIGNAL_HANDLER 0)
|
||||||
|
endif()
|
||||||
|
|
||||||
# include the patched or original list of modules
|
# include the patched or original list of modules
|
||||||
# list <MODULENAME>_TOOLKITS is created foreach module and contains its toolkits
|
# list <MODULENAME>_TOOLKITS is created foreach module and contains its toolkits
|
||||||
# list <OCCT_MODULES> will contain all modules
|
# list <OCCT_MODULES> will contain all modules
|
||||||
@@ -314,9 +362,23 @@ if (ANDROID AND BUILD_MODULE_Draw)
|
|||||||
message (STATUS "Info. Draw module is turned off due to it is not supported on Android")
|
message (STATUS "Info. Draw module is turned off due to it is not supported on Android")
|
||||||
set (BUILD_MODULE_Draw OFF CACHE BOOL "${BUILD_MODULE_Draw_DESCR}" FORCE)
|
set (BUILD_MODULE_Draw OFF CACHE BOOL "${BUILD_MODULE_Draw_DESCR}" FORCE)
|
||||||
endif()
|
endif()
|
||||||
|
if ("${CMAKE_SYSTEM_NAME}" STREQUAL "WindowsStore" AND BUILD_MODULE_Draw)
|
||||||
|
message (STATUS "Info. Draw module is turned off due to it is not supported on UWP")
|
||||||
|
set (BUILD_MODULE_Draw OFF CACHE BOOL "${BUILD_MODULE_Draw_DESCR}" FORCE)
|
||||||
|
endif()
|
||||||
|
|
||||||
# Overview
|
# Overview
|
||||||
set (BUILD_DOC_Overview OFF CACHE BOOL "${BUILD_DOC_Overview_DESCR}")
|
if (NOT DEFINED BUILD_DOC_Overview)
|
||||||
|
set (DO_ONLY_CHECK_FOR_DOXYGEN ON)
|
||||||
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/doxygen")
|
||||||
|
set (DO_ONLY_CHECK_FOR_DOXYGEN OFF)
|
||||||
|
|
||||||
|
if (CAN_DOXYGEN_BE_USED)
|
||||||
|
message (STATUS "Info. Overview building is turned on")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
set (BUILD_DOC_Overview ${CAN_DOXYGEN_BE_USED} CACHE BOOL "${BUILD_DOC_Overview_DESCR}")
|
||||||
|
endif()
|
||||||
|
|
||||||
if (NOT USE_D3D)
|
if (NOT USE_D3D)
|
||||||
list (REMOVE_ITEM Visualization_TOOLKITS TKD3DHost)
|
list (REMOVE_ITEM Visualization_TOOLKITS TKD3DHost)
|
||||||
@@ -446,29 +508,51 @@ endif()
|
|||||||
|
|
||||||
# FREEIMAGE
|
# FREEIMAGE
|
||||||
# search for CSF_FREEIMAGE variable in EXTERNLIB of each being used toolkit
|
# search for CSF_FREEIMAGE variable in EXTERNLIB of each being used toolkit
|
||||||
OCCT_IS_PRODUCT_REQUIRED (CSF_FREEIMAGE CAN_USE_FREEIMAGE)
|
OCCT_IS_PRODUCT_REQUIRED (CSF_FreeImagePlus CAN_USE_FREEIMAGE)
|
||||||
OCCT_IS_PRODUCT_REQUIRED (CSF_FreeImagePlus CAN_USE_FREEIMAGEPLUS)
|
|
||||||
|
|
||||||
if (CAN_USE_FREEIMAGE OR CAN_USE_FREEIMAGEPLUS)
|
if (CAN_USE_FREEIMAGE)
|
||||||
set (USE_FREEIMAGE OFF CACHE BOOL "${USE_FREEIMAGE_DESCR}")
|
set (USE_FREEIMAGE OFF CACHE BOOL "${USE_FREEIMAGE_DESCR}")
|
||||||
|
|
||||||
if (USE_FREEIMAGE)
|
if (USE_FREEIMAGE)
|
||||||
add_definitions (-DHAVE_FREEIMAGE)
|
add_definitions (-DHAVE_FREEIMAGE)
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/freeimage")
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/freeimage")
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/freeimageplus")
|
|
||||||
else()
|
else()
|
||||||
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_FREEIMAGE")
|
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_FREEIMAGE")
|
||||||
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_FREEIMAGEPLUS")
|
|
||||||
OCCT_CHECK_AND_UNSET ("INSTALL_FREEIMAGE")
|
OCCT_CHECK_AND_UNSET ("INSTALL_FREEIMAGE")
|
||||||
OCCT_CHECK_AND_UNSET ("INSTALL_FREEIMAGEPLUS")
|
|
||||||
endif()
|
endif()
|
||||||
else()
|
else()
|
||||||
OCCT_CHECK_AND_UNSET ("USE_FREEIMAGE")
|
OCCT_CHECK_AND_UNSET ("USE_FREEIMAGE")
|
||||||
|
|
||||||
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_FREEIMAGE")
|
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_FREEIMAGE")
|
||||||
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_FREEIMAGEPLUS")
|
|
||||||
OCCT_CHECK_AND_UNSET ("INSTALL_FREEIMAGE")
|
OCCT_CHECK_AND_UNSET ("INSTALL_FREEIMAGE")
|
||||||
OCCT_CHECK_AND_UNSET ("INSTALL_FREEIMAGEPLUS")
|
endif()
|
||||||
|
|
||||||
|
# OpenGL ES 2.0
|
||||||
|
OCCT_IS_PRODUCT_REQUIRED (CSF_OpenGlLibs CAN_USE_GLES2)
|
||||||
|
if (WIN32 AND CAN_USE_GLES2)
|
||||||
|
if ("${CMAKE_SYSTEM_NAME}" STREQUAL "WindowsStore")
|
||||||
|
set (USE_GLES2 ON)
|
||||||
|
else()
|
||||||
|
set (USE_GLES2 OFF CACHE BOOL "${USE_GLES2_DESCR}")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (USE_GLES2)
|
||||||
|
add_definitions (-DHAVE_GLES2)
|
||||||
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/egl")
|
||||||
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/gles2")
|
||||||
|
else()
|
||||||
|
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_EGL")
|
||||||
|
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_GLES2")
|
||||||
|
OCCT_CHECK_AND_UNSET ("INSTALL_EGL")
|
||||||
|
OCCT_CHECK_AND_UNSET ("INSTALL_GLES2")
|
||||||
|
endif()
|
||||||
|
else()
|
||||||
|
OCCT_CHECK_AND_UNSET ("USE_GLES2")
|
||||||
|
|
||||||
|
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_EGL")
|
||||||
|
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_GLES2")
|
||||||
|
OCCT_CHECK_AND_UNSET ("INSTALL_EGL")
|
||||||
|
OCCT_CHECK_AND_UNSET ("INSTALL_GLES2")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# GL2PS
|
# GL2PS
|
||||||
@@ -515,6 +599,25 @@ else()
|
|||||||
OCCT_CHECK_AND_UNSET ("INSTALL_TBB")
|
OCCT_CHECK_AND_UNSET ("INSTALL_TBB")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
# EIGEN
|
||||||
|
# search for CSF_EIGEN variable in EXTERNLIB of each being used toolkit
|
||||||
|
OCCT_IS_PRODUCT_REQUIRED (CSF_EIGEN CAN_USE_EIGEN)
|
||||||
|
|
||||||
|
if (CAN_USE_EIGEN)
|
||||||
|
set (USE_EIGEN OFF CACHE BOOL "${USE_EIGEN_DESCR}")
|
||||||
|
|
||||||
|
if (USE_EIGEN)
|
||||||
|
add_definitions (-DHAVE_EIGEN)
|
||||||
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/eigen")
|
||||||
|
else()
|
||||||
|
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_EIGEN")
|
||||||
|
endif()
|
||||||
|
else()
|
||||||
|
OCCT_CHECK_AND_UNSET ("USE_EIGEN")
|
||||||
|
|
||||||
|
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_EIGEN")
|
||||||
|
endif()
|
||||||
|
|
||||||
# Doxygen
|
# Doxygen
|
||||||
if (BUILD_DOC_Overview)
|
if (BUILD_DOC_Overview)
|
||||||
if (NOT DEFINED INSTALL_DOC_Overview)
|
if (NOT DEFINED INSTALL_DOC_Overview)
|
||||||
@@ -522,11 +625,11 @@ if (BUILD_DOC_Overview)
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (INSTALL_DOC_Overview)
|
if (INSTALL_DOC_Overview)
|
||||||
install (DIRECTORY "${CMAKE_BINARY_DIR}/doc/overview" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_DOC}")
|
install (DIRECTORY "${CMAKE_BINARY_DIR}/doc/overview" DESTINATION "${INSTALL_DIR_DOC}")
|
||||||
|
|
||||||
# create overview.html only for windows
|
# create overview.html only for windows
|
||||||
if (WIN32 AND "${INSTALL_DIR_LAYOUT}" STREQUAL "Windows")
|
if (WIN32 AND "${INSTALL_DIR_LAYOUT}" STREQUAL "Windows")
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("dox/resources/overview.html" "${INSTALL_DIR}/${INSTALL_DIR_DOC}/..")
|
OCCT_INSTALL_FILE_OR_DIR ("dox/resources/overview.html" "${INSTALL_DIR_DOC}/..")
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -569,7 +672,7 @@ endif()
|
|||||||
# include <cmake binary folder>/inc
|
# include <cmake binary folder>/inc
|
||||||
include_directories (${CMAKE_BINARY_DIR}/inc)
|
include_directories (${CMAKE_BINARY_DIR}/inc)
|
||||||
|
|
||||||
if (3RDPARTY_LIBRARY_DIRS)
|
if (3RDPARTY_LIBRARY_DIRS AND BUILD_SHARED_LIBS)
|
||||||
list (REMOVE_DUPLICATES 3RDPARTY_LIBRARY_DIRS)
|
list (REMOVE_DUPLICATES 3RDPARTY_LIBRARY_DIRS)
|
||||||
string (REGEX REPLACE ";" "\n\t" 3RDPARTY_LIBRARY_DIRS_WITH_ENDS "${3RDPARTY_LIBRARY_DIRS}")
|
string (REGEX REPLACE ";" "\n\t" 3RDPARTY_LIBRARY_DIRS_WITH_ENDS "${3RDPARTY_LIBRARY_DIRS}")
|
||||||
message (STATUS "Info: The directories of 3rdparty libraries: \n\t${3RDPARTY_LIBRARY_DIRS_WITH_ENDS}")
|
message (STATUS "Info: The directories of 3rdparty libraries: \n\t${3RDPARTY_LIBRARY_DIRS_WITH_ENDS}")
|
||||||
@@ -613,7 +716,11 @@ COLLECT_AND_INSTALL_OCCT_HEADER_FILES ("${CMAKE_BINARY_DIR}" "${BUILD_TOOLKITS}"
|
|||||||
string(TIMESTAMP CURRENT_TIME "%H:%M:%S")
|
string(TIMESTAMP CURRENT_TIME "%H:%M:%S")
|
||||||
message (STATUS "Info: \(${CURRENT_TIME}\) End the collecting")
|
message (STATUS "Info: \(${CURRENT_TIME}\) End the collecting")
|
||||||
|
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("data/" "${INSTALL_DIR}/${INSTALL_DIR_DATA}")
|
list (FIND BUILD_TOOLKITS DRAWEXE DRAWEXE_INDEX)
|
||||||
|
if (${DRAWEXE_INDEX} GREATER -1)
|
||||||
|
OCCT_INSTALL_FILE_OR_DIR ("data/" "${INSTALL_DIR_DATA}")
|
||||||
|
OCCT_INSTALL_FILE_OR_DIR ("samples/tcl" "${INSTALL_DIR_SAMPLES}")
|
||||||
|
endif()
|
||||||
|
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
set (SCRIPT_EXT bat)
|
set (SCRIPT_EXT bat)
|
||||||
@@ -622,42 +729,57 @@ else()
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
# OCCT samples
|
# OCCT samples
|
||||||
|
# get absolute path from INSTALL_DIR
|
||||||
|
set (INSTALL_DIR_ABSOLUTE "${INSTALL_DIR}")
|
||||||
|
if(NOT IS_ABSOLUTE "${INSTALL_DIR_ABSOLUTE}")
|
||||||
|
get_filename_component(INSTALL_DIR_ABSOLUTE "${CMAKE_BINARY_DIR}/${INSTALL_DIR}" ABSOLUTE)
|
||||||
|
endif()
|
||||||
|
|
||||||
if (INSTALL_SAMPLES)
|
if (INSTALL_SAMPLES)
|
||||||
OCCT_CONFIGURE ("adm/templates/env.samples.${SCRIPT_EXT}.in" "env.samples.${SCRIPT_EXT}")
|
OCCT_CONFIGURE ("adm/templates/env.samples.${SCRIPT_EXT}.in" "env.samples.${SCRIPT_EXT}")
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/CSharp" "${INSTALL_DIR}/${INSTALL_DIR_SAMPLES}")
|
OCCT_INSTALL_FILE_OR_DIR ("samples/CSharp" "${INSTALL_DIR_SAMPLES}")
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/mfc" "${INSTALL_DIR}/${INSTALL_DIR_SAMPLES}")
|
OCCT_INSTALL_FILE_OR_DIR ("samples/mfc" "${INSTALL_DIR_SAMPLES}")
|
||||||
|
|
||||||
install (FILES "${CMAKE_BINARY_DIR}/env.samples.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_SAMPLES}/CSharp" RENAME "env.${SCRIPT_EXT}")
|
if ("${CMAKE_SYSTEM_NAME}" STREQUAL "WindowsStore")
|
||||||
install (FILES "${CMAKE_BINARY_DIR}/env.samples.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_SAMPLES}/mfc/standard" RENAME "env.${SCRIPT_EXT}")
|
OCCT_INSTALL_FILE_OR_DIR ("samples/xaml" "${INSTALL_DIR_SAMPLES}")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
install (FILES "${CMAKE_BINARY_DIR}/env.samples.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR_SAMPLES}/CSharp" RENAME "env.${SCRIPT_EXT}")
|
||||||
|
install (FILES "${CMAKE_BINARY_DIR}/env.samples.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR_SAMPLES}/mfc/standard" RENAME "env.${SCRIPT_EXT}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/java" "${INSTALL_DIR}/${INSTALL_DIR_SAMPLES}")
|
OCCT_INSTALL_FILE_OR_DIR ("samples/java" "${INSTALL_DIR_SAMPLES}")
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/ocafsamples" "${INSTALL_DIR}/${INSTALL_DIR_SAMPLES}")
|
OCCT_INSTALL_FILE_OR_DIR ("samples/ocafsamples" "${INSTALL_DIR_SAMPLES}")
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/qt" "${INSTALL_DIR}/${INSTALL_DIR_SAMPLES}")
|
OCCT_INSTALL_FILE_OR_DIR ("samples/qt" "${INSTALL_DIR_SAMPLES}")
|
||||||
|
|
||||||
install (FILES "${CMAKE_BINARY_DIR}/env.samples.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_SAMPLES}/qt/FuncDemo" RENAME "env.${SCRIPT_EXT}")
|
install (FILES "${CMAKE_BINARY_DIR}/env.samples.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR_SAMPLES}/qt/FuncDemo" RENAME "env.${SCRIPT_EXT}")
|
||||||
install (FILES "${CMAKE_BINARY_DIR}/env.samples.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_SAMPLES}/qt/IESample" RENAME "env.${SCRIPT_EXT}")
|
install (FILES "${CMAKE_BINARY_DIR}/env.samples.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR_SAMPLES}/qt/IESample" RENAME "env.${SCRIPT_EXT}")
|
||||||
install (FILES "${CMAKE_BINARY_DIR}/env.samples.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_SAMPLES}/qt/Tutorial" RENAME "env.${SCRIPT_EXT}")
|
install (FILES "${CMAKE_BINARY_DIR}/env.samples.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR_SAMPLES}/qt/Tutorial" RENAME "env.${SCRIPT_EXT}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/tcl" "${INSTALL_DIR}/${INSTALL_DIR_SAMPLES}")
|
|
||||||
|
|
||||||
if (INSTALL_TEST_CASES)
|
if (INSTALL_TEST_CASES)
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("tests/" "${INSTALL_DIR}/${INSTALL_DIR_TESTS}")
|
OCCT_INSTALL_FILE_OR_DIR ("tests/" "${INSTALL_DIR_TESTS}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# copy draw script to install script folder
|
list (FIND BUILD_TOOLKITS DRAWEXE DRAWEXE_INDEX)
|
||||||
if (BUILD_PATCH AND EXISTS "${BUILD_PATCH}/adm/templates/draw.${SCRIPT_EXT}")
|
if (${DRAWEXE_INDEX} GREATER -1)
|
||||||
install (FILES "${BUILD_PATCH}/adm/templates/draw.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_SCRIPT}"
|
# copy data and samples/tcl folders to install script folder
|
||||||
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_WRITE GROUP_EXECUTE WORLD_READ WORLD_WRITE WORLD_EXECUTE)
|
OCCT_INSTALL_FILE_OR_DIR ("data/" "${INSTALL_DIR_DATA}")
|
||||||
else()
|
OCCT_INSTALL_FILE_OR_DIR ("samples/tcl" "${INSTALL_DIR_SAMPLES}")
|
||||||
install (FILES "${CMAKE_SOURCE_DIR}/adm/templates/draw.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_SCRIPT}"
|
|
||||||
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_WRITE GROUP_EXECUTE WORLD_READ WORLD_WRITE WORLD_EXECUTE)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# copy draw script to CMake binary folder
|
# copy draw script to install script folder
|
||||||
OCCT_COPY_FILE_OR_DIR ("adm/templates/draw.${SCRIPT_EXT}" "${CMAKE_BINARY_DIR}")
|
if (BUILD_PATCH AND EXISTS "${BUILD_PATCH}/adm/templates/draw.${SCRIPT_EXT}")
|
||||||
|
install (FILES "${BUILD_PATCH}/adm/templates/draw.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR_SCRIPT}"
|
||||||
|
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_WRITE GROUP_EXECUTE WORLD_READ WORLD_WRITE WORLD_EXECUTE)
|
||||||
|
else()
|
||||||
|
install (FILES "${CMAKE_SOURCE_DIR}/adm/templates/draw.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR_SCRIPT}"
|
||||||
|
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_WRITE GROUP_EXECUTE WORLD_READ WORLD_WRITE WORLD_EXECUTE)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
# copy draw script to CMake binary folder
|
||||||
|
OCCT_COPY_FILE_OR_DIR ("adm/templates/draw.${SCRIPT_EXT}" "${CMAKE_BINARY_DIR}")
|
||||||
|
endif()
|
||||||
|
|
||||||
set (SUB_CUSTOM_NAME "custom_${COMPILER}_${COMPILER_BITNESS}.${SCRIPT_EXT}")
|
set (SUB_CUSTOM_NAME "custom_${COMPILER}_${COMPILER_BITNESS}.${SCRIPT_EXT}")
|
||||||
|
|
||||||
@@ -675,18 +797,18 @@ if (EXISTS "${INSTALL_DIR}/${INSTALL_DIR_SCRIPT}/custom.${SCRIPT_EXT}")
|
|||||||
|
|
||||||
file (WRITE "${INSTALL_DIR}/${INSTALL_DIR_SCRIPT}/custom.${SCRIPT_EXT}" "${CUSTOM_CONTENT}")
|
file (WRITE "${INSTALL_DIR}/${INSTALL_DIR_SCRIPT}/custom.${SCRIPT_EXT}" "${CUSTOM_CONTENT}")
|
||||||
else()
|
else()
|
||||||
OCCT_CONFIGURE_AND_INSTALL ("adm/templates/custom.${SCRIPT_EXT}.main" "custom.${SCRIPT_EXT}" "custom.${SCRIPT_EXT}" "${INSTALL_DIR}/${INSTALL_DIR_SCRIPT}")
|
OCCT_CONFIGURE_AND_INSTALL ("adm/templates/custom.${SCRIPT_EXT}.main" "custom.${SCRIPT_EXT}" "custom.${SCRIPT_EXT}" "${INSTALL_DIR_SCRIPT}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# write current custom.bat/sh (for install directory)
|
# write current custom.bat/sh (for install directory)
|
||||||
set (SUB_CUSTOM_BUILD_NAME "custom_${COMPILER}_${COMPILER_BITNESS}.install.${SCRIPT_EXT}")
|
set (SUB_CUSTOM_BUILD_NAME "custom_${COMPILER}_${COMPILER_BITNESS}.install.${SCRIPT_EXT}")
|
||||||
OCCT_CONFIGURE_AND_INSTALL ("adm/templates/custom.install.${SCRIPT_EXT}.in" "${SUB_CUSTOM_BUILD_NAME}" "${SUB_CUSTOM_NAME}" "${INSTALL_DIR}/${INSTALL_DIR_SCRIPT}")
|
OCCT_CONFIGURE_AND_INSTALL ("adm/templates/custom.install.${SCRIPT_EXT}.in" "${SUB_CUSTOM_BUILD_NAME}" "${SUB_CUSTOM_NAME}" "${INSTALL_DIR_SCRIPT}")
|
||||||
|
|
||||||
# write current custom.bat/sh (for build directory)
|
# write current custom.bat/sh (for build directory)
|
||||||
OCCT_CONFIGURE ("adm/templates/custom.build.${SCRIPT_EXT}.in" "${SUB_CUSTOM_NAME}")
|
OCCT_CONFIGURE ("adm/templates/custom.build.${SCRIPT_EXT}.in" "${SUB_CUSTOM_NAME}")
|
||||||
|
|
||||||
if (BUILD_MODULE_MfcSamples)
|
if (BUILD_MODULE_MfcSamples)
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("adm/templates/sample.bat" "${INSTALL_DIR}/${INSTALL_DIR_SCRIPT}")
|
OCCT_INSTALL_FILE_OR_DIR ("adm/templates/sample.bat" "${INSTALL_DIR_SCRIPT}")
|
||||||
OCCT_COPY_FILE_OR_DIR ("adm/templates/sample.bat" "${CMAKE_BINARY_DIR}")
|
OCCT_COPY_FILE_OR_DIR ("adm/templates/sample.bat" "${CMAKE_BINARY_DIR}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -694,7 +816,7 @@ endif()
|
|||||||
OCCT_CONFIGURE ("adm/templates/env.${SCRIPT_EXT}.in" "env.${SCRIPT_EXT}")
|
OCCT_CONFIGURE ("adm/templates/env.${SCRIPT_EXT}.in" "env.${SCRIPT_EXT}")
|
||||||
|
|
||||||
# install env script
|
# install env script
|
||||||
install (FILES "${CMAKE_BINARY_DIR}/env.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_SCRIPT}")
|
install (FILES "${CMAKE_BINARY_DIR}/env.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR_SCRIPT}")
|
||||||
|
|
||||||
# copy DrawAppliInit from OCCT source to build directory
|
# copy DrawAppliInit from OCCT source to build directory
|
||||||
if (NOT EXISTS "${CMAKE_BINARY_DIR}/DrawAppliInit")
|
if (NOT EXISTS "${CMAKE_BINARY_DIR}/DrawAppliInit")
|
||||||
@@ -707,12 +829,17 @@ foreach(RESOURCE ${RESOURCES})
|
|||||||
get_filename_component(RESOURCE_FOLDER ${RESOURCE} DIRECTORY)
|
get_filename_component(RESOURCE_FOLDER ${RESOURCE} DIRECTORY)
|
||||||
if(NOT "${RESOURCE_FOLDER}" STREQUAL "")
|
if(NOT "${RESOURCE_FOLDER}" STREQUAL "")
|
||||||
get_filename_component(RESOURCE_FOLDER ${RESOURCE_FOLDER} NAME)
|
get_filename_component(RESOURCE_FOLDER ${RESOURCE_FOLDER} NAME)
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("src/${RESOURCE}" "${INSTALL_DIR}/${INSTALL_DIR_RESOURCE}/${RESOURCE_FOLDER}")
|
OCCT_INSTALL_FILE_OR_DIR ("src/${RESOURCE}" "${INSTALL_DIR_RESOURCE}/${RESOURCE_FOLDER}")
|
||||||
else()
|
else()
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("src/${RESOURCE}" "${INSTALL_DIR}/${INSTALL_DIR_RESOURCE}")
|
OCCT_INSTALL_FILE_OR_DIR ("src/${RESOURCE}" "${INSTALL_DIR_RESOURCE}")
|
||||||
endif()
|
endif()
|
||||||
endforeach()
|
endforeach()
|
||||||
|
|
||||||
|
# patch installed DrawDefault file if BUILD_SHARED_LIBRARY_NAME_POSTFIX is changed
|
||||||
|
if (NOT "${BUILD_SHARED_LIBRARY_NAME_POSTFIX}" STREQUAL "")
|
||||||
|
OCCT_UPDATE_DRAW_DEFAULT_FILE()
|
||||||
|
endif()
|
||||||
|
|
||||||
# define CSF variable
|
# define CSF variable
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/occt_csf")
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/occt_csf")
|
||||||
|
|
||||||
@@ -766,10 +893,16 @@ if (BUILD_MODULE_MfcSamples)
|
|||||||
add_subdirectory(samples/mfc/standard/10_Convert)
|
add_subdirectory(samples/mfc/standard/10_Convert)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if (BUILD_MODULE_UwpSample)
|
||||||
|
add_subdirectory(samples/xaml)
|
||||||
|
endif()
|
||||||
|
|
||||||
# Prepare variables for configuration of OpenCASCADE cmake config file
|
# Prepare variables for configuration of OpenCASCADE cmake config file
|
||||||
set (OCCT_MODULES_ENABLED)
|
set (OCCT_MODULES_ENABLED)
|
||||||
set (OCCT_LIBRARIES)
|
set (OCCT_LIBRARIES)
|
||||||
set (SET_OpenCASCADE_MODULES_TOOLKITS "\n# List of available OpenCASCADE libraries for each module\n")
|
set (SET_OpenCASCADE_MODULES_TOOLKITS "\n# List of available OpenCASCADE libraries for each module\n")
|
||||||
|
set (OCCT_COMPILE_DEFINITIONS)
|
||||||
|
|
||||||
foreach (OCCT_TOOLKIT ${BUILD_TOOLKITS})
|
foreach (OCCT_TOOLKIT ${BUILD_TOOLKITS})
|
||||||
if (TARGET ${OCCT_TOOLKIT})
|
if (TARGET ${OCCT_TOOLKIT})
|
||||||
|
|
||||||
@@ -782,16 +915,46 @@ foreach (OCCT_TOOLKIT ${BUILD_TOOLKITS})
|
|||||||
get_target_property (${OCCT_TOOLKIT}_MODULE ${OCCT_TOOLKIT} "MODULE")
|
get_target_property (${OCCT_TOOLKIT}_MODULE ${OCCT_TOOLKIT} "MODULE")
|
||||||
list (APPEND OCCT_MODULES_ENABLED ${${OCCT_TOOLKIT}_MODULE})
|
list (APPEND OCCT_MODULES_ENABLED ${${OCCT_TOOLKIT}_MODULE})
|
||||||
list (APPEND OpenCASCADE_${${OCCT_TOOLKIT}_MODULE}_TOOLKITS ${OCCT_TOOLKIT})
|
list (APPEND OpenCASCADE_${${OCCT_TOOLKIT}_MODULE}_TOOLKITS ${OCCT_TOOLKIT})
|
||||||
|
|
||||||
|
# get compile definitions of target directory
|
||||||
|
get_directory_property (COMPILE_DEFINITIONS DIRECTORY "${${OCCT_TOOLKIT}_SOURCE_DIR}" "COMPILE_DEFINITIONS")
|
||||||
|
list (APPEND OCCT_COMPILE_DEFINITIONS ${COMPILE_DEFINITIONS})
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endforeach()
|
endforeach()
|
||||||
list (REMOVE_DUPLICATES OCCT_MODULES_ENABLED)
|
list (REMOVE_DUPLICATES OCCT_MODULES_ENABLED)
|
||||||
|
list (REMOVE_DUPLICATES OCCT_COMPILE_DEFINITIONS)
|
||||||
|
|
||||||
|
# export compile definitions and C/C++ flags for each configuration to OpenCASCADE config files
|
||||||
|
foreach (OCCT_CONFIGURATION ${CMAKE_CONFIGURATION_TYPES})
|
||||||
|
set (SET_OpenCASCADE_COMPILE_DEFINITIONS)
|
||||||
|
string (TOUPPER "${OCCT_CONFIGURATION}" OCCT_CONFIGURATION_UPPER)
|
||||||
|
string (TOLOWER "${OCCT_CONFIGURATION}" OCCT_CONFIGURATION_LOWER)
|
||||||
|
foreach(COMPILE_DEFINITION ${OCCT_COMPILE_DEFINITIONS})
|
||||||
|
string(REPLACE "(" "\\(" COMPILE_DEFINITION "${COMPILE_DEFINITION}")
|
||||||
|
string(REPLACE ")" "\\)" COMPILE_DEFINITION "${COMPILE_DEFINITION}")
|
||||||
|
set (SET_OpenCASCADE_COMPILE_DEFINITIONS "${SET_OpenCASCADE_COMPILE_DEFINITIONS}set_property(DIRECTORY APPEND PROPERTY COMPILE_DEFINITIONS $<$<CONFIG:${OCCT_CONFIGURATION}>:${COMPILE_DEFINITION}>)\n")
|
||||||
|
endforeach()
|
||||||
|
set (SET_OpenCASCADE_CMAKE_C_FLAGS "${CMAKE_C_FLAGS_${OCCT_CONFIGURATION_UPPER}}")
|
||||||
|
set (SET_OpenCASCADE_CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS_${OCCT_CONFIGURATION_UPPER}}")
|
||||||
|
configure_file("${CMAKE_SOURCE_DIR}/adm/templates/OpenCASCADECompileDefinitionsAndFlags.cmake.in" "OpenCASCADECompileDefinitionsAndFlags-${OCCT_CONFIGURATION_LOWER}.cmake" @ONLY)
|
||||||
|
endforeach()
|
||||||
|
# install OpenCASCADE config file with compile definitions and C/C++ flags ONLY for current configuration
|
||||||
|
install (CODE "string (TOLOWER \"\${CMAKE_INSTALL_CONFIG_NAME}\" CMAKE_INSTALL_CONFIG_NAME_LOWER)")
|
||||||
|
install (CODE "configure_file(\"${CMAKE_BINARY_DIR}/OpenCASCADECompileDefinitionsAndFlags-\${CMAKE_INSTALL_CONFIG_NAME_LOWER}.cmake\" \"${INSTALL_DIR}/${INSTALL_DIR_CMAKE}/OpenCASCADECompileDefinitionsAndFlags-\${CMAKE_INSTALL_CONFIG_NAME_LOWER}.cmake\" COPYONLY)")
|
||||||
|
|
||||||
foreach (OCCT_MODULE ${OCCT_MODULES})
|
foreach (OCCT_MODULE ${OCCT_MODULES})
|
||||||
if (BUILD_MODULE_${OCCT_MODULE})
|
if (BUILD_MODULE_${OCCT_MODULE})
|
||||||
set (SET_OpenCASCADE_MODULES_TOOLKITS "${SET_OpenCASCADE_MODULES_TOOLKITS}set (OpenCASCADE_${OCCT_MODULE}_LIBRARIES ${OpenCASCADE_${OCCT_MODULE}_TOOLKITS})\n")
|
set (SET_OpenCASCADE_MODULES_TOOLKITS "${SET_OpenCASCADE_MODULES_TOOLKITS}set (OpenCASCADE_${OCCT_MODULE}_LIBRARIES ${OpenCASCADE_${OCCT_MODULE}_TOOLKITS})\n")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
# sort enabled modules for correct work of OpenCASCADE config file
|
||||||
|
list(FIND OCCT_MODULES_ENABLED "${OCCT_MODULE}" OCCT_MODULE_INDEX)
|
||||||
|
if (NOT ${OCCT_MODULE_INDEX} EQUAL -1)
|
||||||
|
list (APPEND OCCT_MODULES_ENABLED_SORTED ${OCCT_MODULE})
|
||||||
|
endif()
|
||||||
endforeach()
|
endforeach()
|
||||||
|
set (OCCT_MODULES_ENABLED ${OCCT_MODULES_ENABLED_SORTED})
|
||||||
|
|
||||||
# Add all targets to the build-tree export set
|
# Add all targets to the build-tree export set
|
||||||
export (TARGETS ${OCCT_LIBRARIES} FILE "${CMAKE_BINARY_DIR}/OpenCASCADETargets.cmake")
|
export (TARGETS ${OCCT_LIBRARIES} FILE "${CMAKE_BINARY_DIR}/OpenCASCADETargets.cmake")
|
||||||
@@ -823,7 +986,7 @@ endif()
|
|||||||
|
|
||||||
# Configure and install cmake config file
|
# Configure and install cmake config file
|
||||||
configure_file("${CMAKE_SOURCE_DIR}/adm/templates/OpenCASCADEConfig.cmake.in" "OpenCASCADEConfig.cmake" @ONLY)
|
configure_file("${CMAKE_SOURCE_DIR}/adm/templates/OpenCASCADEConfig.cmake.in" "OpenCASCADEConfig.cmake" @ONLY)
|
||||||
install(FILES "${CMAKE_BINARY_DIR}/OpenCASCADEConfig.cmake" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_CMAKE}")
|
install(FILES "${CMAKE_BINARY_DIR}/OpenCASCADEConfig.cmake" DESTINATION "${INSTALL_DIR_CMAKE}")
|
||||||
|
|
||||||
# Configure cmake version file
|
# Configure cmake version file
|
||||||
include(CMakePackageConfigHelpers)
|
include(CMakePackageConfigHelpers)
|
||||||
@@ -832,13 +995,11 @@ write_basic_package_version_file( ${CMAKE_BINARY_DIR}/OpenCASCADEConfigVersion.c
|
|||||||
COMPATIBILITY ExactVersion )
|
COMPATIBILITY ExactVersion )
|
||||||
|
|
||||||
# Install cmake version file
|
# Install cmake version file
|
||||||
install (FILES "${CMAKE_BINARY_DIR}/OpenCASCADEConfigVersion.cmake" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_CMAKE}")
|
install (FILES "${CMAKE_BINARY_DIR}/OpenCASCADEConfigVersion.cmake" DESTINATION "${INSTALL_DIR_CMAKE}")
|
||||||
|
|
||||||
# Install the export set for use with the install-tree for each configuration
|
# Install the export set for use with the install-tree for each configuration
|
||||||
foreach (OCCT_MODULE ${OCCT_MODULES})
|
foreach (OCCT_MODULE ${OCCT_MODULES_ENABLED})
|
||||||
if (BUILD_MODULE_${OCCT_MODULE})
|
install(EXPORT OpenCASCADE${OCCT_MODULE}Targets DESTINATION "${INSTALL_DIR_CMAKE}")
|
||||||
install(EXPORT OpenCASCADE${OCCT_MODULE}Targets DESTINATION "${INSTALL_DIR_CMAKE}")
|
|
||||||
endif()
|
|
||||||
endforeach()
|
endforeach()
|
||||||
|
|
||||||
# Update generated OpenCASCADETargets-*.cmake files
|
# Update generated OpenCASCADETargets-*.cmake files
|
||||||
|
@@ -2,6 +2,6 @@ FoundationClasses TKernel TKMath
|
|||||||
ModelingData TKG2d TKG3d TKGeomBase TKBRep
|
ModelingData TKG2d TKG3d TKGeomBase TKBRep
|
||||||
ModelingAlgorithms TKGeomAlgo TKTopAlgo TKPrim TKBO TKBool TKHLR TKFillet TKOffset TKFeat TKMesh TKXMesh TKShHealing
|
ModelingAlgorithms TKGeomAlgo TKTopAlgo TKPrim TKBO TKBool TKHLR TKFillet TKOffset TKFeat TKMesh TKXMesh TKShHealing
|
||||||
Visualization TKService TKV3d TKOpenGl TKMeshVS TKIVtk TKD3DHost
|
Visualization TKService TKV3d TKOpenGl TKMeshVS TKIVtk TKD3DHost
|
||||||
ApplicationFramework TKCDF TKLCAF TKCAF TKBinL TKXmlL TKBin TKXml TKStdL TKStd FWOSPlugin TKTObj TKBinTObj TKXmlTObj TKVCAF
|
ApplicationFramework TKCDF TKLCAF TKCAF TKBinL TKXmlL TKBin TKXml TKStdL TKStd TKTObj TKBinTObj TKXmlTObj TKVCAF
|
||||||
DataExchange TKXSBase TKSTEPBase TKSTEPAttr TKSTEP209 TKSTEP TKIGES TKXCAF TKXDEIGES TKXDESTEP TKSTL TKVRML TKXmlXCAF TKBinXCAF
|
DataExchange TKXSBase TKSTEPBase TKSTEPAttr TKSTEP209 TKSTEP TKIGES TKXCAF TKXDEIGES TKXDESTEP TKSTL TKVRML TKXmlXCAF TKBinXCAF
|
||||||
Draw TKDraw TKTopTest TKViewerTest TKXSDRAW TKDCAF TKXDEDRAW TKTObjDRAW TKQADraw TKIVtkDraw DRAWEXE
|
Draw TKDraw TKTopTest TKViewerTest TKXSDRAW TKDCAF TKXDEDRAW TKTObjDRAW TKQADraw TKIVtkDraw DRAWEXE
|
||||||
|
@@ -6,6 +6,5 @@ Shaders
|
|||||||
XSMessage
|
XSMessage
|
||||||
XSTEPResource
|
XSTEPResource
|
||||||
XmlOcafResource
|
XmlOcafResource
|
||||||
UnitsAPI/Lexi_Expr.dat
|
|
||||||
UnitsAPI/Units.dat
|
UnitsAPI/Units.dat
|
||||||
TObj/TObj.msg
|
TObj/TObj.msg
|
@@ -5,7 +5,6 @@ n Bnd
|
|||||||
n BVH
|
n BVH
|
||||||
n CSLib
|
n CSLib
|
||||||
n Convert
|
n Convert
|
||||||
n Dico
|
|
||||||
n ElCLib
|
n ElCLib
|
||||||
n ElSLib
|
n ElSLib
|
||||||
n Expr
|
n Expr
|
||||||
@@ -241,7 +240,6 @@ n BinObjMgt
|
|||||||
n BinTools
|
n BinTools
|
||||||
n CDF
|
n CDF
|
||||||
n CDM
|
n CDM
|
||||||
n FWOSDriver
|
|
||||||
n PCDM
|
n PCDM
|
||||||
n StdLDrivers
|
n StdLDrivers
|
||||||
n StdLPersistent
|
n StdLPersistent
|
||||||
@@ -269,7 +267,6 @@ n XmlMNaming
|
|||||||
n XmlObjMgt
|
n XmlObjMgt
|
||||||
r StdResource
|
r StdResource
|
||||||
r XmlOcafResource
|
r XmlOcafResource
|
||||||
t FWOSPlugin
|
|
||||||
|
|
||||||
t TKBin
|
t TKBin
|
||||||
t TKBinL
|
t TKBinL
|
||||||
@@ -440,3 +437,4 @@ n IVtkDraw
|
|||||||
t TKIVtkDraw
|
t TKIVtkDraw
|
||||||
n Geom2dEvaluator
|
n Geom2dEvaluator
|
||||||
t TKVCAF
|
t TKVCAF
|
||||||
|
n XCAFView
|
@@ -8,7 +8,7 @@ set(3RDPARTY_MACRO_ALREADY_INCLUDED 1)
|
|||||||
|
|
||||||
macro (THIRDPARTY_PRODUCT PRODUCT_NAME HEADER_NAME LIBRARY_NAME LIBRARY_NAME_DEBUG)
|
macro (THIRDPARTY_PRODUCT PRODUCT_NAME HEADER_NAME LIBRARY_NAME LIBRARY_NAME_DEBUG)
|
||||||
|
|
||||||
if (NOT DEFINED INSTALL_${PRODUCT_NAME})
|
if (NOT DEFINED INSTALL_${PRODUCT_NAME} AND BUILD_SHARED_LIBS)
|
||||||
set (INSTALL_${PRODUCT_NAME} OFF CACHE BOOL "${INSTALL_${PRODUCT_NAME}_DESCR}")
|
set (INSTALL_${PRODUCT_NAME} OFF CACHE BOOL "${INSTALL_${PRODUCT_NAME}_DESCR}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -37,47 +37,50 @@ macro (THIRDPARTY_PRODUCT PRODUCT_NAME HEADER_NAME LIBRARY_NAME LIBRARY_NAME_DEB
|
|||||||
set (3RDPARTY_${PRODUCT_NAME}_INCLUDE_DIR "" CACHE PATH "the path of ${HEADER_NAME}")
|
set (3RDPARTY_${PRODUCT_NAME}_INCLUDE_DIR "" CACHE PATH "the path of ${HEADER_NAME}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (NOT DEFINED 3RDPARTY_${PRODUCT_NAME}_LIBRARY OR NOT 3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR OR NOT EXISTS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR}")
|
if (BUILD_SHARED_LIBS)
|
||||||
set (3RDPARTY_${PRODUCT_NAME}_LIBRARY "" CACHE FILEPATH "${PRODUCT_NAME} library" FORCE)
|
if (NOT DEFINED 3RDPARTY_${PRODUCT_NAME}_LIBRARY OR NOT 3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR OR NOT EXISTS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR}")
|
||||||
endif()
|
set (3RDPARTY_${PRODUCT_NAME}_LIBRARY "" CACHE FILEPATH "${PRODUCT_NAME} library" FORCE)
|
||||||
|
|
||||||
if (NOT DEFINED 3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR)
|
|
||||||
set (3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR "" CACHE PATH "The directory containing ${PRODUCT_NAME} library")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (WIN32)
|
|
||||||
if (NOT DEFINED 3RDPARTY_${PRODUCT_NAME}_DLL OR NOT 3RDPARTY_${PRODUCT_NAME}_DLL_DIR OR NOT EXISTS "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR}")
|
|
||||||
set (3RDPARTY_${PRODUCT_NAME}_DLL "" CACHE FILEPATH "${PRODUCT_NAME} shared library" FORCE)
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
if (WIN32)
|
if (NOT DEFINED 3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR)
|
||||||
if (NOT DEFINED 3RDPARTY_${PRODUCT_NAME}_DLL_DIR)
|
set (3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR "" CACHE PATH "The directory containing ${PRODUCT_NAME} library")
|
||||||
set (3RDPARTY_${PRODUCT_NAME}_DLL_DIR "" CACHE PATH "The directory containing ${PRODUCT_NAME} shared library")
|
endif()
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
if (NOT DEFINED 3RDPARTY_${PRODUCT_NAME}_DLL OR NOT 3RDPARTY_${PRODUCT_NAME}_DLL_DIR OR NOT EXISTS "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR}")
|
||||||
|
set (3RDPARTY_${PRODUCT_NAME}_DLL "" CACHE FILEPATH "${PRODUCT_NAME} shared library" FORCE)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
if (NOT DEFINED 3RDPARTY_${PRODUCT_NAME}_DLL_DIR)
|
||||||
|
set (3RDPARTY_${PRODUCT_NAME}_DLL_DIR "" CACHE PATH "The directory containing ${PRODUCT_NAME} shared library")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# check 3RDPARTY_${PRODUCT_NAME}_ paths for consistency with specified 3RDPARTY_${PRODUCT_NAME}_DIR
|
# check 3RDPARTY_${PRODUCT_NAME}_ paths for consistency with specified 3RDPARTY_${PRODUCT_NAME}_DIR
|
||||||
if (3RDPARTY_${PRODUCT_NAME}_DIR AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_DIR}")
|
if (3RDPARTY_${PRODUCT_NAME}_DIR AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_DIR}")
|
||||||
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_${PRODUCT_NAME}_DIR 3RDPARTY_${PRODUCT_NAME}_INCLUDE_DIR PATH "the path to ${PRODUCT_NAME}")
|
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_${PRODUCT_NAME}_DIR 3RDPARTY_${PRODUCT_NAME}_INCLUDE_DIR PATH "the path to ${PRODUCT_NAME}")
|
||||||
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_${PRODUCT_NAME}_DIR 3RDPARTY_${PRODUCT_NAME}_LIBRARY FILEPATH "the path to ${PRODUCT_NAME} library")
|
if (BUILD_SHARED_LIBS)
|
||||||
|
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_${PRODUCT_NAME}_DIR 3RDPARTY_${PRODUCT_NAME}_LIBRARY FILEPATH "the path to ${PRODUCT_NAME} library")
|
||||||
|
|
||||||
if (3RDPARTY_${PRODUCT_NAME}_LIBRARY AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY}")
|
if (3RDPARTY_${PRODUCT_NAME}_LIBRARY AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY}")
|
||||||
get_filename_component (3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR "${3RDPARTY_${PRODUCT_NAME}_LIBRARY}" PATH)
|
get_filename_component (3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR "${3RDPARTY_${PRODUCT_NAME}_LIBRARY}" PATH)
|
||||||
set (3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR "${3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR}" CACHE PATH "The directory containing ${PRODUCT_NAME} library" FORCE)
|
set (3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR "${3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR}" CACHE PATH "The directory containing ${PRODUCT_NAME} library" FORCE)
|
||||||
else()
|
|
||||||
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_${PRODUCT_NAME}_DIR 3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR PATH "The directory containing ${PRODUCT_NAME} library")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (WIN32)
|
|
||||||
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_${PRODUCT_NAME}_DIR 3RDPARTY_${PRODUCT_NAME}_DLL FILEPATH "the path to ${PRODUCT_NAME} shared library")
|
|
||||||
|
|
||||||
if (3RDPARTY_${PRODUCT_NAME}_DLL AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_DLL}")
|
|
||||||
get_filename_component (3RDPARTY_${PRODUCT_NAME}_DLL_DIR "${3RDPARTY_${PRODUCT_NAME}_DLL}" PATH)
|
|
||||||
set (3RDPARTY_${PRODUCT_NAME}_DLL_DIR "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR}" CACHE PATH "The directory containing ${PRODUCT_NAME} shared library" FORCE)
|
|
||||||
else()
|
else()
|
||||||
|
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_${PRODUCT_NAME}_DIR 3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR PATH "The directory containing ${PRODUCT_NAME} library")
|
||||||
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_${PRODUCT_NAME}_DIR 3RDPARTY_${PRODUCT_NAME}_DLL_DIR PATH "The directory containing ${PRODUCT_NAME} shared library")
|
endif()
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_${PRODUCT_NAME}_DIR 3RDPARTY_${PRODUCT_NAME}_DLL FILEPATH "the path to ${PRODUCT_NAME} shared library")
|
||||||
|
|
||||||
|
if (3RDPARTY_${PRODUCT_NAME}_DLL AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_DLL}")
|
||||||
|
get_filename_component (3RDPARTY_${PRODUCT_NAME}_DLL_DIR "${3RDPARTY_${PRODUCT_NAME}_DLL}" PATH)
|
||||||
|
set (3RDPARTY_${PRODUCT_NAME}_DLL_DIR "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR}" CACHE PATH "The directory containing ${PRODUCT_NAME} shared library" FORCE)
|
||||||
|
else()
|
||||||
|
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_${PRODUCT_NAME}_DIR 3RDPARTY_${PRODUCT_NAME}_DLL_DIR PATH "The directory containing ${PRODUCT_NAME} shared library")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
@@ -109,156 +112,158 @@ macro (THIRDPARTY_PRODUCT PRODUCT_NAME HEADER_NAME LIBRARY_NAME LIBRARY_NAME_DEB
|
|||||||
set (3RDPARTY_${PRODUCT_NAME}_INCLUDE_DIR "" CACHE FILEPATH "The path to ${HEADER_NAME}" FORCE)
|
set (3RDPARTY_${PRODUCT_NAME}_INCLUDE_DIR "" CACHE FILEPATH "The path to ${HEADER_NAME}" FORCE)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# library
|
if (BUILD_SHARED_LIBS)
|
||||||
if (NOT 3RDPARTY_${PRODUCT_NAME}_LIBRARY OR NOT EXISTS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY}")
|
# library
|
||||||
set (CMAKE_FIND_LIBRARY_SUFFIXES .lib .so .dylib)
|
if (NOT 3RDPARTY_${PRODUCT_NAME}_LIBRARY OR NOT EXISTS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY}")
|
||||||
|
set (CMAKE_FIND_LIBRARY_SUFFIXES .lib .so .dylib .a)
|
||||||
|
|
||||||
set (${PRODUCT_NAME}_PATH_SUFFIXES lib)
|
set (${PRODUCT_NAME}_PATH_SUFFIXES lib)
|
||||||
if (ANDROID)
|
if (ANDROID)
|
||||||
set (${PRODUCT_NAME}_PATH_SUFFIXES ${${PRODUCT_NAME}_PATH_SUFFIXES} libs/${ANDROID_ABI})
|
set (${PRODUCT_NAME}_PATH_SUFFIXES ${${PRODUCT_NAME}_PATH_SUFFIXES} libs/${ANDROID_ABI})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# set 3RDPARTY_${PRODUCT_NAME}_LIBRARY as notfound, otherwise find_library can't assign a new value to 3RDPARTY_${PRODUCT_NAME}_LIBRARY
|
# set 3RDPARTY_${PRODUCT_NAME}_LIBRARY as notfound, otherwise find_library can't assign a new value to 3RDPARTY_${PRODUCT_NAME}_LIBRARY
|
||||||
set (3RDPARTY_${PRODUCT_NAME}_LIBRARY "3RDPARTY_${PRODUCT_NAME}_LIBRARY-NOTFOUND" CACHE FILEPATH "The path to ${PRODUCT_NAME} library" FORCE)
|
set (3RDPARTY_${PRODUCT_NAME}_LIBRARY "3RDPARTY_${PRODUCT_NAME}_LIBRARY-NOTFOUND" CACHE FILEPATH "The path to ${PRODUCT_NAME} library" FORCE)
|
||||||
|
|
||||||
if (3RDPARTY_${PRODUCT_NAME}_DIR AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_DIR}")
|
|
||||||
find_library (3RDPARTY_${PRODUCT_NAME}_LIBRARY NAMES ${LIBRARY_NAME}
|
|
||||||
PATHS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR}" "${3RDPARTY_${PRODUCT_NAME}_DIR}"
|
|
||||||
PATH_SUFFIXES ${${PRODUCT_NAME}_PATH_SUFFIXES}
|
|
||||||
CMAKE_FIND_ROOT_PATH_BOTH
|
|
||||||
NO_DEFAULT_PATH)
|
|
||||||
else()
|
|
||||||
find_library (3RDPARTY_${PRODUCT_NAME}_LIBRARY NAMES ${LIBRARY_NAME}
|
|
||||||
PATH_SUFFIXES ${${PRODUCT_NAME}_PATH_SUFFIXES}
|
|
||||||
CMAKE_FIND_ROOT_PATH_BOTH)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (3RDPARTY_${PRODUCT_NAME}_LIBRARY AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY}")
|
|
||||||
get_filename_component (3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR "${3RDPARTY_${PRODUCT_NAME}_LIBRARY}" PATH)
|
|
||||||
set (3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR "${3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR}" CACHE PATH "The directory containing ${PRODUCT_NAME} library" FORCE)
|
|
||||||
else()
|
|
||||||
set (3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR "" CACHE PATH "The directory containing ${PRODUCT_NAME} library" FORCE)
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR}")
|
|
||||||
list (APPEND 3RDPARTY_LIBRARY_DIRS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR}")
|
|
||||||
else()
|
|
||||||
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR)
|
|
||||||
|
|
||||||
set (3RDPARTY_${PRODUCT_NAME}_LIBRARY "" CACHE FILEPATH "The path to ${PRODUCT_NAME} library" FORCE)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# shared library
|
|
||||||
if (WIN32)
|
|
||||||
if (NOT 3RDPARTY_${PRODUCT_NAME}_DLL OR NOT EXISTS "${3RDPARTY_${PRODUCT_NAME}_DLL}")
|
|
||||||
|
|
||||||
set (CMAKE_FIND_LIBRARY_SUFFIXES .dll)
|
|
||||||
|
|
||||||
# set 3RDPARTY_${PRODUCT_NAME}_DLL as notfound, otherwise find_library can't assign a new value to 3RDPARTY_${PRODUCT_NAME}_DLL
|
|
||||||
set (3RDPARTY_${PRODUCT_NAME}_DLL "3RDPARTY_${PRODUCT_NAME}_DLL-NOTFOUND" CACHE FILEPATH "The path to ${PRODUCT_NAME} shared library" FORCE)
|
|
||||||
|
|
||||||
if (3RDPARTY_${PRODUCT_NAME}_DIR AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_DIR}")
|
if (3RDPARTY_${PRODUCT_NAME}_DIR AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_DIR}")
|
||||||
find_library (3RDPARTY_${PRODUCT_NAME}_DLL NAMES ${LIBRARY_NAME}
|
find_library (3RDPARTY_${PRODUCT_NAME}_LIBRARY NAMES ${LIBRARY_NAME}
|
||||||
PATHS "${3RDPARTY_${PRODUCT_NAME}_DIR}"
|
PATHS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR}" "${3RDPARTY_${PRODUCT_NAME}_DIR}"
|
||||||
PATH_SUFFIXES bin
|
PATH_SUFFIXES ${${PRODUCT_NAME}_PATH_SUFFIXES}
|
||||||
NO_DEFAULT_PATH)
|
CMAKE_FIND_ROOT_PATH_BOTH
|
||||||
|
NO_DEFAULT_PATH)
|
||||||
else()
|
else()
|
||||||
find_library (3RDPARTY_${PRODUCT_NAME}_DLL NAMES ${LIBRARY_NAME} PATH_SUFFIXES bin)
|
find_library (3RDPARTY_${PRODUCT_NAME}_LIBRARY NAMES ${LIBRARY_NAME}
|
||||||
|
PATH_SUFFIXES ${${PRODUCT_NAME}_PATH_SUFFIXES}
|
||||||
|
CMAKE_FIND_ROOT_PATH_BOTH)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (3RDPARTY_${PRODUCT_NAME}_DLL AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_DLL}")
|
if (3RDPARTY_${PRODUCT_NAME}_LIBRARY AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY}")
|
||||||
get_filename_component (3RDPARTY_${PRODUCT_NAME}_DLL_DIR "${3RDPARTY_${PRODUCT_NAME}_DLL}" PATH)
|
get_filename_component (3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR "${3RDPARTY_${PRODUCT_NAME}_LIBRARY}" PATH)
|
||||||
set (3RDPARTY_${PRODUCT_NAME}_DLL_DIR "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR}" CACHE PATH "The directory containing ${PRODUCT_NAME} library" FORCE)
|
set (3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR "${3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR}" CACHE PATH "The directory containing ${PRODUCT_NAME} library" FORCE)
|
||||||
else()
|
else()
|
||||||
set (3RDPARTY_${PRODUCT_NAME}_DLL_DIR "" CACHE PATH "The directory containing ${PRODUCT_NAME} shared library" FORCE)
|
set (3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR "" CACHE PATH "The directory containing ${PRODUCT_NAME} library" FORCE)
|
||||||
|
|
||||||
set (3RDPARTY_${PRODUCT_NAME}_DLL "" CACHE FILEPATH "${PRODUCT_NAME} shared library" FORCE)
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (3RDPARTY_${PRODUCT_NAME}_DLL_DIR OR EXISTS "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR}")
|
if (3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR}")
|
||||||
list (APPEND 3RDPARTY_DLL_DIRS "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR}")
|
list (APPEND 3RDPARTY_LIBRARY_DIRS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR}")
|
||||||
else()
|
else()
|
||||||
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_${PRODUCT_NAME}_DLL_DIR)
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR)
|
||||||
|
|
||||||
|
set (3RDPARTY_${PRODUCT_NAME}_LIBRARY "" CACHE FILEPATH "The path to ${PRODUCT_NAME} library" FORCE)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
set (USED_3RDPARTY_${PRODUCT_NAME}_DIR "")
|
|
||||||
|
|
||||||
if (INSTALL_${PRODUCT_NAME})
|
|
||||||
OCCT_MAKE_OS_WITH_BITNESS()
|
|
||||||
OCCT_MAKE_COMPILER_SHORT_NAME()
|
|
||||||
|
|
||||||
|
# shared library
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
if (SINGLE_GENERATOR)
|
if (NOT 3RDPARTY_${PRODUCT_NAME}_DLL OR NOT EXISTS "${3RDPARTY_${PRODUCT_NAME}_DLL}")
|
||||||
install (FILES "${3RDPARTY_${PRODUCT_NAME}_DLL}" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}")
|
|
||||||
else()
|
|
||||||
install (FILES "${3RDPARTY_${PRODUCT_NAME}_DLL}"
|
|
||||||
CONFIGURATIONS Release
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}")
|
|
||||||
install (FILES "${3RDPARTY_${PRODUCT_NAME}_DLL}"
|
|
||||||
CONFIGURATIONS RelWithDebInfo
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}i")
|
|
||||||
install (FILES "${3RDPARTY_${PRODUCT_NAME}_DLL}"
|
|
||||||
CONFIGURATIONS Debug
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}d")
|
|
||||||
endif()
|
|
||||||
else()
|
|
||||||
get_filename_component(ABS_PATH ${3RDPARTY_${PRODUCT_NAME}_LIBRARY} REALPATH)
|
|
||||||
|
|
||||||
if ("${PRODUCT_NAME}" STREQUAL "FREEIMAGE")
|
set (CMAKE_FIND_LIBRARY_SUFFIXES .dll)
|
||||||
get_filename_component(FREEIMLIB ${3RDPARTY_${PRODUCT_NAME}_LIBRARY} NAME)
|
|
||||||
|
|
||||||
if (SINGLE_GENERATOR)
|
# set 3RDPARTY_${PRODUCT_NAME}_DLL as notfound, otherwise find_library can't assign a new value to 3RDPARTY_${PRODUCT_NAME}_DLL
|
||||||
install (FILES "${ABS_PATH}" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}" RENAME ${FREEIMLIB}.3)
|
set (3RDPARTY_${PRODUCT_NAME}_DLL "3RDPARTY_${PRODUCT_NAME}_DLL-NOTFOUND" CACHE FILEPATH "The path to ${PRODUCT_NAME} shared library" FORCE)
|
||||||
|
|
||||||
|
if (3RDPARTY_${PRODUCT_NAME}_DIR AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_DIR}")
|
||||||
|
find_library (3RDPARTY_${PRODUCT_NAME}_DLL NAMES ${LIBRARY_NAME}
|
||||||
|
PATHS "${3RDPARTY_${PRODUCT_NAME}_DIR}"
|
||||||
|
PATH_SUFFIXES bin
|
||||||
|
NO_DEFAULT_PATH)
|
||||||
else()
|
else()
|
||||||
install (FILES "${ABS_PATH}"
|
find_library (3RDPARTY_${PRODUCT_NAME}_DLL NAMES ${LIBRARY_NAME} PATH_SUFFIXES bin)
|
||||||
CONFIGURATIONS Release
|
endif()
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}"
|
|
||||||
RENAME ${FREEIMLIB}.3)
|
if (3RDPARTY_${PRODUCT_NAME}_DLL AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_DLL}")
|
||||||
install (FILES "${ABS_PATH}"
|
get_filename_component (3RDPARTY_${PRODUCT_NAME}_DLL_DIR "${3RDPARTY_${PRODUCT_NAME}_DLL}" PATH)
|
||||||
CONFIGURATIONS RelWithDebInfo
|
set (3RDPARTY_${PRODUCT_NAME}_DLL_DIR "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR}" CACHE PATH "The directory containing ${PRODUCT_NAME} library" FORCE)
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}i"
|
else()
|
||||||
RENAME ${FREEIMLIB}.3)
|
set (3RDPARTY_${PRODUCT_NAME}_DLL_DIR "" CACHE PATH "The directory containing ${PRODUCT_NAME} shared library" FORCE)
|
||||||
install (FILES "${ABS_PATH}"
|
|
||||||
CONFIGURATIONS Debug
|
set (3RDPARTY_${PRODUCT_NAME}_DLL "" CACHE FILEPATH "${PRODUCT_NAME} shared library" FORCE)
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}d"
|
|
||||||
RENAME ${FREEIMLIB}.3)
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if("${PRODUCT_NAME}" STREQUAL "GL2PS")
|
if (3RDPARTY_${PRODUCT_NAME}_DLL_DIR OR EXISTS "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR}")
|
||||||
get_filename_component(GL2PSLIB ${3RDPARTY_${PRODUCT_NAME}_LIBRARY} NAME)
|
list (APPEND 3RDPARTY_DLL_DIRS "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR}")
|
||||||
|
else()
|
||||||
if (SINGLE_GENERATOR)
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_${PRODUCT_NAME}_DLL_DIR)
|
||||||
install (FILES "${ABS_PATH}" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}" RENAME ${GL2PSLIB}.1)
|
|
||||||
else()
|
|
||||||
install (FILES "${ABS_PATH}"
|
|
||||||
CONFIGURATIONS Release
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}"
|
|
||||||
RENAME ${GL2PSLIB}.1)
|
|
||||||
install (FILES "${ABS_PATH}"
|
|
||||||
CONFIGURATIONS RelWithDebInfo
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}i"
|
|
||||||
RENAME ${GL2PSLIB}.1)
|
|
||||||
install (FILES "${ABS_PATH}"
|
|
||||||
CONFIGURATIONS Debug
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}d"
|
|
||||||
RENAME ${GL2PSLIB}.1)
|
|
||||||
endif()
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
else()
|
|
||||||
# the library directory for using by the executable
|
|
||||||
if (WIN32)
|
|
||||||
set (USED_3RDPARTY_${PRODUCT_NAME}_DIR "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR}")
|
|
||||||
else()
|
|
||||||
set (USED_3RDPARTY_${PRODUCT_NAME}_DIR "${3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR}")
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
mark_as_advanced (3RDPARTY_${PRODUCT_NAME}_LIBRARY 3RDPARTY_${PRODUCT_NAME}_DLL)
|
set (USED_3RDPARTY_${PRODUCT_NAME}_DIR "")
|
||||||
|
|
||||||
|
if (INSTALL_${PRODUCT_NAME})
|
||||||
|
OCCT_MAKE_OS_WITH_BITNESS()
|
||||||
|
OCCT_MAKE_COMPILER_SHORT_NAME()
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
if (SINGLE_GENERATOR)
|
||||||
|
install (FILES "${3RDPARTY_${PRODUCT_NAME}_DLL}" DESTINATION "${INSTALL_DIR_BIN}")
|
||||||
|
else()
|
||||||
|
install (FILES "${3RDPARTY_${PRODUCT_NAME}_DLL}"
|
||||||
|
CONFIGURATIONS Release
|
||||||
|
DESTINATION "${INSTALL_DIR_BIN}")
|
||||||
|
install (FILES "${3RDPARTY_${PRODUCT_NAME}_DLL}"
|
||||||
|
CONFIGURATIONS RelWithDebInfo
|
||||||
|
DESTINATION "${INSTALL_DIR_BIN}i")
|
||||||
|
install (FILES "${3RDPARTY_${PRODUCT_NAME}_DLL}"
|
||||||
|
CONFIGURATIONS Debug
|
||||||
|
DESTINATION "${INSTALL_DIR_BIN}d")
|
||||||
|
endif()
|
||||||
|
else()
|
||||||
|
get_filename_component(ABS_PATH ${3RDPARTY_${PRODUCT_NAME}_LIBRARY} REALPATH)
|
||||||
|
|
||||||
|
if ("${PRODUCT_NAME}" STREQUAL "FREEIMAGE")
|
||||||
|
get_filename_component(FREEIMLIB ${3RDPARTY_${PRODUCT_NAME}_LIBRARY} NAME)
|
||||||
|
|
||||||
|
if (SINGLE_GENERATOR)
|
||||||
|
install (FILES "${ABS_PATH}" DESTINATION "${INSTALL_DIR_LIB}" RENAME ${FREEIMLIB}.3)
|
||||||
|
else()
|
||||||
|
install (FILES "${ABS_PATH}"
|
||||||
|
CONFIGURATIONS Release
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}"
|
||||||
|
RENAME ${FREEIMLIB}.3)
|
||||||
|
install (FILES "${ABS_PATH}"
|
||||||
|
CONFIGURATIONS RelWithDebInfo
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}i"
|
||||||
|
RENAME ${FREEIMLIB}.3)
|
||||||
|
install (FILES "${ABS_PATH}"
|
||||||
|
CONFIGURATIONS Debug
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}d"
|
||||||
|
RENAME ${FREEIMLIB}.3)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if("${PRODUCT_NAME}" STREQUAL "GL2PS")
|
||||||
|
get_filename_component(GL2PSLIB ${3RDPARTY_${PRODUCT_NAME}_LIBRARY} NAME)
|
||||||
|
|
||||||
|
if (SINGLE_GENERATOR)
|
||||||
|
install (FILES "${ABS_PATH}" DESTINATION "${INSTALL_DIR_LIB}" RENAME ${GL2PSLIB}.1)
|
||||||
|
else()
|
||||||
|
install (FILES "${ABS_PATH}"
|
||||||
|
CONFIGURATIONS Release
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}"
|
||||||
|
RENAME ${GL2PSLIB}.1)
|
||||||
|
install (FILES "${ABS_PATH}"
|
||||||
|
CONFIGURATIONS RelWithDebInfo
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}i"
|
||||||
|
RENAME ${GL2PSLIB}.1)
|
||||||
|
install (FILES "${ABS_PATH}"
|
||||||
|
CONFIGURATIONS Debug
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}d"
|
||||||
|
RENAME ${GL2PSLIB}.1)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
else()
|
||||||
|
# the library directory for using by the executable
|
||||||
|
if (WIN32)
|
||||||
|
set (USED_3RDPARTY_${PRODUCT_NAME}_DIR "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR}")
|
||||||
|
else()
|
||||||
|
set (USED_3RDPARTY_${PRODUCT_NAME}_DIR "${3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR}")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
mark_as_advanced (3RDPARTY_${PRODUCT_NAME}_LIBRARY 3RDPARTY_${PRODUCT_NAME}_DLL)
|
||||||
|
endif()
|
||||||
endmacro()
|
endmacro()
|
||||||
|
|
||||||
macro (COMPLIANCE_PRODUCT_CONSISTENCY LIBNAME)
|
macro (COMPLIANCE_PRODUCT_CONSISTENCY LIBNAME)
|
||||||
@@ -272,48 +277,52 @@ macro (COMPLIANCE_PRODUCT_CONSISTENCY LIBNAME)
|
|||||||
set (3RDPARTY_${LIBNAME}_INCLUDE_DIR "" CACHE FILEPATH "The directory containing headers of ${LIBNAME}" FORCE)
|
set (3RDPARTY_${LIBNAME}_INCLUDE_DIR "" CACHE FILEPATH "The directory containing headers of ${LIBNAME}" FORCE)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# library dir
|
if (BUILD_SHARED_LIBS)
|
||||||
|
# library dir
|
||||||
|
set (DOES_PATH_CONTAIN FALSE)
|
||||||
|
if (3RDPARTY_${LIBNAME}_LIBRARY_DIR AND EXISTS "${3RDPARTY_${LIBNAME}_LIBRARY_DIR}")
|
||||||
|
string (REGEX MATCH "${3RDPARTY_${LIBNAME}_DIR}" DOES_PATH_CONTAIN "${3RDPARTY_${LIBNAME}_LIBRARY_DIR}")
|
||||||
|
endif()
|
||||||
|
if (NOT DOES_PATH_CONTAIN)
|
||||||
|
set (3RDPARTY_${LIBNAME}_LIBRARY_DIR "" CACHE FILEPATH "The directory containing ${LIBNAME} library" FORCE)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
# shared library dir
|
||||||
|
if (WIN32)
|
||||||
|
set (DOES_PATH_CONTAIN FALSE)
|
||||||
|
if (3RDPARTY_${LIBNAME}_DLL_DIR AND EXISTS "${3RDPARTY_${LIBNAME}_DLL_DIR}")
|
||||||
|
string (REGEX MATCH "${3RDPARTY_${LIBNAME}_DIR}" DOES_PATH_CONTAIN "${3RDPARTY_${LIBNAME}_DLL_DIR}")
|
||||||
|
endif()
|
||||||
|
if (NOT DOES_PATH_CONTAIN)
|
||||||
|
set (3RDPARTY_${LIBNAME}_DLL_DIR "" CACHE FILEPATH "The directory containing ${LIBNAME} shared library" FORCE)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (BUILD_SHARED_LIBS)
|
||||||
|
# check library
|
||||||
set (DOES_PATH_CONTAIN FALSE)
|
set (DOES_PATH_CONTAIN FALSE)
|
||||||
if (3RDPARTY_${LIBNAME}_LIBRARY_DIR AND EXISTS "${3RDPARTY_${LIBNAME}_LIBRARY_DIR}")
|
if (3RDPARTY_${LIBNAME}_LIBRARY_DIR AND EXISTS "${3RDPARTY_${LIBNAME}_LIBRARY_DIR}")
|
||||||
string (REGEX MATCH "${3RDPARTY_${LIBNAME}_DIR}" DOES_PATH_CONTAIN "${3RDPARTY_${LIBNAME}_LIBRARY_DIR}")
|
if (3RDPARTY_${LIBNAME}_LIBRARY AND EXISTS "${3RDPARTY_${LIBNAME}_LIBRARY}")
|
||||||
|
string (REGEX MATCH "${3RDPARTY_${LIBNAME}_LIBRARY_DIR}" DOES_PATH_CONTAIN "${3RDPARTY_${LIBNAME}_LIBRARY}")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
if (NOT DOES_PATH_CONTAIN)
|
if (NOT DOES_PATH_CONTAIN)
|
||||||
set (3RDPARTY_${LIBNAME}_LIBRARY_DIR "" CACHE FILEPATH "The directory containing ${LIBNAME} library" FORCE)
|
set (3RDPARTY_${LIBNAME}_LIBRARY "" CACHE FILEPATH "${LIBNAME} library" FORCE)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# shared library dir
|
# check shared library
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
set (DOES_PATH_CONTAIN FALSE)
|
set (DOES_PATH_CONTAIN FALSE)
|
||||||
if (3RDPARTY_${LIBNAME}_DLL_DIR AND EXISTS "${3RDPARTY_${LIBNAME}_DLL_DIR}")
|
if (3RDPARTY_${LIBNAME}_DLL_DIR AND EXISTS "${3RDPARTY_${LIBNAME}_DLL_DIR}")
|
||||||
string (REGEX MATCH "${3RDPARTY_${LIBNAME}_DIR}" DOES_PATH_CONTAIN "${3RDPARTY_${LIBNAME}_DLL_DIR}")
|
if (3RDPARTY_${LIBNAME}_DLL AND EXISTS "${3RDPARTY_${LIBNAME}_DLL}")
|
||||||
|
string (REGEX MATCH "${3RDPARTY_${LIBNAME}_DLL_DIR}" DOES_PATH_CONTAIN "${3RDPARTY_${LIBNAME}_DLL}")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
if (NOT DOES_PATH_CONTAIN)
|
if (NOT DOES_PATH_CONTAIN)
|
||||||
set (3RDPARTY_${LIBNAME}_DLL_DIR "" CACHE FILEPATH "The directory containing ${LIBNAME} shared library" FORCE)
|
set (3RDPARTY_${LIBNAME}_DLL "" CACHE FILEPATH "${LIBNAME} shared library" FORCE)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# check library
|
|
||||||
set (DOES_PATH_CONTAIN FALSE)
|
|
||||||
if (3RDPARTY_${LIBNAME}_LIBRARY_DIR AND EXISTS "${3RDPARTY_${LIBNAME}_LIBRARY_DIR}")
|
|
||||||
if (3RDPARTY_${LIBNAME}_LIBRARY AND EXISTS "${3RDPARTY_${LIBNAME}_LIBRARY}")
|
|
||||||
string (REGEX MATCH "${3RDPARTY_${LIBNAME}_LIBRARY_DIR}" DOES_PATH_CONTAIN "${3RDPARTY_${LIBNAME}_LIBRARY}")
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
if (NOT DOES_PATH_CONTAIN)
|
|
||||||
set (3RDPARTY_${LIBNAME}_LIBRARY "" CACHE FILEPATH "${LIBNAME} library" FORCE)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# check shared library
|
|
||||||
if (WIN32)
|
|
||||||
set (DOES_PATH_CONTAIN FALSE)
|
|
||||||
if (3RDPARTY_${LIBNAME}_DLL_DIR AND EXISTS "${3RDPARTY_${LIBNAME}_DLL_DIR}")
|
|
||||||
if (3RDPARTY_${LIBNAME}_DLL AND EXISTS "${3RDPARTY_${LIBNAME}_DLL}")
|
|
||||||
string (REGEX MATCH "${3RDPARTY_${LIBNAME}_DLL_DIR}" DOES_PATH_CONTAIN "${3RDPARTY_${LIBNAME}_DLL}")
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
if (NOT DOES_PATH_CONTAIN)
|
|
||||||
set (3RDPARTY_${LIBNAME}_DLL "" CACHE FILEPATH "${LIBNAME} shared library" FORCE)
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
endmacro()
|
endmacro()
|
||||||
|
@@ -1,45 +1,58 @@
|
|||||||
# doxygen
|
# doxygen
|
||||||
|
set (DOXYGEN_MINIMUM_VERSION 1.8.4)
|
||||||
|
|
||||||
set (3RDPARTY_DOT_EXECUTABLE_DESCR "The path to the 'dot' tool producing layered drawings of directed graphs.\nThis tool used by doxygen")
|
if (DO_ONLY_CHECK_FOR_DOXYGEN)
|
||||||
set (3RDPARTY_DOXYGEN_EXECUTABLE_DESCR "The path to the doxygen command")
|
message (STATUS "Info. Detecting doxygen")
|
||||||
|
set (DOXYGEN_SKIP_DOT ON)
|
||||||
|
find_package (Doxygen ${DOXYGEN_MINIMUM_VERSION})
|
||||||
|
|
||||||
if (NOT DEFINED 3RDPARTY_DOXYGEN_EXECUTABLE)
|
set (CAN_DOXYGEN_BE_USED OFF)
|
||||||
set (3RDPARTY_DOXYGEN_EXECUTABLE "" CACHE FILEPATH "${3RDPARTY_DOXYGEN_EXECUTABLE_DESCR}")
|
if (DOXYGEN_EXECUTABLE)
|
||||||
endif()
|
set (CAN_DOXYGEN_BE_USED ON)
|
||||||
|
message (STATUS "Info. Doxygen is found and can be used")
|
||||||
if (NOT DEFINED 3RDPARTY_DOT_EXECUTABLE)
|
|
||||||
set (3RDPARTY_DOT_EXECUTABLE "" CACHE FILEPATH "${3RDPARTY_DOT_EXECUTABLE_DESCR}")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (NOT DEFINED 3RDPARTY_SKIP_DOT_EXECUTABLE)
|
|
||||||
set (3RDPARTY_SKIP_DOT_EXECUTABLE OFF CACHE BOOL "Skip trying to find Dot")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (3RDPARTY_SKIP_DOT_EXECUTABLE)
|
|
||||||
OCCT_CHECK_AND_UNSET (3RDPARTY_DOT_EXECUTABLE)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (NOT 3RDPARTY_DOXYGEN_EXECUTABLE OR (NOT 3RDPARTY_SKIP_DOT_EXECUTABLE AND NOT 3RDPARTY_DOT_EXECUTABLE))
|
|
||||||
|
|
||||||
set (DOXYGEN_SKIP_DOT ${3RDPARTY_SKIP_DOT_EXECUTABLE})
|
|
||||||
find_package (Doxygen)
|
|
||||||
|
|
||||||
if (NOT 3RDPARTY_DOXYGEN_EXECUTABLE AND DOXYGEN_EXECUTABLE)
|
|
||||||
set (3RDPARTY_DOXYGEN_EXECUTABLE "${DOXYGEN_EXECUTABLE}" CACHE FILEPATH "${3RDPARTY_DOXYGEN_EXECUTABLE_DESCR}" FORCE)
|
|
||||||
endif()
|
endif()
|
||||||
|
else()
|
||||||
if (NOT 3RDPARTY_SKIP_DOT_EXECUTABLE AND NOT 3RDPARTY_DOT_EXECUTABLE AND DOXYGEN_DOT_EXECUTABLE)
|
set (3RDPARTY_DOT_EXECUTABLE_DESCR "The path to the 'dot' tool producing layered drawings of directed graphs.\nThis tool used by doxygen")
|
||||||
set (3RDPARTY_DOT_EXECUTABLE "${DOXYGEN_DOT_EXECUTABLE}" CACHE FILEPATH "${3RDPARTY_DOT_EXECUTABLE_DESCR}" FORCE)
|
set (3RDPARTY_DOXYGEN_EXECUTABLE_DESCR "The path to the doxygen command")
|
||||||
|
|
||||||
|
if (NOT DEFINED 3RDPARTY_DOXYGEN_EXECUTABLE)
|
||||||
|
set (3RDPARTY_DOXYGEN_EXECUTABLE "" CACHE FILEPATH "${3RDPARTY_DOXYGEN_EXECUTABLE_DESCR}")
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
if (NOT 3RDPARTY_DOXYGEN_EXECUTABLE OR NOT EXISTS "${3RDPARTY_DOXYGEN_EXECUTABLE}")
|
if (NOT DEFINED 3RDPARTY_DOT_EXECUTABLE)
|
||||||
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_DOXYGEN_EXECUTABLE)
|
set (3RDPARTY_DOT_EXECUTABLE "" CACHE FILEPATH "${3RDPARTY_DOT_EXECUTABLE_DESCR}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (NOT 3RDPARTY_SKIP_DOT_EXECUTABLE)
|
if (NOT DEFINED 3RDPARTY_SKIP_DOT_EXECUTABLE)
|
||||||
if (NOT 3RDPARTY_DOT_EXECUTABLE OR NOT EXISTS "${3RDPARTY_DOT_EXECUTABLE}")
|
set (3RDPARTY_SKIP_DOT_EXECUTABLE ON CACHE BOOL "Skip trying to find Dot")
|
||||||
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_DOT_EXECUTABLE)
|
endif()
|
||||||
|
|
||||||
|
if (3RDPARTY_SKIP_DOT_EXECUTABLE)
|
||||||
|
OCCT_CHECK_AND_UNSET (3RDPARTY_DOT_EXECUTABLE)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (NOT 3RDPARTY_DOXYGEN_EXECUTABLE OR (NOT 3RDPARTY_SKIP_DOT_EXECUTABLE AND NOT 3RDPARTY_DOT_EXECUTABLE))
|
||||||
|
|
||||||
|
set (DOXYGEN_SKIP_DOT ${3RDPARTY_SKIP_DOT_EXECUTABLE})
|
||||||
|
find_package (Doxygen ${DOXYGEN_MINIMUM_VERSION})
|
||||||
|
|
||||||
|
if (NOT 3RDPARTY_DOXYGEN_EXECUTABLE AND DOXYGEN_EXECUTABLE)
|
||||||
|
set (3RDPARTY_DOXYGEN_EXECUTABLE "${DOXYGEN_EXECUTABLE}" CACHE FILEPATH "${3RDPARTY_DOXYGEN_EXECUTABLE_DESCR}" FORCE)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (NOT 3RDPARTY_SKIP_DOT_EXECUTABLE AND NOT 3RDPARTY_DOT_EXECUTABLE AND DOXYGEN_DOT_EXECUTABLE)
|
||||||
|
set (3RDPARTY_DOT_EXECUTABLE "${DOXYGEN_DOT_EXECUTABLE}" CACHE FILEPATH "${3RDPARTY_DOT_EXECUTABLE_DESCR}" FORCE)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (NOT 3RDPARTY_DOXYGEN_EXECUTABLE OR NOT EXISTS "${3RDPARTY_DOXYGEN_EXECUTABLE}")
|
||||||
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_DOXYGEN_EXECUTABLE)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (NOT 3RDPARTY_SKIP_DOT_EXECUTABLE)
|
||||||
|
if (NOT 3RDPARTY_DOT_EXECUTABLE OR NOT EXISTS "${3RDPARTY_DOT_EXECUTABLE}")
|
||||||
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_DOT_EXECUTABLE)
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
6
adm/cmake/egl.cmake
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
# EGL
|
||||||
|
if (WIN32)
|
||||||
|
THIRDPARTY_PRODUCT("EGL" "EGL/egl.h" "libEGL" "libEGL")
|
||||||
|
else()
|
||||||
|
THIRDPARTY_PRODUCT("EGL" "EGL/egl.h" "EGL" "EGL")
|
||||||
|
endif()
|
71
adm/cmake/eigen.cmake
Normal file
@@ -0,0 +1,71 @@
|
|||||||
|
# eigen
|
||||||
|
|
||||||
|
# eigen directory
|
||||||
|
if (NOT DEFINED 3RDPARTY_EIGEN_DIR)
|
||||||
|
set (3RDPARTY_EIGEN_DIR "" CACHE PATH "The directory containing eigen")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
# search for eigen in user defined directory
|
||||||
|
if (3RDPARTY_DIR AND EXISTS "${3RDPARTY_DIR}")
|
||||||
|
if (NOT 3RDPARTY_EIGEN_DIR OR NOT EXISTS "${3RDPARTY_EIGEN_DIR}")
|
||||||
|
FIND_PRODUCT_DIR("${3RDPARTY_DIR}" Eigen EIGEN_DIR_NAME)
|
||||||
|
if (EIGEN_DIR_NAME)
|
||||||
|
set (3RDPARTY_EIGEN_DIR "${3RDPARTY_DIR}/${EIGEN_DIR_NAME}" CACHE PATH "The directory containing eigen" FORCE)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (NOT DEFINED 3RDPARTY_EIGEN_INCLUDE_DIR)
|
||||||
|
set (3RDPARTY_EIGEN_INCLUDE_DIR "" CACHE FILEPATH "The directory containing headers of the EIGEN")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (NOT 3RDPARTY_EIGEN_INCLUDE_DIR OR NOT EXISTS "${3RDPARTY_EIGEN_INCLUDE_DIR}")
|
||||||
|
|
||||||
|
set (HEADER_NAMES Eigen)
|
||||||
|
|
||||||
|
set (3RDPARTY_EIGEN_INCLUDE_DIR "3RDPARTY_EIGEN_INCLUDE_DIR-NOTFOUND" CACHE PATH "the path to Eigen header file" FORCE)
|
||||||
|
|
||||||
|
if (3RDPARTY_EIGEN_DIR AND EXISTS "${3RDPARTY_EIGEN_DIR}")
|
||||||
|
find_path (3RDPARTY_EIGEN_INCLUDE_DIR NAMES ${HEADER_NAMES}
|
||||||
|
PATHS ${3RDPARTY_EIGEN_DIR}
|
||||||
|
PATH_SUFFIXES include eigen3 include/eigen3
|
||||||
|
CMAKE_FIND_ROOT_PATH_BOTH
|
||||||
|
NO_DEFAULT_PATH)
|
||||||
|
else()
|
||||||
|
find_path (3RDPARTY_EIGEN_INCLUDE_DIR NAMES ${HEADER_NAMES}
|
||||||
|
PATH_SUFFIXES include eigen3 include/eigen3
|
||||||
|
CMAKE_FIND_ROOT_PATH_BOTH)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
# use default (CMake) EIGEN search
|
||||||
|
if (NOT 3RDPARTY_EIGEN_INCLUDE_DIR OR NOT EXISTS "${3RDPARTY_EIGEN_INCLUDE_DIR}")
|
||||||
|
# use 3RDPARTY_FREETYPE_DIR if it is specified for freetype search
|
||||||
|
if (3RDPARTY_EIGEN_DIR AND EXISTS "${3RDPARTY_EIGEN_DIR}")
|
||||||
|
set (CACHED_EIGEN_DIR $ENV{Eigen3_DIR})
|
||||||
|
set (ENV{Eigen3_DIR} "${3RDPARTY_EIGEN_DIR}")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
find_package(Eigen3 QUIET)
|
||||||
|
|
||||||
|
# restore ENV{Eigen3_DIR}
|
||||||
|
if (3RDPARTY_EIGEN_DIR AND EXISTS "${3RDPARTY_EIGEN_DIR}")
|
||||||
|
set (ENV{Eigen3_DIR} ${CACHED_EIGEN_DIR})
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (${EIGEN3_FOUND})
|
||||||
|
set (3RDPARTY_EIGEN_INCLUDE_DIR "${EIGEN3_INCLUDE_DIR}" CACHE PATH "the path to Eigen header file" FORCE)
|
||||||
|
set (3RDPARTY_EIGEN_DIR "${EIGEN3_ROOT_DIR}" CACHE PATH "The directory containing eigen" FORCE)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (3RDPARTY_EIGEN_INCLUDE_DIR AND EXISTS "${3RDPARTY_EIGEN_INCLUDE_DIR}")
|
||||||
|
list (APPEND 3RDPARTY_INCLUDE_DIRS "${3RDPARTY_EIGEN_INCLUDE_DIR}")
|
||||||
|
else()
|
||||||
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_EIGEN_INCLUDE_DIR)
|
||||||
|
|
||||||
|
set (3RDPARTY_EIGEN_INCLUDE_DIR "" CACHE PATH "the path to Eigen header file" FORCE)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
# unset all redundant variables
|
||||||
|
OCCT_CHECK_AND_UNSET(Eigen3_DIR)
|
@@ -1,9 +0,0 @@
|
|||||||
#freeimageplus
|
|
||||||
|
|
||||||
if (WIN32)
|
|
||||||
if (3RDPARTY_FREEIMAGE_DIR AND NOT 3RDPARTY_FREEIMAGEPLUS_DIR)
|
|
||||||
set (3RDPARTY_FREEIMAGEPLUS_DIR "${3RDPARTY_FREEIMAGE_DIR}" CACHE PATH "The directory containing freeimageplus" FORCE)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
THIRDPARTY_PRODUCT("FREEIMAGEPLUS" "FreeImagePlus.h" "freeimageplus" "freeimageplusd")
|
|
||||||
endif()
|
|
@@ -1,6 +1,6 @@
|
|||||||
# freetype
|
# freetype
|
||||||
|
|
||||||
if (NOT DEFINED INSTALL_FREETYPE)
|
if (NOT DEFINED INSTALL_FREETYPE AND BUILD_SHARED_LIBS)
|
||||||
set (INSTALL_FREETYPE OFF CACHE BOOL "${INSTALL_FREETYPE_DESCR}")
|
set (INSTALL_FREETYPE OFF CACHE BOOL "${INSTALL_FREETYPE_DESCR}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -37,23 +37,25 @@ if (NOT DEFINED 3RDPARTY_FREETYPE_INCLUDE_DIR_freetype2)
|
|||||||
set (3RDPARTY_FREETYPE_INCLUDE_DIR_freetype2 "" CACHE FILEPATH "the path of freetype2")
|
set (3RDPARTY_FREETYPE_INCLUDE_DIR_freetype2 "" CACHE FILEPATH "the path of freetype2")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (NOT DEFINED 3RDPARTY_FREETYPE_LIBRARY OR NOT 3RDPARTY_FREETYPE_LIBRARY_DIR OR NOT EXISTS "${3RDPARTY_FREETYPE_LIBRARY_DIR}")
|
if (BUILD_SHARED_LIBS)
|
||||||
set (3RDPARTY_FREETYPE_LIBRARY "" CACHE FILEPATH "freetype library" FORCE)
|
if (NOT DEFINED 3RDPARTY_FREETYPE_LIBRARY OR NOT 3RDPARTY_FREETYPE_LIBRARY_DIR OR NOT EXISTS "${3RDPARTY_FREETYPE_LIBRARY_DIR}")
|
||||||
endif()
|
set (3RDPARTY_FREETYPE_LIBRARY "" CACHE FILEPATH "freetype library" FORCE)
|
||||||
|
|
||||||
if (NOT DEFINED 3RDPARTY_FREETYPE_LIBRARY_DIR)
|
|
||||||
set (3RDPARTY_FREETYPE_LIBRARY_DIR "" CACHE PATH "The directory containing freetype library")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (WIN32)
|
|
||||||
if (NOT DEFINED 3RDPARTY_FREETYPE_DLL OR NOT 3RDPARTY_FREETYPE_DLL_DIR OR NOT EXISTS "${3RDPARTY_FREETYPE_DLL_DIR}")
|
|
||||||
set (3RDPARTY_FREETYPE_DLL "" CACHE FILEPATH "freetype shared library" FORCE)
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
if (WIN32)
|
if (NOT DEFINED 3RDPARTY_FREETYPE_LIBRARY_DIR)
|
||||||
if (NOT DEFINED 3RDPARTY_FREETYPE_DLL_DIR)
|
set (3RDPARTY_FREETYPE_LIBRARY_DIR "" CACHE PATH "The directory containing freetype library")
|
||||||
set (3RDPARTY_FREETYPE_DLL_DIR "" CACHE PATH "The directory containing freetype shared library")
|
endif()
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
if (NOT DEFINED 3RDPARTY_FREETYPE_DLL OR NOT 3RDPARTY_FREETYPE_DLL_DIR OR NOT EXISTS "${3RDPARTY_FREETYPE_DLL_DIR}")
|
||||||
|
set (3RDPARTY_FREETYPE_DLL "" CACHE FILEPATH "freetype shared library" FORCE)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
if (NOT DEFINED 3RDPARTY_FREETYPE_DLL_DIR)
|
||||||
|
set (3RDPARTY_FREETYPE_DLL_DIR "" CACHE PATH "The directory containing freetype shared library")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -61,24 +63,25 @@ endif()
|
|||||||
if (3RDPARTY_FREETYPE_DIR AND EXISTS "${3RDPARTY_FREETYPE_DIR}")
|
if (3RDPARTY_FREETYPE_DIR AND EXISTS "${3RDPARTY_FREETYPE_DIR}")
|
||||||
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR 3RDPARTY_FREETYPE_INCLUDE_DIR_ft2build FILEPATH "the path to ft2build.h")
|
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR 3RDPARTY_FREETYPE_INCLUDE_DIR_ft2build FILEPATH "the path to ft2build.h")
|
||||||
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR 3RDPARTY_FREETYPE_INCLUDE_DIR_freetype2 FILEPATH "the path to ftheader.h")
|
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR 3RDPARTY_FREETYPE_INCLUDE_DIR_freetype2 FILEPATH "the path to ftheader.h")
|
||||||
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR 3RDPARTY_FREETYPE_LIBRARY FILEPATH "the path to freetype library")
|
if (BUILD_SHARED_LIBS)
|
||||||
|
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR 3RDPARTY_FREETYPE_LIBRARY FILEPATH "the path to freetype library")
|
||||||
|
|
||||||
if (3RDPARTY_FREETYPE_LIBRARY AND EXISTS "${3RDPARTY_FREETYPE_LIBRARY}")
|
if (3RDPARTY_FREETYPE_LIBRARY AND EXISTS "${3RDPARTY_FREETYPE_LIBRARY}")
|
||||||
get_filename_component (3RDPARTY_FREETYPE_LIBRARY_DIR "${3RDPARTY_FREETYPE_LIBRARY}" PATH)
|
get_filename_component (3RDPARTY_FREETYPE_LIBRARY_DIR "${3RDPARTY_FREETYPE_LIBRARY}" PATH)
|
||||||
set (3RDPARTY_FREETYPE_LIBRARY_DIR "${3RDPARTY_FREETYPE_LIBRARY_DIR}" CACHE PATH "The directory containing freetype library" FORCE)
|
set (3RDPARTY_FREETYPE_LIBRARY_DIR "${3RDPARTY_FREETYPE_LIBRARY_DIR}" CACHE PATH "The directory containing freetype library" FORCE)
|
||||||
else()
|
|
||||||
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR 3RDPARTY_FREETYPE_LIBRARY_DIR PATH "The directory containing freetype library")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (WIN32)
|
|
||||||
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR 3RDPARTY_FREETYPE_DLL FILEPATH "the path to freetype shared library")
|
|
||||||
|
|
||||||
if (3RDPARTY_FREETYPE_DLL AND EXISTS "${3RDPARTY_FREETYPE_DLL}")
|
|
||||||
get_filename_component (3RDPARTY_FREETYPE_DLL_DIR "${3RDPARTY_FREETYPE_DLL}" PATH)
|
|
||||||
set (3RDPARTY_FREETYPE_DLL_DIR "${3RDPARTY_FREETYPE_DLL_DIR}" CACHE PATH "The directory containing freetype shared library" FORCE)
|
|
||||||
else()
|
else()
|
||||||
|
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR 3RDPARTY_FREETYPE_LIBRARY_DIR PATH "The directory containing freetype library")
|
||||||
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR 3RDPARTY_FREETYPE_DLL_DIR PATH "The directory containing freetype shared library")
|
endif()
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR 3RDPARTY_FREETYPE_DLL FILEPATH "the path to freetype shared library")
|
||||||
|
|
||||||
|
if (3RDPARTY_FREETYPE_DLL AND EXISTS "${3RDPARTY_FREETYPE_DLL}")
|
||||||
|
get_filename_component (3RDPARTY_FREETYPE_DLL_DIR "${3RDPARTY_FREETYPE_DLL}" PATH)
|
||||||
|
set (3RDPARTY_FREETYPE_DLL_DIR "${3RDPARTY_FREETYPE_DLL_DIR}" CACHE PATH "The directory containing freetype shared library" FORCE)
|
||||||
|
else()
|
||||||
|
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR 3RDPARTY_FREETYPE_DLL_DIR PATH "The directory containing freetype shared library")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
@@ -118,7 +121,9 @@ if (IS_BUILTIN_SEARCH_REQUIRED)
|
|||||||
if (3RDPARTY_FREETYPE_DIR AND EXISTS "${3RDPARTY_FREETYPE_DIR}")
|
if (3RDPARTY_FREETYPE_DIR AND EXISTS "${3RDPARTY_FREETYPE_DIR}")
|
||||||
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR FREETYPE_INCLUDE_DIR_ft2build FILEPATH "the path to ft2build.h")
|
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR FREETYPE_INCLUDE_DIR_ft2build FILEPATH "the path to ft2build.h")
|
||||||
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR FREETYPE_INCLUDE_DIR_freetype2 FILEPATH "the path to ftheader.h")
|
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR FREETYPE_INCLUDE_DIR_freetype2 FILEPATH "the path to ftheader.h")
|
||||||
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR FREETYPE_LIBRARY FILEPATH "freetype library")
|
if (BUILD_SHARED_LIBS)
|
||||||
|
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_FREETYPE_DIR FREETYPE_LIBRARY FILEPATH "freetype library")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# assign the found paths to corresponding 3RDPARTY_FREETYPE_ variables
|
# assign the found paths to corresponding 3RDPARTY_FREETYPE_ variables
|
||||||
@@ -134,17 +139,19 @@ if (IS_BUILTIN_SEARCH_REQUIRED)
|
|||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (NOT 3RDPARTY_FREETYPE_LIBRARY OR NOT EXISTS "${3RDPARTY_FREETYPE_LIBRARY}")
|
if (BUILD_SHARED_LIBS)
|
||||||
if (FREETYPE_LIBRARY AND EXISTS "${FREETYPE_LIBRARY}")
|
if (NOT 3RDPARTY_FREETYPE_LIBRARY OR NOT EXISTS "${3RDPARTY_FREETYPE_LIBRARY}")
|
||||||
set (3RDPARTY_FREETYPE_LIBRARY "${FREETYPE_LIBRARY}" CACHE FILEPATH "The path to freetype library" FORCE)
|
if (FREETYPE_LIBRARY AND EXISTS "${FREETYPE_LIBRARY}")
|
||||||
|
set (3RDPARTY_FREETYPE_LIBRARY "${FREETYPE_LIBRARY}" CACHE FILEPATH "The path to freetype library" FORCE)
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
if (3RDPARTY_FREETYPE_LIBRARY AND EXISTS "${3RDPARTY_FREETYPE_LIBRARY}")
|
if (3RDPARTY_FREETYPE_LIBRARY AND EXISTS "${3RDPARTY_FREETYPE_LIBRARY}")
|
||||||
get_filename_component (3RDPARTY_FREETYPE_LIBRARY_DIR "${3RDPARTY_FREETYPE_LIBRARY}" PATH)
|
get_filename_component (3RDPARTY_FREETYPE_LIBRARY_DIR "${3RDPARTY_FREETYPE_LIBRARY}" PATH)
|
||||||
set (3RDPARTY_FREETYPE_LIBRARY_DIR "${3RDPARTY_FREETYPE_LIBRARY_DIR}" CACHE PATH "The directory containing freetype library" FORCE)
|
set (3RDPARTY_FREETYPE_LIBRARY_DIR "${3RDPARTY_FREETYPE_LIBRARY_DIR}" CACHE PATH "The directory containing freetype library" FORCE)
|
||||||
else()
|
else()
|
||||||
set (3RDPARTY_FREETYPE_LIBRARY_DIR "" CACHE PATH "The directory containing freetype library" FORCE)
|
set (3RDPARTY_FREETYPE_LIBRARY_DIR "" CACHE PATH "The directory containing freetype library" FORCE)
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -211,131 +218,132 @@ else()
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
# freetype library
|
# freetype library
|
||||||
if (NOT 3RDPARTY_FREETYPE_LIBRARY OR NOT EXISTS "${3RDPARTY_FREETYPE_LIBRARY}")
|
if (BUILD_SHARED_LIBS)
|
||||||
set (CMAKE_FIND_LIBRARY_SUFFIXES .lib .so .dylib)
|
if (NOT 3RDPARTY_FREETYPE_LIBRARY OR NOT EXISTS "${3RDPARTY_FREETYPE_LIBRARY}")
|
||||||
|
set (CMAKE_FIND_LIBRARY_SUFFIXES .lib .so .dylib .a)
|
||||||
|
|
||||||
set (FREETYPE_PATH_SUFFIXES lib)
|
set (FREETYPE_PATH_SUFFIXES lib)
|
||||||
if (ANDROID)
|
if (ANDROID)
|
||||||
set (FREETYPE_PATH_SUFFIXES ${FREETYPE_PATH_SUFFIXES} libs/${ANDROID_ABI})
|
set (FREETYPE_PATH_SUFFIXES ${FREETYPE_PATH_SUFFIXES} libs/${ANDROID_ABI})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# set 3RDPARTY_FREETYPE_LIBRARY as notfound, otherwise find_library can't assign a new value to 3RDPARTY_FREETYPE_LIBRARY
|
# set 3RDPARTY_FREETYPE_LIBRARY as notfound, otherwise find_library can't assign a new value to 3RDPARTY_FREETYPE_LIBRARY
|
||||||
set (3RDPARTY_FREETYPE_LIBRARY "3RDPARTY_FREETYPE_LIBRARY-NOTFOUND" CACHE FILEPATH "The path to freetype library" FORCE)
|
set (3RDPARTY_FREETYPE_LIBRARY "3RDPARTY_FREETYPE_LIBRARY-NOTFOUND" CACHE FILEPATH "The path to freetype library" FORCE)
|
||||||
|
|
||||||
if (3RDPARTY_FREETYPE_DIR AND EXISTS "${3RDPARTY_FREETYPE_DIR}")
|
|
||||||
find_library (3RDPARTY_FREETYPE_LIBRARY freetype
|
|
||||||
PATHS "${3RDPARTY_FREETYPE_LIBRARY_DIR}" "${3RDPARTY_FREETYPE_DIR}"
|
|
||||||
PATH_SUFFIXES ${FREETYPE_PATH_SUFFIXES}
|
|
||||||
CMAKE_FIND_ROOT_PATH_BOTH
|
|
||||||
NO_DEFAULT_PATH)
|
|
||||||
else()
|
|
||||||
find_library (3RDPARTY_FREETYPE_LIBRARY freetype
|
|
||||||
PATH_SUFFIXES ${FREETYPE_PATH_SUFFIXES}
|
|
||||||
CMAKE_FIND_ROOT_PATH_BOTH)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (3RDPARTY_FREETYPE_LIBRARY AND EXISTS "${3RDPARTY_FREETYPE_LIBRARY}")
|
|
||||||
get_filename_component (3RDPARTY_FREETYPE_LIBRARY_DIR "${3RDPARTY_FREETYPE_LIBRARY}" PATH)
|
|
||||||
set (3RDPARTY_FREETYPE_LIBRARY_DIR "${3RDPARTY_FREETYPE_LIBRARY_DIR}" CACHE PATH "The directory containing freetype library" FORCE)
|
|
||||||
else()
|
|
||||||
set (3RDPARTY_FREETYPE_LIBRARY_DIR "" CACHE PATH "The directory containing freetype library" FORCE)
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (3RDPARTY_FREETYPE_LIBRARY_DIR AND EXISTS "${3RDPARTY_FREETYPE_LIBRARY_DIR}")
|
|
||||||
list (APPEND 3RDPARTY_LIBRARY_DIRS "${3RDPARTY_FREETYPE_LIBRARY_DIR}")
|
|
||||||
else()
|
|
||||||
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_FREETYPE_LIBRARY_DIR)
|
|
||||||
|
|
||||||
set (3RDPARTY_FREETYPE_LIBRARY "" CACHE FILEPATH "The path to freetype library" FORCE)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# freetype shared library
|
|
||||||
if (WIN32)
|
|
||||||
if (NOT 3RDPARTY_FREETYPE_DLL OR NOT EXISTS "${3RDPARTY_FREETYPE_DLL}")
|
|
||||||
|
|
||||||
set (CMAKE_FIND_LIBRARY_SUFFIXES .dll)
|
|
||||||
|
|
||||||
# set 3RDPARTY_FREETYPE_DLL as notfound, otherwise find_library can't assign a new value to 3RDPARTY_FREETYPE_DLL
|
|
||||||
set (3RDPARTY_FREETYPE_DLL "3RDPARTY_FREETYPE_DLL-NOTFOUND" CACHE FILEPATH "The path to freetype shared library" FORCE)
|
|
||||||
|
|
||||||
if (3RDPARTY_FREETYPE_DIR AND EXISTS "${3RDPARTY_FREETYPE_DIR}")
|
if (3RDPARTY_FREETYPE_DIR AND EXISTS "${3RDPARTY_FREETYPE_DIR}")
|
||||||
find_library (3RDPARTY_FREETYPE_DLL freetype
|
find_library (3RDPARTY_FREETYPE_LIBRARY freetype
|
||||||
PATHS "${3RDPARTY_FREETYPE_DIR}"
|
PATHS "${3RDPARTY_FREETYPE_LIBRARY_DIR}" "${3RDPARTY_FREETYPE_DIR}"
|
||||||
PATH_SUFFIXES bin
|
PATH_SUFFIXES ${FREETYPE_PATH_SUFFIXES}
|
||||||
NO_DEFAULT_PATH)
|
CMAKE_FIND_ROOT_PATH_BOTH
|
||||||
|
NO_DEFAULT_PATH)
|
||||||
else()
|
else()
|
||||||
find_library (3RDPARTY_FREETYPE_DLL freetype
|
find_library (3RDPARTY_FREETYPE_LIBRARY freetype
|
||||||
PATH_SUFFIXES bin)
|
PATH_SUFFIXES ${FREETYPE_PATH_SUFFIXES}
|
||||||
|
CMAKE_FIND_ROOT_PATH_BOTH)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (3RDPARTY_FREETYPE_DLL AND EXISTS "${3RDPARTY_FREETYPE_DLL}")
|
if (3RDPARTY_FREETYPE_LIBRARY AND EXISTS "${3RDPARTY_FREETYPE_LIBRARY}")
|
||||||
get_filename_component (3RDPARTY_FREETYPE_DLL_DIR "${3RDPARTY_FREETYPE_DLL}" PATH)
|
get_filename_component (3RDPARTY_FREETYPE_LIBRARY_DIR "${3RDPARTY_FREETYPE_LIBRARY}" PATH)
|
||||||
set (3RDPARTY_FREETYPE_DLL_DIR "${3RDPARTY_FREETYPE_DLL_DIR}" CACHE PATH "The directory containing freetype library" FORCE)
|
set (3RDPARTY_FREETYPE_LIBRARY_DIR "${3RDPARTY_FREETYPE_LIBRARY_DIR}" CACHE PATH "The directory containing freetype library" FORCE)
|
||||||
else()
|
else()
|
||||||
set (3RDPARTY_FREETYPE_DLL_DIR "" CACHE PATH "The directory containing freetype shared library" FORCE)
|
set (3RDPARTY_FREETYPE_LIBRARY_DIR "" CACHE PATH "The directory containing freetype library" FORCE)
|
||||||
|
|
||||||
set (3RDPARTY_FREETYPE_DLL "" CACHE FILEPATH "freetype shared library" FORCE)
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (3RDPARTY_FREETYPE_DLL_DIR OR EXISTS "${3RDPARTY_FREETYPE_DLL_DIR}")
|
if (3RDPARTY_FREETYPE_LIBRARY_DIR AND EXISTS "${3RDPARTY_FREETYPE_LIBRARY_DIR}")
|
||||||
list (APPEND 3RDPARTY_DLL_DIRS "${3RDPARTY_FREETYPE_DLL_DIR}")
|
list (APPEND 3RDPARTY_LIBRARY_DIRS "${3RDPARTY_FREETYPE_LIBRARY_DIR}")
|
||||||
else()
|
else()
|
||||||
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_FREETYPE_DLL_DIR)
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_FREETYPE_LIBRARY_DIR)
|
||||||
|
|
||||||
|
set (3RDPARTY_FREETYPE_LIBRARY "" CACHE FILEPATH "The path to freetype library" FORCE)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
|
|
||||||
# install instructions
|
|
||||||
if (INSTALL_FREETYPE)
|
|
||||||
OCCT_MAKE_OS_WITH_BITNESS()
|
|
||||||
|
|
||||||
|
# freetype shared library
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
if (SINGLE_GENERATOR)
|
if (NOT 3RDPARTY_FREETYPE_DLL OR NOT EXISTS "${3RDPARTY_FREETYPE_DLL}")
|
||||||
install (FILES "${3RDPARTY_FREETYPE_DLL}" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}")
|
|
||||||
else()
|
|
||||||
install (FILES "${3RDPARTY_FREETYPE_DLL}"
|
|
||||||
CONFIGURATIONS Release
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}")
|
|
||||||
install (FILES "${3RDPARTY_FREETYPE_DLL}"
|
|
||||||
CONFIGURATIONS RelWithDebInfo
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}i")
|
|
||||||
install (FILES "${3RDPARTY_FREETYPE_DLL}"
|
|
||||||
CONFIGURATIONS Debug
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}d")
|
|
||||||
endif()
|
|
||||||
else()
|
|
||||||
get_filename_component(3RDPARTY_FREETYPE_LIBRARY_ABS ${3RDPARTY_FREETYPE_LIBRARY} REALPATH)
|
|
||||||
get_filename_component(3RDPARTY_FREETYPE_LIBRARY_NAME ${3RDPARTY_FREETYPE_LIBRARY} NAME)
|
|
||||||
|
|
||||||
if (SINGLE_GENERATOR)
|
set (CMAKE_FIND_LIBRARY_SUFFIXES .dll)
|
||||||
install (FILES "${3RDPARTY_FREETYPE_LIBRARY_ABS}"
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}"
|
# set 3RDPARTY_FREETYPE_DLL as notfound, otherwise find_library can't assign a new value to 3RDPARTY_FREETYPE_DLL
|
||||||
RENAME ${3RDPARTY_FREETYPE_LIBRARY_NAME}.6)
|
set (3RDPARTY_FREETYPE_DLL "3RDPARTY_FREETYPE_DLL-NOTFOUND" CACHE FILEPATH "The path to freetype shared library" FORCE)
|
||||||
|
|
||||||
|
if (3RDPARTY_FREETYPE_DIR AND EXISTS "${3RDPARTY_FREETYPE_DIR}")
|
||||||
|
find_library (3RDPARTY_FREETYPE_DLL freetype
|
||||||
|
PATHS "${3RDPARTY_FREETYPE_DIR}"
|
||||||
|
PATH_SUFFIXES bin
|
||||||
|
NO_DEFAULT_PATH)
|
||||||
|
else()
|
||||||
|
find_library (3RDPARTY_FREETYPE_DLL freetype
|
||||||
|
PATH_SUFFIXES bin)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (3RDPARTY_FREETYPE_DLL AND EXISTS "${3RDPARTY_FREETYPE_DLL}")
|
||||||
|
get_filename_component (3RDPARTY_FREETYPE_DLL_DIR "${3RDPARTY_FREETYPE_DLL}" PATH)
|
||||||
|
set (3RDPARTY_FREETYPE_DLL_DIR "${3RDPARTY_FREETYPE_DLL_DIR}" CACHE PATH "The directory containing freetype library" FORCE)
|
||||||
|
else()
|
||||||
|
set (3RDPARTY_FREETYPE_DLL_DIR "" CACHE PATH "The directory containing freetype shared library" FORCE)
|
||||||
|
|
||||||
|
set (3RDPARTY_FREETYPE_DLL "" CACHE FILEPATH "freetype shared library" FORCE)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (3RDPARTY_FREETYPE_DLL_DIR OR EXISTS "${3RDPARTY_FREETYPE_DLL_DIR}")
|
||||||
|
list (APPEND 3RDPARTY_DLL_DIRS "${3RDPARTY_FREETYPE_DLL_DIR}")
|
||||||
else()
|
else()
|
||||||
install (FILES "${3RDPARTY_FREETYPE_LIBRARY_ABS}"
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_FREETYPE_DLL_DIR)
|
||||||
CONFIGURATIONS Release
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}"
|
|
||||||
RENAME ${3RDPARTY_FREETYPE_LIBRARY_NAME}.6)
|
|
||||||
install (FILES "${3RDPARTY_FREETYPE_LIBRARY_ABS}"
|
|
||||||
CONFIGURATIONS RelWithDebInfo
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}i"
|
|
||||||
RENAME ${3RDPARTY_FREETYPE_LIBRARY_NAME}.6)
|
|
||||||
install (FILES "${3RDPARTY_FREETYPE_LIBRARY_ABS}"
|
|
||||||
CONFIGURATIONS Debug
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}d"
|
|
||||||
RENAME ${3RDPARTY_FREETYPE_LIBRARY_NAME}.6)
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set (USED_3RDPARTY_FREETYPE_DIR "")
|
# install instructions
|
||||||
else()
|
if (INSTALL_FREETYPE)
|
||||||
# the library directory for using by the executable
|
OCCT_MAKE_OS_WITH_BITNESS()
|
||||||
if (WIN32)
|
|
||||||
set (USED_3RDPARTY_FREETYPE_DIR ${3RDPARTY_FREETYPE_DLL_DIR})
|
if (WIN32)
|
||||||
|
if (SINGLE_GENERATOR)
|
||||||
|
install (FILES "${3RDPARTY_FREETYPE_DLL}" DESTINATION "${INSTALL_DIR_BIN}")
|
||||||
|
else()
|
||||||
|
install (FILES "${3RDPARTY_FREETYPE_DLL}"
|
||||||
|
CONFIGURATIONS Release
|
||||||
|
DESTINATION "${INSTALL_DIR_BIN}")
|
||||||
|
install (FILES "${3RDPARTY_FREETYPE_DLL}"
|
||||||
|
CONFIGURATIONS RelWithDebInfo
|
||||||
|
DESTINATION "${INSTALL_DIR_BIN}i")
|
||||||
|
install (FILES "${3RDPARTY_FREETYPE_DLL}"
|
||||||
|
CONFIGURATIONS Debug
|
||||||
|
DESTINATION "${INSTALL_DIR_BIN}d")
|
||||||
|
endif()
|
||||||
|
else()
|
||||||
|
get_filename_component(3RDPARTY_FREETYPE_LIBRARY_ABS ${3RDPARTY_FREETYPE_LIBRARY} REALPATH)
|
||||||
|
get_filename_component(3RDPARTY_FREETYPE_LIBRARY_NAME ${3RDPARTY_FREETYPE_LIBRARY} NAME)
|
||||||
|
|
||||||
|
if (SINGLE_GENERATOR)
|
||||||
|
install (FILES "${3RDPARTY_FREETYPE_LIBRARY_ABS}"
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}"
|
||||||
|
RENAME ${3RDPARTY_FREETYPE_LIBRARY_NAME}.6)
|
||||||
|
else()
|
||||||
|
install (FILES "${3RDPARTY_FREETYPE_LIBRARY_ABS}"
|
||||||
|
CONFIGURATIONS Release
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}"
|
||||||
|
RENAME ${3RDPARTY_FREETYPE_LIBRARY_NAME}.6)
|
||||||
|
install (FILES "${3RDPARTY_FREETYPE_LIBRARY_ABS}"
|
||||||
|
CONFIGURATIONS RelWithDebInfo
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}i"
|
||||||
|
RENAME ${3RDPARTY_FREETYPE_LIBRARY_NAME}.6)
|
||||||
|
install (FILES "${3RDPARTY_FREETYPE_LIBRARY_ABS}"
|
||||||
|
CONFIGURATIONS Debug
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}d"
|
||||||
|
RENAME ${3RDPARTY_FREETYPE_LIBRARY_NAME}.6)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
set (USED_3RDPARTY_FREETYPE_DIR "")
|
||||||
else()
|
else()
|
||||||
set (USED_3RDPARTY_FREETYPE_DIR ${3RDPARTY_FREETYPE_LIBRARY_DIR})
|
# the library directory for using by the executable
|
||||||
|
if (WIN32)
|
||||||
|
set (USED_3RDPARTY_FREETYPE_DIR ${3RDPARTY_FREETYPE_DLL_DIR})
|
||||||
|
else()
|
||||||
|
set (USED_3RDPARTY_FREETYPE_DIR ${3RDPARTY_FREETYPE_LIBRARY_DIR})
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -344,4 +352,12 @@ OCCT_CHECK_AND_UNSET(FREETYPE_INCLUDE_DIR_ft2build)
|
|||||||
OCCT_CHECK_AND_UNSET(FREETYPE_INCLUDE_DIR_freetype2)
|
OCCT_CHECK_AND_UNSET(FREETYPE_INCLUDE_DIR_freetype2)
|
||||||
OCCT_CHECK_AND_UNSET(FREETYPE_LIBRARY)
|
OCCT_CHECK_AND_UNSET(FREETYPE_LIBRARY)
|
||||||
|
|
||||||
mark_as_advanced (3RDPARTY_FREETYPE_LIBRARY 3RDPARTY_FREETYPE_DLL)
|
if (BUILD_SHARED_LIBS)
|
||||||
|
mark_as_advanced (3RDPARTY_FREETYPE_LIBRARY 3RDPARTY_FREETYPE_DLL)
|
||||||
|
else()
|
||||||
|
OCCT_CHECK_AND_UNSET(3RDPARTY_FREETYPE_DLL)
|
||||||
|
OCCT_CHECK_AND_UNSET(3RDPARTY_FREETYPE_DLL_DIR)
|
||||||
|
OCCT_CHECK_AND_UNSET(3RDPARTY_FREETYPE_LIBRARY)
|
||||||
|
OCCT_CHECK_AND_UNSET(3RDPARTY_FREETYPE_LIBRARY_DIR)
|
||||||
|
OCCT_CHECK_AND_UNSET(INSTALL_FREETYPE)
|
||||||
|
endif()
|
||||||
|
6
adm/cmake/gles2.cmake
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
# OpenGL ES 2.0
|
||||||
|
if (WIN32)
|
||||||
|
THIRDPARTY_PRODUCT("GLES2" "GLES2/gl2.h" "libGLESv2" "libGLESv2")
|
||||||
|
else()
|
||||||
|
THIRDPARTY_PRODUCT("GLES2" "GLES2/gl2.h" "GLESv2" "GLESv2")
|
||||||
|
endif()
|
@@ -10,7 +10,7 @@ if (NOT DEFINED USE_TCL)
|
|||||||
OCCT_IS_PRODUCT_REQUIRED (CSF_TclLibs USE_TCL)
|
OCCT_IS_PRODUCT_REQUIRED (CSF_TclLibs USE_TCL)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (USE_TCL)
|
if (USE_TCL AND BUILD_SHARED_LIBS)
|
||||||
if ("${3RDPARTY_TCL_LIBRARY_VERSION}" STREQUAL "")
|
if ("${3RDPARTY_TCL_LIBRARY_VERSION}" STREQUAL "")
|
||||||
message (STATUS "Warning: TCL version has not been specified by CSF_TclLibs defining thus it will be used as 8.6")
|
message (STATUS "Warning: TCL version has not been specified by CSF_TclLibs defining thus it will be used as 8.6")
|
||||||
set (3RDPARTY_TCL_LIBRARY_VERSION "8.6")
|
set (3RDPARTY_TCL_LIBRARY_VERSION "8.6")
|
||||||
@@ -33,10 +33,12 @@ if (WIN32)
|
|||||||
set (CSF_gdi32 "gdi32.lib")
|
set (CSF_gdi32 "gdi32.lib")
|
||||||
set (CSF_user32 "user32.lib")
|
set (CSF_user32 "user32.lib")
|
||||||
set (CSF_wsock32 "wsock32.lib")
|
set (CSF_wsock32 "wsock32.lib")
|
||||||
set (CSF_winspool "Winspool.lib")
|
|
||||||
set (CSF_psapi "Psapi.lib")
|
set (CSF_psapi "Psapi.lib")
|
||||||
set (CSF_AviLibs "ws2_32.lib vfw32.lib")
|
if ("${CMAKE_SYSTEM_NAME}" STREQUAL "WindowsStore" OR USE_GLES2)
|
||||||
set (CSF_OpenGlLibs "opengl32.lib glu32.lib")
|
set (CSF_OpenGlLibs "libEGL.lib libGLESv2.lib")
|
||||||
|
else()
|
||||||
|
set (CSF_OpenGlLibs "opengl32.lib")
|
||||||
|
endif()
|
||||||
|
|
||||||
if (USE_FREETYPE)
|
if (USE_FREETYPE)
|
||||||
set (CSF_FREETYPE "freetype.lib")
|
set (CSF_FREETYPE "freetype.lib")
|
||||||
@@ -44,8 +46,14 @@ if (WIN32)
|
|||||||
set (CSF_FREETYPE)
|
set (CSF_FREETYPE)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if (USE_GL2PS)
|
||||||
|
set (CSF_GL2PS "gl2ps.lib")
|
||||||
|
else()
|
||||||
|
set (CSF_GL2PS)
|
||||||
|
endif()
|
||||||
|
|
||||||
if (USE_FREEIMAGE)
|
if (USE_FREEIMAGE)
|
||||||
set (CSF_FreeImagePlus "freeimage.lib freeimageplus.lib")
|
set (CSF_FreeImagePlus "freeimage.lib")
|
||||||
else()
|
else()
|
||||||
set (CSF_FreeImagePlus)
|
set (CSF_FreeImagePlus)
|
||||||
endif()
|
endif()
|
||||||
@@ -89,7 +97,7 @@ else()
|
|||||||
set (CSF_OpenGlLibs "EGL GLESv2")
|
set (CSF_OpenGlLibs "EGL GLESv2")
|
||||||
elseif (UNIX)
|
elseif (UNIX)
|
||||||
set (CSF_ThreadLibs "pthread rt stdc++")
|
set (CSF_ThreadLibs "pthread rt stdc++")
|
||||||
set (CSF_OpenGlLibs "GLU GL")
|
set (CSF_OpenGlLibs "GL")
|
||||||
set (CSF_XwLibs "X11 Xext Xmu Xi")
|
set (CSF_XwLibs "X11 Xext Xmu Xi")
|
||||||
set (CSF_dl "dl")
|
set (CSF_dl "dl")
|
||||||
|
|
||||||
|
@@ -104,19 +104,32 @@ elseif (CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_GNUCXX OR "${CMAKE_CXX_COMP
|
|||||||
elseif(NOT WIN32)
|
elseif(NOT WIN32)
|
||||||
set (CMAKE_SHARED_LINKER_FLAGS "-lm ${CMAKE_SHARED_LINKER_FLAGS}")
|
set (CMAKE_SHARED_LINKER_FLAGS "-lm ${CMAKE_SHARED_LINKER_FLAGS}")
|
||||||
endif()
|
endif()
|
||||||
else()
|
|
||||||
if (NOT ANDROID AND NOT MINGW)
|
|
||||||
set (CMAKE_STATIC_LINKER_FLAGS "-lm ${CMAKE_SHARED_STATIC_FLAGS}")
|
|
||||||
endif()
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(MINGW)
|
if(MINGW)
|
||||||
|
# Set default release optimization option to O2 instead of O3, since in
|
||||||
|
# some OCCT related examples, this gives significantly smaller binaries
|
||||||
|
# at comparable performace with MinGW-w64.
|
||||||
|
string (REGEX MATCH "-O3" IS_O3_CXX "${CMAKE_CXX_FLAGS_RELEASE}")
|
||||||
|
if (IS_O3_CXX)
|
||||||
|
string (REGEX REPLACE "-O3" "-O2" CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE}")
|
||||||
|
else()
|
||||||
|
set (CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -O2")
|
||||||
|
endif()
|
||||||
|
|
||||||
set (CMAKE_CXX_FLAGS "-std=gnu++0x ${CMAKE_CXX_FLAGS}")
|
set (CMAKE_CXX_FLAGS "-std=gnu++0x ${CMAKE_CXX_FLAGS}")
|
||||||
add_definitions(-D_WIN32_WINNT=0x0501)
|
add_definitions(-D_WIN32_WINNT=0x0501)
|
||||||
# workaround bugs in mingw with vtable export
|
# workaround bugs in mingw with vtable export
|
||||||
set (CMAKE_SHARED_LINKER_FLAGS "-Wl,--export-all-symbols")
|
set (CMAKE_SHARED_LINKER_FLAGS "-Wl,--export-all-symbols")
|
||||||
elseif (DEFINED CMAKE_COMPILER_IS_GNUCXX OR "x${CMAKE_CXX_COMPILER_ID}" STREQUAL "xClang")
|
elseif ("x${CMAKE_CXX_COMPILER_ID}" STREQUAL "xClang")
|
||||||
|
if (APPLE)
|
||||||
|
# CLang can be used with both libstdc++ and libc++, however on OS X libstdc++ is outdated.
|
||||||
|
set (CMAKE_CXX_FLAGS "-std=c++0x -stdlib=libc++ ${CMAKE_CXX_FLAGS}")
|
||||||
|
else()
|
||||||
|
set (CMAKE_CXX_FLAGS "-std=c++0x ${CMAKE_CXX_FLAGS}")
|
||||||
|
endif()
|
||||||
|
elseif (DEFINED CMAKE_COMPILER_IS_GNUCXX)
|
||||||
set (CMAKE_CXX_FLAGS "-std=c++0x ${CMAKE_CXX_FLAGS}")
|
set (CMAKE_CXX_FLAGS "-std=c++0x ${CMAKE_CXX_FLAGS}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
@@ -257,6 +257,8 @@ macro (COLLECT_AND_INSTALL_OCCT_HEADER_FILES ROOT_TARGET_OCCT_DIR OCCT_BUILD_TOO
|
|||||||
foreach (FILE_INDEX RANGE ${ALL_FILES_NB})
|
foreach (FILE_INDEX RANGE ${ALL_FILES_NB})
|
||||||
list (GET OCCT_ALL_FILE_NAMES ${FILE_INDEX} OCCT_FILE_NAME)
|
list (GET OCCT_ALL_FILE_NAMES ${FILE_INDEX} OCCT_FILE_NAME)
|
||||||
|
|
||||||
|
string (REGEX REPLACE "[^:]+:+" "" OCCT_FILE_NAME "${OCCT_FILE_NAME}")
|
||||||
|
|
||||||
if ("${OCCT_FILE_IN_DIR_NAME}" STREQUAL "${OCCT_FILE_NAME}")
|
if ("${OCCT_FILE_IN_DIR_NAME}" STREQUAL "${OCCT_FILE_NAME}")
|
||||||
set (OCCT_FILE_IN_DIR_STATUS ON)
|
set (OCCT_FILE_IN_DIR_STATUS ON)
|
||||||
|
|
||||||
@@ -296,10 +298,11 @@ macro (COLLECT_AND_INSTALL_OCCT_HEADER_FILES ROOT_TARGET_OCCT_DIR OCCT_BUILD_TOO
|
|||||||
|
|
||||||
foreach (OCCT_HEADER_FILE ${OCCT_HEADER_FILES_COMPLETE})
|
foreach (OCCT_HEADER_FILE ${OCCT_HEADER_FILES_COMPLETE})
|
||||||
get_filename_component (HEADER_FILE_NAME ${OCCT_HEADER_FILE} NAME)
|
get_filename_component (HEADER_FILE_NAME ${OCCT_HEADER_FILE} NAME)
|
||||||
|
set (OCCT_HEADER_FILE_CONTENT "#include \"${OCCT_HEADER_FILE}\"")
|
||||||
configure_file ("${TEMPLATE_HEADER_PATH}" "${ROOT_TARGET_OCCT_DIR}/inc/${HEADER_FILE_NAME}" @ONLY)
|
configure_file ("${TEMPLATE_HEADER_PATH}" "${ROOT_TARGET_OCCT_DIR}/inc/${HEADER_FILE_NAME}" @ONLY)
|
||||||
endforeach()
|
endforeach()
|
||||||
|
|
||||||
install (FILES ${OCCT_HEADER_FILES_COMPLETE} DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_INCLUDE}")
|
install (FILES ${OCCT_HEADER_FILES_COMPLETE} DESTINATION "${INSTALL_DIR_INCLUDE}")
|
||||||
|
|
||||||
string(TIMESTAMP CURRENT_TIME "%H:%M:%S")
|
string(TIMESTAMP CURRENT_TIME "%H:%M:%S")
|
||||||
message (STATUS "Info: \(${CURRENT_TIME}\) Checking headers in inc folder...")
|
message (STATUS "Info: \(${CURRENT_TIME}\) Checking headers in inc folder...")
|
||||||
@@ -576,3 +579,26 @@ macro (OCCT_INSERT_CODE_FOR_TARGET)
|
|||||||
set (OCCT_INSTALL_BIN_LETTER \"d\")
|
set (OCCT_INSTALL_BIN_LETTER \"d\")
|
||||||
endif()")
|
endif()")
|
||||||
endmacro()
|
endmacro()
|
||||||
|
|
||||||
|
macro (OCCT_UPDATE_DRAW_DEFAULT_FILE)
|
||||||
|
install(CODE "cmake_policy(PUSH)
|
||||||
|
cmake_policy(SET CMP0007 NEW)
|
||||||
|
set (DRAW_DEFAULT_FILE_NAME \"${INSTALL_DIR}/${INSTALL_DIR_RESOURCE}/DrawResources/DrawPlugin\")
|
||||||
|
file (STRINGS \"\${DRAW_DEFAULT_FILE_NAME}\" DRAW_DEFAULT_CONTENT)
|
||||||
|
file (REMOVE \"\${DRAW_DEFAULT_FILE_NAME}\")
|
||||||
|
foreach (line IN LISTS DRAW_DEFAULT_CONTENT)
|
||||||
|
string (REGEX MATCH \": TK\([a-zA-Z]+\)$\" IS_TK_LINE \"\${line}\")
|
||||||
|
string (REGEX REPLACE \": TK\([a-zA-Z]+\)$\" \": TK\${CMAKE_MATCH_1}${BUILD_SHARED_LIBRARY_NAME_POSTFIX}\" line \"\${line}\")
|
||||||
|
file (APPEND \"\${DRAW_DEFAULT_FILE_NAME}\" \"\${line}\\n\")
|
||||||
|
endforeach()
|
||||||
|
cmake_policy(POP)")
|
||||||
|
endmacro()
|
||||||
|
|
||||||
|
macro (OCCT_CREATE_SYMLINK_TO_FILE LIBRARY_NAME LINK_NAME)
|
||||||
|
if (NOT WIN32)
|
||||||
|
install (CODE "if (EXISTS \"${LIBRARY_NAME}\")
|
||||||
|
execute_process (COMMAND ln -s \"${LIBRARY_NAME}\" \"${LINK_NAME}\")
|
||||||
|
endif()
|
||||||
|
")
|
||||||
|
endif()
|
||||||
|
endmacro()
|
||||||
|
77
adm/cmake/occt_resources.cmake
Normal file
@@ -0,0 +1,77 @@
|
|||||||
|
# OCCT resource files generation
|
||||||
|
|
||||||
|
macro (OCCT_GENERATE_CONTENT_ONLY CurrentResource)
|
||||||
|
set (RESOURCE_FILES)
|
||||||
|
set (isResDirectory FALSE)
|
||||||
|
if (IS_DIRECTORY "${CMAKE_SOURCE_DIR}/src/${CurrentResource}")
|
||||||
|
file (STRINGS "${CMAKE_SOURCE_DIR}/src/${CurrentResource}/FILES" RESOURCE_FILES)
|
||||||
|
set (CurrentResource_Directory "${CurrentResource}")
|
||||||
|
set (isResDirectory TRUE)
|
||||||
|
else()
|
||||||
|
get_filename_component (CurrentResource_Name "${CurrentResource}" NAME)
|
||||||
|
list (APPEND RESOURCE_FILES "res:::${CurrentResource_Name}")
|
||||||
|
get_filename_component (CurrentResource_Directory "${CurrentResource}" DIRECTORY)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
# Add current toolkit into RESOURCE_TOOLKITS array to copy it to the BUILD directory
|
||||||
|
list (APPEND RESOURCE_TOOLKITS "${CurrentResource_Directory}")
|
||||||
|
list (REMOVE_DUPLICATES RESOURCE_TOOLKITS)
|
||||||
|
|
||||||
|
if (BUILD_RESOURCES)
|
||||||
|
foreach (RESOURCE_FILE ${RESOURCE_FILES})
|
||||||
|
string (REGEX MATCH "^[^:]+:::" IS_RESOURCE "${RESOURCE_FILE}")
|
||||||
|
if (IS_RESOURCE)
|
||||||
|
string (REGEX REPLACE "[^:]+:+" "" RESOURCE_FILE "${RESOURCE_FILE}")
|
||||||
|
|
||||||
|
get_filename_component (CurrentResource_FileName "${RESOURCE_FILE}" NAME)
|
||||||
|
string (REPLACE "." "_" CurrentResource_FileName "${CurrentResource_FileName}")
|
||||||
|
set (HEADER_FILE_NAME "${CurrentResource_Directory}_${CurrentResource_FileName}.pxx")
|
||||||
|
|
||||||
|
set (toProcessResFile TRUE)
|
||||||
|
if (isResDirectory)
|
||||||
|
list (FIND RESOURCE_FILES "${HEADER_FILE_NAME}" aResIndex)
|
||||||
|
if ("${aResIndex}" STREQUAL "-1")
|
||||||
|
set (toProcessResFile FALSE)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (toProcessResFile)
|
||||||
|
message(STATUS "Info. Generating header file from resource file: ${CMAKE_SOURCE_DIR}/src/${CurrentResource_Directory}/${RESOURCE_FILE}")
|
||||||
|
|
||||||
|
# generate content for header file
|
||||||
|
set (OCCT_HEADER_FILE_CONTENT "// This file has been automatically generated from resource file src/${CurrentResource_Directory}/${RESOURCE_FILE}\n\n")
|
||||||
|
|
||||||
|
# read resource file
|
||||||
|
file (STRINGS "${CMAKE_SOURCE_DIR}/src/${CurrentResource_Directory}/${RESOURCE_FILE}" RESOURCE_FILE_LINES_LIST)
|
||||||
|
|
||||||
|
set (OCCT_HEADER_FILE_CONTENT "${OCCT_HEADER_FILE_CONTENT}static const char ${CurrentResource_Directory}_${CurrentResource_FileName}[] =")
|
||||||
|
foreach (line IN LISTS RESOURCE_FILE_LINES_LIST)
|
||||||
|
string (REPLACE "\"" "\\\"" line "${line}")
|
||||||
|
set (OCCT_HEADER_FILE_CONTENT "${OCCT_HEADER_FILE_CONTENT}\n \"${line}\\n\"")
|
||||||
|
endforeach()
|
||||||
|
set (OCCT_HEADER_FILE_CONTENT "${OCCT_HEADER_FILE_CONTENT};")
|
||||||
|
|
||||||
|
# Save generated content to header file
|
||||||
|
set (HEADER_FILE "${CMAKE_SOURCE_DIR}/src/${CurrentResource_Directory}/${HEADER_FILE_NAME}")
|
||||||
|
if (EXISTS "${HEADER_FILE}")
|
||||||
|
file (REMOVE "${HEADER_FILE}")
|
||||||
|
endif()
|
||||||
|
configure_file ("${CMAKE_SOURCE_DIR}/adm/templates/header.in" "${HEADER_FILE}" @ONLY NEWLINE_STYLE LF)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
endforeach()
|
||||||
|
endif()
|
||||||
|
endmacro()
|
||||||
|
|
||||||
|
|
||||||
|
FILE_TO_LIST ("adm/RESOURCES" RESOURCES)
|
||||||
|
foreach (CurrentResource ${RESOURCES})
|
||||||
|
get_filename_component (CurrentResource_FileName "${CurrentResource}" NAME)
|
||||||
|
if ("${CurrentResource_FileName}" STREQUAL TObj.msg OR
|
||||||
|
"${CurrentResource_FileName}" STREQUAL Units.dat OR
|
||||||
|
"${CurrentResource}" STREQUAL XSMessage OR
|
||||||
|
"${CurrentResource}" STREQUAL SHMessage OR
|
||||||
|
"${CurrentResource}" STREQUAL Shaders)
|
||||||
|
OCCT_GENERATE_CONTENT_ONLY ("${CurrentResource}")
|
||||||
|
endif()
|
||||||
|
endforeach()
|
@@ -9,6 +9,10 @@ endif()
|
|||||||
|
|
||||||
set (PRECOMPILED_DEFS)
|
set (PRECOMPILED_DEFS)
|
||||||
|
|
||||||
|
if (NOT BUILD_SHARED_LIBS)
|
||||||
|
list (APPEND PRECOMPILED_DEFS "-DOCCT_NO_PLUGINS")
|
||||||
|
endif()
|
||||||
|
|
||||||
# Get all used packages from toolkit
|
# Get all used packages from toolkit
|
||||||
foreach (OCCT_PACKAGE ${USED_PACKAGES})
|
foreach (OCCT_PACKAGE ${USED_PACKAGES})
|
||||||
|
|
||||||
@@ -143,25 +147,44 @@ if ("${PROJECT_NAME}" STREQUAL "DRAWEXE")
|
|||||||
add_executable (${PROJECT_NAME} ${USED_SRCFILES} ${USED_INCFILES} ${USED_RCFILE})
|
add_executable (${PROJECT_NAME} ${USED_SRCFILES} ${USED_INCFILES} ${USED_RCFILE})
|
||||||
|
|
||||||
install (TARGETS ${PROJECT_NAME}
|
install (TARGETS ${PROJECT_NAME}
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}\${OCCT_INSTALL_BIN_LETTER}")
|
DESTINATION "${INSTALL_DIR_BIN}\${OCCT_INSTALL_BIN_LETTER}")
|
||||||
else()
|
else()
|
||||||
add_library (${PROJECT_NAME} ${USED_SRCFILES} ${USED_INCFILES} ${USED_RCFILE})
|
add_library (${PROJECT_NAME} ${USED_SRCFILES} ${USED_INCFILES} ${USED_RCFILE})
|
||||||
|
|
||||||
if (MSVC)
|
if (MSVC)
|
||||||
install (FILES ${CMAKE_BINARY_DIR}/${OS_WITH_BIT}/${COMPILER}/bind/${PROJECT_NAME}.pdb
|
install (FILES ${CMAKE_BINARY_DIR}/${OS_WITH_BIT}/${COMPILER}/bind/${PROJECT_NAME}.pdb
|
||||||
CONFIGURATIONS Debug
|
CONFIGURATIONS Debug
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}\${OCCT_INSTALL_BIN_LETTER}")
|
DESTINATION "${INSTALL_DIR_BIN}\${OCCT_INSTALL_BIN_LETTER}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if (BUILD_SHARED_LIBS AND NOT "${BUILD_SHARED_LIBRARY_NAME_POSTFIX}" STREQUAL "")
|
||||||
|
set (CMAKE_SHARED_LIBRARY_SUFFIX_DEFAULT ${CMAKE_SHARED_LIBRARY_SUFFIX})
|
||||||
|
set (CMAKE_SHARED_LIBRARY_SUFFIX "${BUILD_SHARED_LIBRARY_NAME_POSTFIX}${CMAKE_SHARED_LIBRARY_SUFFIX}")
|
||||||
|
endif()
|
||||||
|
|
||||||
install (TARGETS ${PROJECT_NAME}
|
install (TARGETS ${PROJECT_NAME}
|
||||||
EXPORT OpenCASCADE${CURRENT_MODULE}Targets
|
EXPORT OpenCASCADE${CURRENT_MODULE}Targets
|
||||||
RUNTIME DESTINATION "${INSTALL_DIR_BIN}\${OCCT_INSTALL_BIN_LETTER}"
|
RUNTIME DESTINATION "${INSTALL_DIR_BIN}\${OCCT_INSTALL_BIN_LETTER}"
|
||||||
ARCHIVE DESTINATION "${INSTALL_DIR_LIB}\${OCCT_INSTALL_BIN_LETTER}"
|
ARCHIVE DESTINATION "${INSTALL_DIR_LIB}\${OCCT_INSTALL_BIN_LETTER}"
|
||||||
LIBRARY DESTINATION "${INSTALL_DIR_LIB}\${OCCT_INSTALL_BIN_LETTER}")
|
LIBRARY DESTINATION "${INSTALL_DIR_LIB}\${OCCT_INSTALL_BIN_LETTER}")
|
||||||
|
|
||||||
|
if (NOT WIN32)
|
||||||
|
if (BUILD_SHARED_LIBS AND NOT "${BUILD_SHARED_LIBRARY_NAME_POSTFIX}" STREQUAL "")
|
||||||
|
set (LINK_NAME "${INSTALL_DIR}/${INSTALL_DIR_LIB}\${OCCT_INSTALL_BIN_LETTER}/lib${PROJECT_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX_DEFAULT}")
|
||||||
|
set (LIBRARY_NAME "${INSTALL_DIR}/${INSTALL_DIR_LIB}\${OCCT_INSTALL_BIN_LETTER}/lib${PROJECT_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}")
|
||||||
|
OCCT_CREATE_SYMLINK_TO_FILE (${LIBRARY_NAME} ${LINK_NAME})
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (CURRENT_MODULE)
|
if (CURRENT_MODULE)
|
||||||
set_target_properties (${PROJECT_NAME} PROPERTIES FOLDER "Modules/${CURRENT_MODULE}")
|
set_target_properties (${PROJECT_NAME} PROPERTIES FOLDER "Modules/${CURRENT_MODULE}")
|
||||||
set_target_properties (${PROJECT_NAME} PROPERTIES MODULE "${CURRENT_MODULE}")
|
set_target_properties (${PROJECT_NAME} PROPERTIES MODULE "${CURRENT_MODULE}")
|
||||||
|
if (APPLE)
|
||||||
|
if (NOT "${INSTALL_NAME_DIR}" STREQUAL "")
|
||||||
|
set_target_properties (${PROJECT_NAME} PROPERTIES BUILD_WITH_INSTALL_RPATH 1 INSTALL_NAME_DIR "${INSTALL_NAME_DIR}")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
get_property (OCC_VERSION_MAJOR GLOBAL PROPERTY OCC_VERSION_MAJOR)
|
get_property (OCC_VERSION_MAJOR GLOBAL PROPERTY OCC_VERSION_MAJOR)
|
||||||
@@ -196,7 +219,7 @@ foreach (USED_ITEM ${USED_EXTERNLIB_AND_TOOLKITS})
|
|||||||
message (STATUS "Info: ${USED_ITEM} from ${PROJECT_NAME} skipped due to it is empty")
|
message (STATUS "Info: ${USED_ITEM} from ${PROJECT_NAME} skipped due to it is empty")
|
||||||
else() # get CSF_ value
|
else() # get CSF_ value
|
||||||
set (CURRENT_CSF ${${USED_ITEM}})
|
set (CURRENT_CSF ${${USED_ITEM}})
|
||||||
if (NOT "${CURRENT_CSF}" STREQUAL "")
|
if (NOT "x${CURRENT_CSF}" STREQUAL "x")
|
||||||
# prepare a list from a string with whitespaces
|
# prepare a list from a string with whitespaces
|
||||||
separate_arguments (CURRENT_CSF)
|
separate_arguments (CURRENT_CSF)
|
||||||
list (APPEND USED_EXTERNAL_LIBS_BY_CURRENT_PROJECT ${CURRENT_CSF})
|
list (APPEND USED_EXTERNAL_LIBS_BY_CURRENT_PROJECT ${CURRENT_CSF})
|
||||||
@@ -216,4 +239,21 @@ if (APPLE)
|
|||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
target_link_libraries (${PROJECT_NAME} ${USED_TOOLKITS_BY_CURRENT_PROJECT} ${USED_EXTERNAL_LIBS_BY_CURRENT_PROJECT})
|
# Update list of used VTK libraries if OpenGL2 Rendering BackEnd is used.
|
||||||
|
# Add VTK_OPENGL2_BACKEND definition.
|
||||||
|
if("${VTK_RENDERING_BACKEND}" STREQUAL "OpenGL2")
|
||||||
|
add_definitions(-DVTK_OPENGL2_BACKEND)
|
||||||
|
foreach (VTK_EXCLUDE_LIBRARY vtkRenderingOpenGL vtkRenderingFreeTypeOpenGL)
|
||||||
|
list (FIND USED_TOOLKITS_BY_CURRENT_PROJECT "${VTK_EXCLUDE_LIBRARY}" IS_VTK_OPENGL_FOUND)
|
||||||
|
if (NOT ${IS_VTK_OPENGL_FOUND} EQUAL -1)
|
||||||
|
list (REMOVE_ITEM USED_TOOLKITS_BY_CURRENT_PROJECT ${VTK_EXCLUDE_LIBRARY})
|
||||||
|
if (${VTK_EXCLUDE_LIBRARY} STREQUAL vtkRenderingOpenGL)
|
||||||
|
list (APPEND USED_TOOLKITS_BY_CURRENT_PROJECT vtkRenderingOpenGL2)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
endforeach()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (BUILD_SHARED_LIBS)
|
||||||
|
target_link_libraries (${PROJECT_NAME} ${USED_TOOLKITS_BY_CURRENT_PROJECT} ${USED_EXTERNAL_LIBS_BY_CURRENT_PROJECT})
|
||||||
|
endif()
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
# tbb
|
# tbb
|
||||||
|
|
||||||
if (NOT DEFINED INSTALL_TBB)
|
if (NOT DEFINED INSTALL_TBB AND BUILD_SHARED_LIBS)
|
||||||
set (INSTALL_TBB OFF CACHE BOOL "${INSTALL_TBB_DESCR}")
|
set (INSTALL_TBB OFF CACHE BOOL "${INSTALL_TBB_DESCR}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -9,7 +9,7 @@ if (NOT DEFINED 3RDPARTY_TBB_DIR)
|
|||||||
set (3RDPARTY_TBB_DIR "" CACHE PATH "The directory containing tbb")
|
set (3RDPARTY_TBB_DIR "" CACHE PATH "The directory containing tbb")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (MSVC)
|
if (MSVC AND BUILD_SHARED_LIBS)
|
||||||
add_definitions (-D__TBB_NO_IMPLICIT_LINKAGE)
|
add_definitions (-D__TBB_NO_IMPLICIT_LINKAGE)
|
||||||
add_definitions (-D__TBBMALLOC_NO_IMPLICIT_LINKAGE)
|
add_definitions (-D__TBBMALLOC_NO_IMPLICIT_LINKAGE)
|
||||||
endif()
|
endif()
|
||||||
@@ -129,7 +129,7 @@ macro (TBB_PRODUCT_SEARCH PRODUCT_NAME)
|
|||||||
# tbb/tbbmalloc library
|
# tbb/tbbmalloc library
|
||||||
if (NOT 3RDPARTY_${PRODUCT_NAME}_LIBRARY OR NOT EXISTS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY}")
|
if (NOT 3RDPARTY_${PRODUCT_NAME}_LIBRARY OR NOT EXISTS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY}")
|
||||||
|
|
||||||
set (CMAKE_FIND_LIBRARY_SUFFIXES .lib .so .dylib)
|
set (CMAKE_FIND_LIBRARY_SUFFIXES .lib .so .dylib .a)
|
||||||
set (PRODUCT_PATH_SUFFIXES lib ${lower_PRODUCT_NAME})
|
set (PRODUCT_PATH_SUFFIXES lib ${lower_PRODUCT_NAME})
|
||||||
|
|
||||||
# set 3RDPARTY_${PRODUCT_NAME}_LIBRARY as notfound, otherwise find_library can't assign a new value to 3RDPARTY_${PRODUCT_NAME}_LIBRARY
|
# set 3RDPARTY_${PRODUCT_NAME}_LIBRARY as notfound, otherwise find_library can't assign a new value to 3RDPARTY_${PRODUCT_NAME}_LIBRARY
|
||||||
@@ -231,43 +231,43 @@ macro (TBB_PRODUCT_SEARCH PRODUCT_NAME)
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
# install tbb/tbbmalloc
|
# install tbb/tbbmalloc
|
||||||
if (INSTALL_${PRODUCT_NAME})
|
if (INSTALL_TBB)
|
||||||
OCCT_MAKE_OS_WITH_BITNESS()
|
OCCT_MAKE_OS_WITH_BITNESS()
|
||||||
OCCT_MAKE_COMPILER_SHORT_NAME()
|
OCCT_MAKE_COMPILER_SHORT_NAME()
|
||||||
|
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
if (SINGLE_GENERATOR)
|
if (SINGLE_GENERATOR)
|
||||||
install (FILES ${3RDPARTY_${PRODUCT_NAME}_DLL} DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}")
|
install (FILES ${3RDPARTY_${PRODUCT_NAME}_DLL} DESTINATION "${INSTALL_DIR_BIN}")
|
||||||
else()
|
else()
|
||||||
install (FILES ${3RDPARTY_${PRODUCT_NAME}_DLL}
|
install (FILES ${3RDPARTY_${PRODUCT_NAME}_DLL}
|
||||||
CONFIGURATIONS Release
|
CONFIGURATIONS Release
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}")
|
DESTINATION "${INSTALL_DIR_BIN}")
|
||||||
install (FILES ${3RDPARTY_${PRODUCT_NAME}_DLL}
|
install (FILES ${3RDPARTY_${PRODUCT_NAME}_DLL}
|
||||||
CONFIGURATIONS RelWithDebInfo
|
CONFIGURATIONS RelWithDebInfo
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}i")
|
DESTINATION "${INSTALL_DIR_BIN}i")
|
||||||
install (FILES ${3RDPARTY_${PRODUCT_NAME}_DLL}
|
install (FILES ${3RDPARTY_${PRODUCT_NAME}_DLL}
|
||||||
CONFIGURATIONS Debug
|
CONFIGURATIONS Debug
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}d")
|
DESTINATION "${INSTALL_DIR_BIN}d")
|
||||||
endif()
|
endif()
|
||||||
else()
|
else()
|
||||||
get_filename_component (PRODUCT_LIBRARY_NAME ${3RDPARTY_${PRODUCT_NAME}_LIBRARY} NAME)
|
get_filename_component (PRODUCT_LIBRARY_NAME ${3RDPARTY_${PRODUCT_NAME}_LIBRARY} NAME)
|
||||||
|
|
||||||
if (SINGLE_GENERATOR)
|
if (SINGLE_GENERATOR)
|
||||||
install (FILES ${3RDPARTY_${PRODUCT_NAME}_LIBRARY}.2
|
install (FILES ${3RDPARTY_${PRODUCT_NAME}_LIBRARY}.2
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}"
|
DESTINATION "${INSTALL_DIR_LIB}"
|
||||||
RENAME ${PRODUCT_LIBRARY_NAME}.2)
|
RENAME ${PRODUCT_LIBRARY_NAME}.2)
|
||||||
else()
|
else()
|
||||||
install (FILES ${3RDPARTY_${PRODUCT_NAME}_LIBRARY}.2
|
install (FILES ${3RDPARTY_${PRODUCT_NAME}_LIBRARY}.2
|
||||||
CONFIGURATIONS Release
|
CONFIGURATIONS Release
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}"
|
DESTINATION "${INSTALL_DIR_LIB}"
|
||||||
RENAME ${PRODUCT_LIBRARY_NAME}.2)
|
RENAME ${PRODUCT_LIBRARY_NAME}.2)
|
||||||
install (FILES ${3RDPARTY_${PRODUCT_NAME}_LIBRARY}.2
|
install (FILES ${3RDPARTY_${PRODUCT_NAME}_LIBRARY}.2
|
||||||
CONFIGURATIONS RelWithDebInfo
|
CONFIGURATIONS RelWithDebInfo
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}i"
|
DESTINATION "${INSTALL_DIR_LIB}i"
|
||||||
RENAME ${PRODUCT_LIBRARY_NAME}.2)
|
RENAME ${PRODUCT_LIBRARY_NAME}.2)
|
||||||
install (FILES ${3RDPARTY_${PRODUCT_NAME}_LIBRARY}.2
|
install (FILES ${3RDPARTY_${PRODUCT_NAME}_LIBRARY}.2
|
||||||
CONFIGURATIONS Debug
|
CONFIGURATIONS Debug
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}d"
|
DESTINATION "${INSTALL_DIR_LIB}d"
|
||||||
RENAME ${PRODUCT_LIBRARY_NAME}.2)
|
RENAME ${PRODUCT_LIBRARY_NAME}.2)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
@@ -275,18 +275,18 @@ macro (TBB_PRODUCT_SEARCH PRODUCT_NAME)
|
|||||||
mark_as_advanced (3RDPARTY_${PRODUCT_NAME}_LIBRARY 3RDPARTY_${PRODUCT_NAME}_DLL)
|
mark_as_advanced (3RDPARTY_${PRODUCT_NAME}_LIBRARY 3RDPARTY_${PRODUCT_NAME}_DLL)
|
||||||
endmacro()
|
endmacro()
|
||||||
|
|
||||||
|
if (BUILD_SHARED_LIBS)
|
||||||
|
TBB_PRODUCT_SEARCH (TBB)
|
||||||
|
TBB_PRODUCT_SEARCH (TBBMALLOC)
|
||||||
|
|
||||||
TBB_PRODUCT_SEARCH (TBB)
|
if (INSTALL_TBB)
|
||||||
TBB_PRODUCT_SEARCH (TBBMALLOC)
|
set (USED_3RDPARTY_TBB_DIR "")
|
||||||
|
|
||||||
|
|
||||||
if (INSTALL_TBB)
|
|
||||||
set (USED_3RDPARTY_TBB_DIR "")
|
|
||||||
else()
|
|
||||||
# the library directory for using by the executable
|
|
||||||
if (WIN32)
|
|
||||||
set (USED_3RDPARTY_TBB_DIR ${3RDPARTY_TBB_DLL_DIR})
|
|
||||||
else()
|
else()
|
||||||
set (USED_3RDPARTY_TBB_DIR ${3RDPARTY_TBB_LIBRARY_DIR})
|
# the library directory for using by the executable
|
||||||
|
if (WIN32)
|
||||||
|
set (USED_3RDPARTY_TBB_DIR ${3RDPARTY_TBB_DLL_DIR})
|
||||||
|
else()
|
||||||
|
set (USED_3RDPARTY_TBB_DIR ${3RDPARTY_TBB_LIBRARY_DIR})
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
@@ -1,6 +1,6 @@
|
|||||||
# tcl
|
# tcl
|
||||||
|
|
||||||
if (NOT DEFINED INSTALL_TCL)
|
if (NOT DEFINED INSTALL_TCL AND BUILD_SHARED_LIBS)
|
||||||
set (INSTALL_TCL OFF CACHE BOOL "${INSTALL_TCL_DESCR}")
|
set (INSTALL_TCL OFF CACHE BOOL "${INSTALL_TCL_DESCR}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -14,26 +14,28 @@ if (NOT DEFINED 3RDPARTY_TCL_INCLUDE_DIR)
|
|||||||
set (3RDPARTY_TCL_INCLUDE_DIR "" CACHE FILEPATH "The directory containing headers of tcl")
|
set (3RDPARTY_TCL_INCLUDE_DIR "" CACHE FILEPATH "The directory containing headers of tcl")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# tcl library file (with absolute path)
|
if (BUILD_SHARED_LIBS)
|
||||||
if (NOT DEFINED 3RDPARTY_TCL_LIBRARY OR NOT 3RDPARTY_TCL_LIBRARY_DIR)
|
# tcl library file (with absolute path)
|
||||||
set (3RDPARTY_TCL_LIBRARY "" CACHE FILEPATH "tcl library" FORCE)
|
if (NOT DEFINED 3RDPARTY_TCL_LIBRARY OR NOT 3RDPARTY_TCL_LIBRARY_DIR)
|
||||||
endif()
|
set (3RDPARTY_TCL_LIBRARY "" CACHE FILEPATH "tcl library" FORCE)
|
||||||
|
|
||||||
# tcl library directory
|
|
||||||
if (NOT DEFINED 3RDPARTY_TCL_LIBRARY_DIR)
|
|
||||||
set (3RDPARTY_TCL_LIBRARY_DIR "" CACHE FILEPATH "The directory containing tcl library")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# tcl shared library (with absolute path)
|
|
||||||
if (WIN32)
|
|
||||||
if (NOT DEFINED 3RDPARTY_TCL_DLL OR NOT 3RDPARTY_TCL_DLL_DIR)
|
|
||||||
set (3RDPARTY_TCL_DLL "" CACHE FILEPATH "tcl shared library" FORCE)
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
# tcl shared library directory
|
# tcl library directory
|
||||||
if (WIN32 AND NOT DEFINED 3RDPARTY_TCL_DLL_DIR)
|
if (NOT DEFINED 3RDPARTY_TCL_LIBRARY_DIR)
|
||||||
set (3RDPARTY_TCL_DLL_DIR "" CACHE FILEPATH "The directory containing tcl shared library")
|
set (3RDPARTY_TCL_LIBRARY_DIR "" CACHE FILEPATH "The directory containing tcl library")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
# tcl shared library (with absolute path)
|
||||||
|
if (WIN32)
|
||||||
|
if (NOT DEFINED 3RDPARTY_TCL_DLL OR NOT 3RDPARTY_TCL_DLL_DIR)
|
||||||
|
set (3RDPARTY_TCL_DLL "" CACHE FILEPATH "tcl shared library" FORCE)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
# tcl shared library directory
|
||||||
|
if (WIN32 AND NOT DEFINED 3RDPARTY_TCL_DLL_DIR)
|
||||||
|
set (3RDPARTY_TCL_DLL_DIR "" CACHE FILEPATH "The directory containing tcl shared library")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# search for tcl in user defined directory
|
# search for tcl in user defined directory
|
||||||
@@ -53,7 +55,7 @@ endif()
|
|||||||
COMPLIANCE_PRODUCT_CONSISTENCY(TCL)
|
COMPLIANCE_PRODUCT_CONSISTENCY(TCL)
|
||||||
|
|
||||||
# use default (CMake) TCL search
|
# use default (CMake) TCL search
|
||||||
find_package(TCL)
|
find_package(TCL QUIET)
|
||||||
|
|
||||||
# tcl include dir
|
# tcl include dir
|
||||||
if (NOT 3RDPARTY_TCL_INCLUDE_DIR)
|
if (NOT 3RDPARTY_TCL_INCLUDE_DIR)
|
||||||
@@ -62,199 +64,203 @@ if (NOT 3RDPARTY_TCL_INCLUDE_DIR)
|
|||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# tcl dir and library
|
if (BUILD_SHARED_LIBS)
|
||||||
if (NOT 3RDPARTY_TCL_LIBRARY)
|
# tcl dir and library
|
||||||
if (TCL_LIBRARY AND EXISTS "${TCL_LIBRARY}")
|
if (NOT 3RDPARTY_TCL_LIBRARY)
|
||||||
set (3RDPARTY_TCL_LIBRARY "${TCL_LIBRARY}" CACHE FILEPATH "TCL library" FORCE)
|
if (TCL_LIBRARY AND EXISTS "${TCL_LIBRARY}")
|
||||||
|
set (3RDPARTY_TCL_LIBRARY "${TCL_LIBRARY}" CACHE FILEPATH "TCL library" FORCE)
|
||||||
|
|
||||||
if (NOT 3RDPARTY_TCL_LIBRARY_DIR)
|
if (NOT 3RDPARTY_TCL_LIBRARY_DIR)
|
||||||
get_filename_component (3RDPARTY_TCL_LIBRARY_DIR "${3RDPARTY_TCL_LIBRARY}" PATH)
|
get_filename_component (3RDPARTY_TCL_LIBRARY_DIR "${3RDPARTY_TCL_LIBRARY}" PATH)
|
||||||
set (3RDPARTY_TCL_LIBRARY_DIR "${3RDPARTY_TCL_LIBRARY_DIR}" CACHE FILEPATH "The directory containing TCL library" FORCE)
|
set (3RDPARTY_TCL_LIBRARY_DIR "${3RDPARTY_TCL_LIBRARY_DIR}" CACHE FILEPATH "The directory containing TCL library" FORCE)
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
|
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
if (NOT 3RDPARTY_TCL_DLL)
|
if (NOT 3RDPARTY_TCL_DLL)
|
||||||
set (CMAKE_FIND_LIBRARY_SUFFIXES .lib .dll)
|
set (CMAKE_FIND_LIBRARY_SUFFIXES .lib .dll .a)
|
||||||
|
|
||||||
set (DLL_FOLDER_FOR_SEARCH "")
|
set (DLL_FOLDER_FOR_SEARCH "")
|
||||||
if (3RDPARTY_TCL_DLL_DIR)
|
if (3RDPARTY_TCL_DLL_DIR)
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_DLL_DIR}")
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_DLL_DIR}")
|
||||||
elseif (3RDPARTY_TCL_DIR)
|
elseif (3RDPARTY_TCL_DIR)
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_DIR}/bin")
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_DIR}/bin")
|
||||||
elseif (3RDPARTY_TCL_LIBRARY_DIR)
|
elseif (3RDPARTY_TCL_LIBRARY_DIR)
|
||||||
get_filename_component (3RDPARTY_TCL_LIBRARY_DIR_PARENT "${3RDPARTY_TCL_LIBRARY_DIR}" PATH)
|
get_filename_component (3RDPARTY_TCL_LIBRARY_DIR_PARENT "${3RDPARTY_TCL_LIBRARY_DIR}" PATH)
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_LIBRARY_DIR_PARENT}/bin")
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_LIBRARY_DIR_PARENT}/bin")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
set (3RDPARTY_TCL_DLL "3RDPARTY_TCL_DLL-NOTFOUND" CACHE FILEPATH "TCL shared library" FORCE)
|
||||||
|
find_library (3RDPARTY_TCL_DLL NAMES tcl86 tcl85
|
||||||
|
PATHS "${DLL_FOLDER_FOR_SEARCH}"
|
||||||
|
NO_DEFAULT_PATH)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set (3RDPARTY_TCL_DLL "3RDPARTY_TCL_DLL-NOTFOUND" CACHE FILEPATH "TCL shared library" FORCE)
|
|
||||||
find_library (3RDPARTY_TCL_DLL NAMES tcl86 tcl85
|
|
||||||
PATHS "${DLL_FOLDER_FOR_SEARCH}"
|
|
||||||
NO_DEFAULT_PATH)
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
COMPLIANCE_PRODUCT_CONSISTENCY(TCL)
|
COMPLIANCE_PRODUCT_CONSISTENCY(TCL)
|
||||||
|
|
||||||
# tcl dir and library
|
if (BUILD_SHARED_LIBS)
|
||||||
if (NOT 3RDPARTY_TCL_LIBRARY)
|
# tcl dir and library
|
||||||
set (3RDPARTY_TCL_LIBRARY "3RDPARTY_TCL_LIBRARY-NOTFOUND" CACHE FILEPATH "TCL library" FORCE)
|
if (NOT 3RDPARTY_TCL_LIBRARY)
|
||||||
find_library (3RDPARTY_TCL_LIBRARY NAMES tcl8.6 tcl86 tcl8.5 tcl85
|
set (3RDPARTY_TCL_LIBRARY "3RDPARTY_TCL_LIBRARY-NOTFOUND" CACHE FILEPATH "TCL library" FORCE)
|
||||||
PATHS "${3RDPARTY_TCL_LIBRARY_DIR}"
|
find_library (3RDPARTY_TCL_LIBRARY NAMES tcl8.6 tcl86 tcl8.5 tcl85
|
||||||
NO_DEFAULT_PATH)
|
PATHS "${3RDPARTY_TCL_LIBRARY_DIR}"
|
||||||
|
NO_DEFAULT_PATH)
|
||||||
|
|
||||||
# search in another place if previous search doesn't find anything
|
# search in another place if previous search doesn't find anything
|
||||||
find_library (3RDPARTY_TCL_LIBRARY NAMES tcl8.6 tcl86 tcl8.5 tcl85
|
find_library (3RDPARTY_TCL_LIBRARY NAMES tcl8.6 tcl86 tcl8.5 tcl85
|
||||||
PATHS "${3RDPARTY_TCL_DIR}/lib"
|
PATHS "${3RDPARTY_TCL_DIR}/lib"
|
||||||
NO_DEFAULT_PATH)
|
NO_DEFAULT_PATH)
|
||||||
|
|
||||||
|
|
||||||
if (NOT 3RDPARTY_TCL_LIBRARY OR NOT EXISTS "${3RDPARTY_TCL_LIBRARY}")
|
if (NOT 3RDPARTY_TCL_LIBRARY OR NOT EXISTS "${3RDPARTY_TCL_LIBRARY}")
|
||||||
set (3RDPARTY_TCL_LIBRARY "" CACHE FILEPATH "TCL library" FORCE)
|
set (3RDPARTY_TCL_LIBRARY "" CACHE FILEPATH "TCL library" FORCE)
|
||||||
endif()
|
|
||||||
|
|
||||||
if (NOT 3RDPARTY_TCL_LIBRARY_DIR AND 3RDPARTY_TCL_LIBRARY)
|
|
||||||
get_filename_component (3RDPARTY_TCL_LIBRARY_DIR "${3RDPARTY_TCL_LIBRARY}" PATH)
|
|
||||||
set (3RDPARTY_TCL_LIBRARY_DIR "${3RDPARTY_TCL_LIBRARY_DIR}" CACHE FILEPATH "The directory containing TCL library" FORCE)
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
set (3RDPARTY_TCL_LIBRARY_VERSION "")
|
|
||||||
if (3RDPARTY_TCL_LIBRARY AND EXISTS "${3RDPARTY_TCL_LIBRARY}")
|
|
||||||
get_filename_component (TCL_LIBRARY_NAME "${3RDPARTY_TCL_LIBRARY}" NAME)
|
|
||||||
string(REGEX REPLACE "^.*tcl([0-9]\\.*[0-9]).*$" "\\1" TCL_LIBRARY_VERSION "${TCL_LIBRARY_NAME}")
|
|
||||||
|
|
||||||
if (NOT "${TCL_LIBRARY_VERSION}" STREQUAL "${TCL_LIBRARY_NAME}")
|
|
||||||
set (3RDPARTY_TCL_LIBRARY_VERSION "${TCL_LIBRARY_VERSION}")
|
|
||||||
else() # if the version isn't found - seek other library with 8.6 or 8.5 version in the same dir
|
|
||||||
message (STATUS "Info: TCL version isn't found")
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
set (3RDPARTY_TCL_LIBRARY_VERSION_WITH_DOT "")
|
|
||||||
if (3RDPARTY_TCL_LIBRARY_VERSION)
|
|
||||||
string (REGEX REPLACE "^.*([0-9])[^0-9]*[0-9].*$" "\\1" 3RDPARTY_TCL_MAJOR_VERSION "${3RDPARTY_TCL_LIBRARY_VERSION}")
|
|
||||||
string (REGEX REPLACE "^.*[0-9][^0-9]*([0-9]).*$" "\\1" 3RDPARTY_TCL_MINOR_VERSION "${3RDPARTY_TCL_LIBRARY_VERSION}")
|
|
||||||
set (3RDPARTY_TCL_LIBRARY_VERSION_WITH_DOT "${3RDPARTY_TCL_MAJOR_VERSION}.${3RDPARTY_TCL_MINOR_VERSION}")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (WIN32)
|
|
||||||
if (NOT 3RDPARTY_TCL_DLL)
|
|
||||||
set (CMAKE_FIND_LIBRARY_SUFFIXES .lib .dll)
|
|
||||||
|
|
||||||
set (DLL_FOLDER_FOR_SEARCH "")
|
|
||||||
if (3RDPARTY_TCL_DLL_DIR)
|
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_DLL_DIR}")
|
|
||||||
elseif (3RDPARTY_TCL_DIR)
|
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_DIR}/bin")
|
|
||||||
else()
|
|
||||||
get_filename_component (3RDPARTY_TCL_LIBRARY_DIR_PARENT "${3RDPARTY_TCL_LIBRARY_DIR}" PATH)
|
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_LIBRARY_DIR_PARENT}/bin")
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set (3RDPARTY_TCL_DLL "3RDPARTY_TCL_DLL-NOTFOUND" CACHE FILEPATH "TCL shared library" FORCE)
|
if (NOT 3RDPARTY_TCL_LIBRARY_DIR AND 3RDPARTY_TCL_LIBRARY)
|
||||||
find_library (3RDPARTY_TCL_DLL NAMES tcl${3RDPARTY_TCL_LIBRARY_VERSION}
|
get_filename_component (3RDPARTY_TCL_LIBRARY_DIR "${3RDPARTY_TCL_LIBRARY}" PATH)
|
||||||
PATHS "${DLL_FOLDER_FOR_SEARCH}"
|
set (3RDPARTY_TCL_LIBRARY_DIR "${3RDPARTY_TCL_LIBRARY_DIR}" CACHE FILEPATH "The directory containing TCL library" FORCE)
|
||||||
NO_DEFAULT_PATH)
|
|
||||||
|
|
||||||
if (NOT 3RDPARTY_TCL_DLL OR NOT EXISTS "${3RDPARTY_TCL_DLL}")
|
|
||||||
set (3RDPARTY_TCL_DLL "" CACHE FILEPATH "TCL shared library" FORCE)
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
if (NOT 3RDPARTY_TCL_DLL_DIR AND 3RDPARTY_TCL_DLL)
|
|
||||||
get_filename_component (3RDPARTY_TCL_DLL_DIR "${3RDPARTY_TCL_DLL}" PATH)
|
set (3RDPARTY_TCL_LIBRARY_VERSION "")
|
||||||
set (3RDPARTY_TCL_DLL_DIR "${3RDPARTY_TCL_DLL_DIR}" CACHE FILEPATH "The directory containing TCL shared library" FORCE)
|
if (3RDPARTY_TCL_LIBRARY AND EXISTS "${3RDPARTY_TCL_LIBRARY}")
|
||||||
|
get_filename_component (TCL_LIBRARY_NAME "${3RDPARTY_TCL_LIBRARY}" NAME)
|
||||||
|
string(REGEX REPLACE "^.*tcl([0-9]\\.*[0-9]).*$" "\\1" TCL_LIBRARY_VERSION "${TCL_LIBRARY_NAME}")
|
||||||
|
|
||||||
|
if (NOT "${TCL_LIBRARY_VERSION}" STREQUAL "${TCL_LIBRARY_NAME}")
|
||||||
|
set (3RDPARTY_TCL_LIBRARY_VERSION "${TCL_LIBRARY_VERSION}")
|
||||||
|
else() # if the version isn't found - seek other library with 8.6 or 8.5 version in the same dir
|
||||||
|
message (STATUS "Info: TCL version isn't found")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
# include found paths to common variables
|
set (3RDPARTY_TCL_LIBRARY_VERSION_WITH_DOT "")
|
||||||
if (3RDPARTY_TCL_INCLUDE_DIR AND EXISTS "${3RDPARTY_TCL_INCLUDE_DIR}")
|
if (3RDPARTY_TCL_LIBRARY_VERSION)
|
||||||
list (APPEND 3RDPARTY_INCLUDE_DIRS "${3RDPARTY_TCL_INCLUDE_DIR}")
|
string (REGEX REPLACE "^.*([0-9])[^0-9]*[0-9].*$" "\\1" 3RDPARTY_TCL_MAJOR_VERSION "${3RDPARTY_TCL_LIBRARY_VERSION}")
|
||||||
else()
|
string (REGEX REPLACE "^.*[0-9][^0-9]*([0-9]).*$" "\\1" 3RDPARTY_TCL_MINOR_VERSION "${3RDPARTY_TCL_LIBRARY_VERSION}")
|
||||||
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_TCL_INCLUDE_DIR)
|
set (3RDPARTY_TCL_LIBRARY_VERSION_WITH_DOT "${3RDPARTY_TCL_MAJOR_VERSION}.${3RDPARTY_TCL_MINOR_VERSION}")
|
||||||
endif()
|
|
||||||
|
|
||||||
if (3RDPARTY_TCL_LIBRARY AND EXISTS "${3RDPARTY_TCL_LIBRARY}")
|
|
||||||
list (APPEND 3RDPARTY_LIBRARY_DIRS "${3RDPARTY_TCL_LIBRARY_DIR}")
|
|
||||||
else()
|
|
||||||
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_TCL_LIBRARY_DIR})
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (WIN32)
|
|
||||||
if (3RDPARTY_TCL_DLL OR EXISTS "${3RDPARTY_TCL_DLL}")
|
|
||||||
list (APPEND 3RDPARTY_DLL_DIRS "${3RDPARTY_TCL_DLL_DIR}")
|
|
||||||
else()
|
|
||||||
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_TCL_DLL_DIR)
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
# install tcl
|
|
||||||
if (INSTALL_TCL)
|
|
||||||
# include occt macros. compiler_bitness, os_wiht_bit, compiler
|
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/occt_macros")
|
|
||||||
|
|
||||||
OCCT_MAKE_OS_WITH_BITNESS()
|
|
||||||
OCCT_MAKE_COMPILER_SHORT_NAME()
|
|
||||||
|
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
# tcl 8.6 requires zlib. install all dlls from tcl bin folder that may contain zlib also
|
if (NOT 3RDPARTY_TCL_DLL)
|
||||||
|
set (CMAKE_FIND_LIBRARY_SUFFIXES .lib .dll .a)
|
||||||
|
|
||||||
# collect and install all dlls from tcl dll dirs
|
set (DLL_FOLDER_FOR_SEARCH "")
|
||||||
file (GLOB TCL_DLLS "${3RDPARTY_TCL_DLL_DIR}/*.dll")
|
if (3RDPARTY_TCL_DLL_DIR)
|
||||||
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_DLL_DIR}")
|
||||||
|
elseif (3RDPARTY_TCL_DIR)
|
||||||
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_DIR}/bin")
|
||||||
|
else()
|
||||||
|
get_filename_component (3RDPARTY_TCL_LIBRARY_DIR_PARENT "${3RDPARTY_TCL_LIBRARY_DIR}" PATH)
|
||||||
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_LIBRARY_DIR_PARENT}/bin")
|
||||||
|
endif()
|
||||||
|
|
||||||
if (SINGLE_GENERATOR)
|
set (3RDPARTY_TCL_DLL "3RDPARTY_TCL_DLL-NOTFOUND" CACHE FILEPATH "TCL shared library" FORCE)
|
||||||
install (FILES ${TCL_DLLS} DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}")
|
find_library (3RDPARTY_TCL_DLL NAMES tcl${3RDPARTY_TCL_LIBRARY_VERSION}
|
||||||
else()
|
PATHS "${DLL_FOLDER_FOR_SEARCH}"
|
||||||
install (FILES ${TCL_DLLS}
|
NO_DEFAULT_PATH)
|
||||||
CONFIGURATIONS Release
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}")
|
if (NOT 3RDPARTY_TCL_DLL OR NOT EXISTS "${3RDPARTY_TCL_DLL}")
|
||||||
install (FILES ${TCL_DLLS}
|
set (3RDPARTY_TCL_DLL "" CACHE FILEPATH "TCL shared library" FORCE)
|
||||||
CONFIGURATIONS RelWithDebInfo
|
endif()
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}i")
|
|
||||||
install (FILES ${TCL_DLLS}
|
|
||||||
CONFIGURATIONS Debug
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}d")
|
|
||||||
endif()
|
endif()
|
||||||
else()
|
if (NOT 3RDPARTY_TCL_DLL_DIR AND 3RDPARTY_TCL_DLL)
|
||||||
get_filename_component(3RDPARTY_TCL_LIBRARY_REALPATH ${3RDPARTY_TCL_LIBRARY} REALPATH)
|
get_filename_component (3RDPARTY_TCL_DLL_DIR "${3RDPARTY_TCL_DLL}" PATH)
|
||||||
|
set (3RDPARTY_TCL_DLL_DIR "${3RDPARTY_TCL_DLL_DIR}" CACHE FILEPATH "The directory containing TCL shared library" FORCE)
|
||||||
if (SINGLE_GENERATOR)
|
|
||||||
install (FILES ${3RDPARTY_TCL_LIBRARY_REALPATH} DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}")
|
|
||||||
else()
|
|
||||||
install (FILES ${3RDPARTY_TCL_LIBRARY_REALPATH}
|
|
||||||
CONFIGURATIONS Release
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}")
|
|
||||||
install (FILES ${3RDPARTY_TCL_LIBRARY_REALPATH}
|
|
||||||
CONFIGURATIONS RelWithDebInfo
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}i")
|
|
||||||
install (FILES ${3RDPARTY_TCL_LIBRARY_REALPATH}
|
|
||||||
CONFIGURATIONS Debug
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}d")
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (TCL_TCLSH_VERSION)
|
# include found paths to common variables
|
||||||
# tcl is required to install in lib folder (without)
|
if (3RDPARTY_TCL_INCLUDE_DIR AND EXISTS "${3RDPARTY_TCL_INCLUDE_DIR}")
|
||||||
install (DIRECTORY "${3RDPARTY_TCL_LIBRARY_DIR}/tcl8" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}")
|
list (APPEND 3RDPARTY_INCLUDE_DIRS "${3RDPARTY_TCL_INCLUDE_DIR}")
|
||||||
install (DIRECTORY "${3RDPARTY_TCL_LIBRARY_DIR}/tcl${TCL_TCLSH_VERSION}" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}")
|
|
||||||
else()
|
else()
|
||||||
message (STATUS "\nWarning: tclX.X subdir won't be copyied during the installation process.")
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_TCL_INCLUDE_DIR)
|
||||||
message (STATUS "Try seeking tcl within another folder by changing 3RDPARTY_TCL_DIR variable.")
|
endif()
|
||||||
|
|
||||||
|
if (3RDPARTY_TCL_LIBRARY AND EXISTS "${3RDPARTY_TCL_LIBRARY}")
|
||||||
|
list (APPEND 3RDPARTY_LIBRARY_DIRS "${3RDPARTY_TCL_LIBRARY_DIR}")
|
||||||
|
else()
|
||||||
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_TCL_LIBRARY_DIR})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set (USED_3RDPARTY_TCL_DIR "")
|
|
||||||
else()
|
|
||||||
# the library directory for using by the executable
|
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
set (USED_3RDPARTY_TCL_DIR ${3RDPARTY_TCL_DLL_DIR})
|
if (3RDPARTY_TCL_DLL OR EXISTS "${3RDPARTY_TCL_DLL}")
|
||||||
else()
|
list (APPEND 3RDPARTY_DLL_DIRS "${3RDPARTY_TCL_DLL_DIR}")
|
||||||
set (USED_3RDPARTY_TCL_DIR ${3RDPARTY_TCL_LIBRARY_DIR})
|
else()
|
||||||
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_TCL_DLL_DIR)
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
mark_as_advanced (3RDPARTY_TCL_LIBRARY 3RDPARTY_TCL_DLL)
|
# install tcl
|
||||||
|
if (INSTALL_TCL)
|
||||||
|
# include occt macros. compiler_bitness, os_wiht_bit, compiler
|
||||||
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/occt_macros")
|
||||||
|
|
||||||
|
OCCT_MAKE_OS_WITH_BITNESS()
|
||||||
|
OCCT_MAKE_COMPILER_SHORT_NAME()
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
# tcl 8.6 requires zlib. install all dlls from tcl bin folder that may contain zlib also
|
||||||
|
|
||||||
|
# collect and install all dlls from tcl dll dirs
|
||||||
|
file (GLOB TCL_DLLS "${3RDPARTY_TCL_DLL_DIR}/*.dll")
|
||||||
|
|
||||||
|
if (SINGLE_GENERATOR)
|
||||||
|
install (FILES ${TCL_DLLS} DESTINATION "${INSTALL_DIR_BIN}")
|
||||||
|
else()
|
||||||
|
install (FILES ${TCL_DLLS}
|
||||||
|
CONFIGURATIONS Release
|
||||||
|
DESTINATION "${INSTALL_DIR_BIN}")
|
||||||
|
install (FILES ${TCL_DLLS}
|
||||||
|
CONFIGURATIONS RelWithDebInfo
|
||||||
|
DESTINATION "${INSTALL_DIR_BIN}i")
|
||||||
|
install (FILES ${TCL_DLLS}
|
||||||
|
CONFIGURATIONS Debug
|
||||||
|
DESTINATION "${INSTALL_DIR_BIN}d")
|
||||||
|
endif()
|
||||||
|
else()
|
||||||
|
get_filename_component(3RDPARTY_TCL_LIBRARY_REALPATH ${3RDPARTY_TCL_LIBRARY} REALPATH)
|
||||||
|
|
||||||
|
if (SINGLE_GENERATOR)
|
||||||
|
install (FILES ${3RDPARTY_TCL_LIBRARY_REALPATH} DESTINATION "${INSTALL_DIR_LIB}")
|
||||||
|
else()
|
||||||
|
install (FILES ${3RDPARTY_TCL_LIBRARY_REALPATH}
|
||||||
|
CONFIGURATIONS Release
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}")
|
||||||
|
install (FILES ${3RDPARTY_TCL_LIBRARY_REALPATH}
|
||||||
|
CONFIGURATIONS RelWithDebInfo
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}i")
|
||||||
|
install (FILES ${3RDPARTY_TCL_LIBRARY_REALPATH}
|
||||||
|
CONFIGURATIONS Debug
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}d")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (TCL_TCLSH_VERSION)
|
||||||
|
# tcl is required to install in lib folder (without)
|
||||||
|
install (DIRECTORY "${3RDPARTY_TCL_LIBRARY_DIR}/tcl8" DESTINATION "${INSTALL_DIR_LIB}")
|
||||||
|
install (DIRECTORY "${3RDPARTY_TCL_LIBRARY_DIR}/tcl${TCL_TCLSH_VERSION}" DESTINATION "${INSTALL_DIR_LIB}")
|
||||||
|
else()
|
||||||
|
message (STATUS "\nWarning: tclX.X subdir won't be copyied during the installation process.")
|
||||||
|
message (STATUS "Try seeking tcl within another folder by changing 3RDPARTY_TCL_DIR variable.")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
set (USED_3RDPARTY_TCL_DIR "")
|
||||||
|
else()
|
||||||
|
# the library directory for using by the executable
|
||||||
|
if (WIN32)
|
||||||
|
set (USED_3RDPARTY_TCL_DIR ${3RDPARTY_TCL_DLL_DIR})
|
||||||
|
else()
|
||||||
|
set (USED_3RDPARTY_TCL_DIR ${3RDPARTY_TCL_LIBRARY_DIR})
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
mark_as_advanced (3RDPARTY_TCL_LIBRARY 3RDPARTY_TCL_DLL)
|
||||||
|
endif()
|
||||||
|
|
||||||
if (TK_FOUND AND 3RDPARTY_TCL_DIR)
|
if (TK_FOUND AND 3RDPARTY_TCL_DIR)
|
||||||
|
|
||||||
@@ -278,3 +284,11 @@ OCCT_CHECK_AND_UNSET (TCL_TCLSH)
|
|||||||
OCCT_CHECK_AND_UNSET (TK_LIBRARY)
|
OCCT_CHECK_AND_UNSET (TK_LIBRARY)
|
||||||
OCCT_CHECK_AND_UNSET (TK_INCLUDE_PATH)
|
OCCT_CHECK_AND_UNSET (TK_INCLUDE_PATH)
|
||||||
OCCT_CHECK_AND_UNSET (TK_WISH)
|
OCCT_CHECK_AND_UNSET (TK_WISH)
|
||||||
|
|
||||||
|
if (NOT BUILD_SHARED_LIBS)
|
||||||
|
OCCT_CHECK_AND_UNSET (3RDPARTY_TCL_LIBRARY)
|
||||||
|
OCCT_CHECK_AND_UNSET (3RDPARTY_TCL_LIBRARY_DIR)
|
||||||
|
OCCT_CHECK_AND_UNSET (3RDPARTY_TCL_DLL)
|
||||||
|
OCCT_CHECK_AND_UNSET (3RDPARTY_TCL_DLL_DIR)
|
||||||
|
OCCT_CHECK_AND_UNSET (INSTALL_TCL)
|
||||||
|
endif()
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
# tk
|
# tk
|
||||||
|
|
||||||
if (NOT DEFINED INSTALL_TK)
|
if (NOT DEFINED INSTALL_TK AND BUILD_SHARED_LIBS)
|
||||||
set (INSTALL_TK OFF CACHE BOOL "${INSTALL_TK_DESCR}")
|
set (INSTALL_TK OFF CACHE BOOL "${INSTALL_TK_DESCR}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -18,26 +18,28 @@ if (NOT DEFINED 3RDPARTY_TK_INCLUDE_DIR)
|
|||||||
set (3RDPARTY_TK_INCLUDE_DIR "" CACHE FILEPATH "The directory containing headers of tk")
|
set (3RDPARTY_TK_INCLUDE_DIR "" CACHE FILEPATH "The directory containing headers of tk")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# tk library file (with absolute path)
|
if (BUILD_SHARED_LIBS)
|
||||||
if (NOT DEFINED 3RDPARTY_TK_LIBRARY OR NOT 3RDPARTY_TK_LIBRARY_DIR)
|
# tk library file (with absolute path)
|
||||||
set (3RDPARTY_TK_LIBRARY "" CACHE FILEPATH "tk library" FORCE)
|
if (NOT DEFINED 3RDPARTY_TK_LIBRARY OR NOT 3RDPARTY_TK_LIBRARY_DIR)
|
||||||
endif()
|
set (3RDPARTY_TK_LIBRARY "" CACHE FILEPATH "tk library" FORCE)
|
||||||
|
|
||||||
# tk library directory
|
|
||||||
if (NOT DEFINED 3RDPARTY_TK_LIBRARY_DIR)
|
|
||||||
set (3RDPARTY_TK_LIBRARY_DIR "" CACHE FILEPATH "The directory containing tk library")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# tk shared library (with absolute path)
|
|
||||||
if (WIN32)
|
|
||||||
if (NOT DEFINED 3RDPARTY_TK_DLL OR NOT 3RDPARTY_TK_DLL_DIR)
|
|
||||||
set (3RDPARTY_TK_DLL "" CACHE FILEPATH "tk shared library" FORCE)
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
# tk shared library directory
|
# tk library directory
|
||||||
if (WIN32 AND NOT DEFINED 3RDPARTY_TK_DLL_DIR)
|
if (NOT DEFINED 3RDPARTY_TK_LIBRARY_DIR)
|
||||||
set (3RDPARTY_TK_DLL_DIR "" CACHE FILEPATH "The directory containing tk shared library")
|
set (3RDPARTY_TK_LIBRARY_DIR "" CACHE FILEPATH "The directory containing tk library")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
# tk shared library (with absolute path)
|
||||||
|
if (WIN32)
|
||||||
|
if (NOT DEFINED 3RDPARTY_TK_DLL OR NOT 3RDPARTY_TK_DLL_DIR)
|
||||||
|
set (3RDPARTY_TK_DLL "" CACHE FILEPATH "tk shared library" FORCE)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
# tk shared library directory
|
||||||
|
if (WIN32 AND NOT DEFINED 3RDPARTY_TK_DLL_DIR)
|
||||||
|
set (3RDPARTY_TK_DLL_DIR "" CACHE FILEPATH "The directory containing tk shared library")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# search for tk in user defined directory
|
# search for tk in user defined directory
|
||||||
@@ -57,7 +59,7 @@ endif()
|
|||||||
COMPLIANCE_PRODUCT_CONSISTENCY(TK)
|
COMPLIANCE_PRODUCT_CONSISTENCY(TK)
|
||||||
|
|
||||||
# use default (CMake) TCL search
|
# use default (CMake) TCL search
|
||||||
find_package(TCL)
|
find_package(TCL QUIET)
|
||||||
|
|
||||||
# tk include dir
|
# tk include dir
|
||||||
if (NOT 3RDPARTY_TK_INCLUDE_DIR)
|
if (NOT 3RDPARTY_TK_INCLUDE_DIR)
|
||||||
@@ -66,111 +68,115 @@ if (NOT 3RDPARTY_TK_INCLUDE_DIR)
|
|||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# tk dir and library
|
if (BUILD_SHARED_LIBS)
|
||||||
if (NOT 3RDPARTY_TK_LIBRARY)
|
# tk dir and library
|
||||||
if (TK_LIBRARY AND EXISTS "${TK_LIBRARY}")
|
if (NOT 3RDPARTY_TK_LIBRARY)
|
||||||
set (3RDPARTY_TK_LIBRARY "${TK_LIBRARY}" CACHE FILEPATH "TK library" FORCE)
|
if (TK_LIBRARY AND EXISTS "${TK_LIBRARY}")
|
||||||
|
set (3RDPARTY_TK_LIBRARY "${TK_LIBRARY}" CACHE FILEPATH "TK library" FORCE)
|
||||||
|
|
||||||
if (NOT 3RDPARTY_TK_LIBRARY_DIR)
|
if (NOT 3RDPARTY_TK_LIBRARY_DIR)
|
||||||
get_filename_component (3RDPARTY_TK_LIBRARY_DIR "${3RDPARTY_TK_LIBRARY}" PATH)
|
get_filename_component (3RDPARTY_TK_LIBRARY_DIR "${3RDPARTY_TK_LIBRARY}" PATH)
|
||||||
set (3RDPARTY_TK_LIBRARY_DIR "${3RDPARTY_TK_LIBRARY_DIR}" CACHE FILEPATH "The directory containing TK library" FORCE)
|
set (3RDPARTY_TK_LIBRARY_DIR "${3RDPARTY_TK_LIBRARY_DIR}" CACHE FILEPATH "The directory containing TK library" FORCE)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
if (NOT 3RDPARTY_TK_DLL)
|
||||||
|
set (CMAKE_FIND_LIBRARY_SUFFIXES ".lib" ".dll" ".a")
|
||||||
|
|
||||||
|
set (DLL_FOLDER_FOR_SEARCH "")
|
||||||
|
if (3RDPARTY_TK_DLL_DIR)
|
||||||
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TK_DLL_DIR}")
|
||||||
|
elseif (3RDPARTY_TK_DIR)
|
||||||
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TK_DIR}/bin")
|
||||||
|
elseif (3RDPARTY_TK_LIBRARY_DIR)
|
||||||
|
get_filename_component (3RDPARTY_TK_LIBRARY_DIR_PARENT "${3RDPARTY_TK_LIBRARY_DIR}" PATH)
|
||||||
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TK_LIBRARY_DIR_PARENT}/bin")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
set (3RDPARTY_TK_DLL "3RDPARTY_TK_DLL-NOTFOUND" CACHE FILEPATH "TK shared library" FORCE)
|
||||||
|
find_library (3RDPARTY_TK_DLL NAMES tk86 tk85
|
||||||
|
PATHS "${DLL_FOLDER_FOR_SEARCH}"
|
||||||
|
NO_DEFAULT_PATH)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
COMPLIANCE_PRODUCT_CONSISTENCY(TK)
|
||||||
|
|
||||||
if (WIN32)
|
if (BUILD_SHARED_LIBS)
|
||||||
if (NOT 3RDPARTY_TK_DLL)
|
# tk dir and library
|
||||||
set (CMAKE_FIND_LIBRARY_SUFFIXES ".lib" ".dll")
|
if (NOT 3RDPARTY_TK_LIBRARY)
|
||||||
|
set (3RDPARTY_TK_LIBRARY "3RDPARTY_TK_LIBRARY-NOTFOUND" CACHE FILEPATH "TK library" FORCE)
|
||||||
|
find_library (3RDPARTY_TK_LIBRARY NAMES tk8.6 tk86 tk8.5 tk85
|
||||||
|
PATHS "${3RDPARTY_TK_LIBRARY_DIR}"
|
||||||
|
NO_DEFAULT_PATH)
|
||||||
|
|
||||||
|
# search in another place if previous search doesn't find anything
|
||||||
|
find_library (3RDPARTY_TK_LIBRARY NAMES tk8.6 tk86 tk8.5 tk85
|
||||||
|
PATHS "${3RDPARTY_TK_DIR}/lib"
|
||||||
|
NO_DEFAULT_PATH)
|
||||||
|
|
||||||
|
|
||||||
|
if (NOT 3RDPARTY_TK_LIBRARY OR NOT EXISTS "${3RDPARTY_TK_LIBRARY}")
|
||||||
|
set (3RDPARTY_TK_LIBRARY "" CACHE FILEPATH "TK library" FORCE)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (NOT 3RDPARTY_TK_LIBRARY_DIR AND 3RDPARTY_TK_LIBRARY)
|
||||||
|
get_filename_component (3RDPARTY_TK_LIBRARY_DIR "${3RDPARTY_TK_LIBRARY}" PATH)
|
||||||
|
set (3RDPARTY_TK_LIBRARY_DIR "${3RDPARTY_TK_LIBRARY_DIR}" CACHE FILEPATH "The directory containing TK library" FORCE)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
set (3RDPARTY_TK_LIBRARY_VERSION "")
|
||||||
|
if (3RDPARTY_TK_LIBRARY AND EXISTS "${3RDPARTY_TK_LIBRARY}")
|
||||||
|
get_filename_component (TK_LIBRARY_NAME "${3RDPARTY_TK_LIBRARY}" NAME)
|
||||||
|
string(REGEX REPLACE "^.*tk([0-9]\\.*[0-9]).*$" "\\1" TK_LIBRARY_VERSION "${TK_LIBRARY_NAME}")
|
||||||
|
|
||||||
|
if (NOT "${TK_LIBRARY_VERSION}" STREQUAL "${TK_LIBRARY_NAME}")
|
||||||
|
set (3RDPARTY_TK_LIBRARY_VERSION "${TK_LIBRARY_VERSION}")
|
||||||
|
else() # if the version isn't found - seek other library with 8.6 or 8.5 version in the same dir
|
||||||
|
message (STATUS "Info: TK version isn't found")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
set (3RDPARTY_TK_LIBRARY_VERSION_WITH_DOT "")
|
||||||
|
if (3RDPARTY_TK_LIBRARY_VERSION)
|
||||||
|
string (REGEX REPLACE "^.*([0-9])[^0-9]*[0-9].*$" "\\1" 3RDPARTY_TK_MAJOR_VERSION "${3RDPARTY_TK_LIBRARY_VERSION}")
|
||||||
|
string (REGEX REPLACE "^.*[0-9][^0-9]*([0-9]).*$" "\\1" 3RDPARTY_TK_MINOR_VERSION "${3RDPARTY_TK_LIBRARY_VERSION}")
|
||||||
|
set (3RDPARTY_TK_LIBRARY_VERSION_WITH_DOT "${3RDPARTY_TK_MAJOR_VERSION}.${3RDPARTY_TK_MINOR_VERSION}")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
if (NOT 3RDPARTY_TK_DLL)
|
||||||
|
set (CMAKE_FIND_LIBRARY_SUFFIXES ".lib" ".dll" ".a")
|
||||||
|
|
||||||
set (DLL_FOLDER_FOR_SEARCH "")
|
set (DLL_FOLDER_FOR_SEARCH "")
|
||||||
if (3RDPARTY_TK_DLL_DIR)
|
if (3RDPARTY_TK_DLL_DIR)
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TK_DLL_DIR}")
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TK_DLL_DIR}")
|
||||||
elseif (3RDPARTY_TK_DIR)
|
elseif (3RDPARTY_TK_DIR)
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TK_DIR}/bin")
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TK_DIR}/bin")
|
||||||
elseif (3RDPARTY_TK_LIBRARY_DIR)
|
else()
|
||||||
get_filename_component (3RDPARTY_TK_LIBRARY_DIR_PARENT "${3RDPARTY_TK_LIBRARY_DIR}" PATH)
|
get_filename_component (3RDPARTY_TK_LIBRARY_DIR_PARENT "${3RDPARTY_TK_LIBRARY_DIR}" PATH)
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TK_LIBRARY_DIR_PARENT}/bin")
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TK_LIBRARY_DIR_PARENT}/bin")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set (3RDPARTY_TK_DLL "3RDPARTY_TK_DLL-NOTFOUND" CACHE FILEPATH "TK shared library" FORCE)
|
set (3RDPARTY_TK_DLL "3RDPARTY_TK_DLL-NOTFOUND" CACHE FILEPATH "TK shared library" FORCE)
|
||||||
find_library (3RDPARTY_TK_DLL NAMES tk86 tk85
|
find_library (3RDPARTY_TK_DLL NAMES tk${3RDPARTY_TK_LIBRARY_VERSION}
|
||||||
PATHS "${DLL_FOLDER_FOR_SEARCH}"
|
PATHS "${DLL_FOLDER_FOR_SEARCH}"
|
||||||
NO_DEFAULT_PATH)
|
NO_DEFAULT_PATH)
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
COMPLIANCE_PRODUCT_CONSISTENCY(TK)
|
if (NOT 3RDPARTY_TK_DLL OR NOT EXISTS "${3RDPARTY_TK_DLL}")
|
||||||
|
set (3RDPARTY_TK_DLL "" CACHE FILEPATH "TK shared library" FORCE)
|
||||||
# tk dir and library
|
endif()
|
||||||
if (NOT 3RDPARTY_TK_LIBRARY)
|
|
||||||
set (3RDPARTY_TK_LIBRARY "3RDPARTY_TK_LIBRARY-NOTFOUND" CACHE FILEPATH "TK library" FORCE)
|
|
||||||
find_library (3RDPARTY_TK_LIBRARY NAMES tk8.6 tk86 tk8.5 tk85
|
|
||||||
PATHS "${3RDPARTY_TK_LIBRARY_DIR}"
|
|
||||||
NO_DEFAULT_PATH)
|
|
||||||
|
|
||||||
# search in another place if previous search doesn't find anything
|
|
||||||
find_library (3RDPARTY_TK_LIBRARY NAMES tk8.6 tk86 tk8.5 tk85
|
|
||||||
PATHS "${3RDPARTY_TK_DIR}/lib"
|
|
||||||
NO_DEFAULT_PATH)
|
|
||||||
|
|
||||||
|
|
||||||
if (NOT 3RDPARTY_TK_LIBRARY OR NOT EXISTS "${3RDPARTY_TK_LIBRARY}")
|
|
||||||
set (3RDPARTY_TK_LIBRARY "" CACHE FILEPATH "TK library" FORCE)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (NOT 3RDPARTY_TK_LIBRARY_DIR AND 3RDPARTY_TK_LIBRARY)
|
|
||||||
get_filename_component (3RDPARTY_TK_LIBRARY_DIR "${3RDPARTY_TK_LIBRARY}" PATH)
|
|
||||||
set (3RDPARTY_TK_LIBRARY_DIR "${3RDPARTY_TK_LIBRARY_DIR}" CACHE FILEPATH "The directory containing TK library" FORCE)
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
set (3RDPARTY_TK_LIBRARY_VERSION "")
|
|
||||||
if (3RDPARTY_TK_LIBRARY AND EXISTS "${3RDPARTY_TK_LIBRARY}")
|
|
||||||
get_filename_component (TK_LIBRARY_NAME "${3RDPARTY_TK_LIBRARY}" NAME)
|
|
||||||
string(REGEX REPLACE "^.*tk([0-9]\\.*[0-9]).*$" "\\1" TK_LIBRARY_VERSION "${TK_LIBRARY_NAME}")
|
|
||||||
|
|
||||||
if (NOT "${TK_LIBRARY_VERSION}" STREQUAL "${TK_LIBRARY_NAME}")
|
|
||||||
set (3RDPARTY_TK_LIBRARY_VERSION "${TK_LIBRARY_VERSION}")
|
|
||||||
else() # if the version isn't found - seek other library with 8.6 or 8.5 version in the same dir
|
|
||||||
message (STATUS "Info: TK version isn't found")
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
set (3RDPARTY_TK_LIBRARY_VERSION_WITH_DOT "")
|
|
||||||
if (3RDPARTY_TK_LIBRARY_VERSION)
|
|
||||||
string (REGEX REPLACE "^.*([0-9])[^0-9]*[0-9].*$" "\\1" 3RDPARTY_TK_MAJOR_VERSION "${3RDPARTY_TK_LIBRARY_VERSION}")
|
|
||||||
string (REGEX REPLACE "^.*[0-9][^0-9]*([0-9]).*$" "\\1" 3RDPARTY_TK_MINOR_VERSION "${3RDPARTY_TK_LIBRARY_VERSION}")
|
|
||||||
set (3RDPARTY_TK_LIBRARY_VERSION_WITH_DOT "${3RDPARTY_TK_MAJOR_VERSION}.${3RDPARTY_TK_MINOR_VERSION}")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (WIN32)
|
|
||||||
if (NOT 3RDPARTY_TK_DLL)
|
|
||||||
set (CMAKE_FIND_LIBRARY_SUFFIXES ".lib" ".dll")
|
|
||||||
|
|
||||||
set (DLL_FOLDER_FOR_SEARCH "")
|
|
||||||
if (3RDPARTY_TK_DLL_DIR)
|
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TK_DLL_DIR}")
|
|
||||||
elseif (3RDPARTY_TK_DIR)
|
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TK_DIR}/bin")
|
|
||||||
else()
|
|
||||||
get_filename_component (3RDPARTY_TK_LIBRARY_DIR_PARENT "${3RDPARTY_TK_LIBRARY_DIR}" PATH)
|
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TK_LIBRARY_DIR_PARENT}/bin")
|
|
||||||
endif()
|
endif()
|
||||||
|
if (NOT 3RDPARTY_TK_DLL_DIR AND 3RDPARTY_TK_DLL)
|
||||||
set (3RDPARTY_TK_DLL "3RDPARTY_TK_DLL-NOTFOUND" CACHE FILEPATH "TK shared library" FORCE)
|
get_filename_component (3RDPARTY_TK_DLL_DIR "${3RDPARTY_TK_DLL}" PATH)
|
||||||
find_library (3RDPARTY_TK_DLL NAMES tk${3RDPARTY_TK_LIBRARY_VERSION}
|
set (3RDPARTY_TK_DLL_DIR "${3RDPARTY_TK_DLL_DIR}" CACHE FILEPATH "The directory containing TK shared library" FORCE)
|
||||||
PATHS "${DLL_FOLDER_FOR_SEARCH}"
|
|
||||||
NO_DEFAULT_PATH)
|
|
||||||
|
|
||||||
if (NOT 3RDPARTY_TK_DLL OR NOT EXISTS "${3RDPARTY_TK_DLL}")
|
|
||||||
set (3RDPARTY_TK_DLL "" CACHE FILEPATH "TK shared library" FORCE)
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
if (NOT 3RDPARTY_TK_DLL_DIR AND 3RDPARTY_TK_DLL)
|
|
||||||
get_filename_component (3RDPARTY_TK_DLL_DIR "${3RDPARTY_TK_DLL}" PATH)
|
|
||||||
set (3RDPARTY_TK_DLL_DIR "${3RDPARTY_TK_DLL_DIR}" CACHE FILEPATH "The directory containing TK shared library" FORCE)
|
|
||||||
endif()
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# include found paths to common variables
|
# include found paths to common variables
|
||||||
@@ -180,85 +186,87 @@ else()
|
|||||||
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_TK_INCLUDE_DIR)
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_TK_INCLUDE_DIR)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (3RDPARTY_TK_LIBRARY AND EXISTS "${3RDPARTY_TK_LIBRARY}")
|
if (BUILD_SHARED_LIBS)
|
||||||
list (APPEND 3RDPARTY_LIBRARY_DIRS "${3RDPARTY_TK_LIBRARY_DIR}")
|
if (3RDPARTY_TK_LIBRARY AND EXISTS "${3RDPARTY_TK_LIBRARY}")
|
||||||
else()
|
list (APPEND 3RDPARTY_LIBRARY_DIRS "${3RDPARTY_TK_LIBRARY_DIR}")
|
||||||
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_TK_LIBRARY_DIR})
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (WIN32)
|
|
||||||
if (3RDPARTY_TK_DLL OR EXISTS "${3RDPARTY_TK_DLL}")
|
|
||||||
list (APPEND 3RDPARTY_DLL_DIRS "${3RDPARTY_TK_DLL_DIR}")
|
|
||||||
else()
|
else()
|
||||||
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_TK_DLL_DIR)
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_TK_LIBRARY_DIR})
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
# install tk
|
|
||||||
if (INSTALL_TK)
|
|
||||||
# include occt macros. compiler_bitness, os_wiht_bit, compiler
|
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/occt_macros")
|
|
||||||
|
|
||||||
OCCT_MAKE_OS_WITH_BITNESS()
|
|
||||||
OCCT_MAKE_COMPILER_SHORT_NAME()
|
|
||||||
|
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
# tk 8.6 requires zlib. install all dlls from tk bin folder that may contain zlib also
|
if (3RDPARTY_TK_DLL OR EXISTS "${3RDPARTY_TK_DLL}")
|
||||||
|
list (APPEND 3RDPARTY_DLL_DIRS "${3RDPARTY_TK_DLL_DIR}")
|
||||||
# collect and install all dlls from tk dll dirs
|
|
||||||
file (GLOB TK_DLLS "${3RDPARTY_TK_DLL_DIR}/*.dll")
|
|
||||||
|
|
||||||
if (SINGLE_GENERATOR)
|
|
||||||
install (FILES ${TK_DLLS} DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}")
|
|
||||||
else()
|
else()
|
||||||
install (FILES ${TK_DLLS}
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_TK_DLL_DIR)
|
||||||
CONFIGURATIONS Release
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}")
|
|
||||||
install (FILES ${TK_DLLS}
|
|
||||||
CONFIGURATIONS RelWithDebInfo
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}i")
|
|
||||||
install (FILES ${TK_DLLS}
|
|
||||||
CONFIGURATIONS Debug
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_BIN}d")
|
|
||||||
endif()
|
|
||||||
else()
|
|
||||||
get_filename_component(3RDPARTY_TK_LIBRARY_REALPATH ${3RDPARTY_TK_LIBRARY} REALPATH)
|
|
||||||
|
|
||||||
if (SINGLE_GENERATOR)
|
|
||||||
install (FILES ${3RDPARTY_TK_LIBRARY_REALPATH} DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}")
|
|
||||||
else()
|
|
||||||
install (FILES ${3RDPARTY_TK_LIBRARY_REALPATH}
|
|
||||||
CONFIGURATIONS Release
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}/")
|
|
||||||
install (FILES ${3RDPARTY_TK_LIBRARY_REALPATH}
|
|
||||||
CONFIGURATIONS RelWithDebInfo
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}/i")
|
|
||||||
install (FILES ${3RDPARTY_TK_LIBRARY_REALPATH}
|
|
||||||
CONFIGURATIONS Debug
|
|
||||||
DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}d")
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (TCL_TCLSH_VERSION)
|
# install tk
|
||||||
# tk is required to install in lib folder (without)
|
if (INSTALL_TK)
|
||||||
install (DIRECTORY "${3RDPARTY_TK_LIBRARY_DIR}/tk${TCL_TCLSH_VERSION}" DESTINATION "${INSTALL_DIR}/${INSTALL_DIR_LIB}")
|
# include occt macros. compiler_bitness, os_wiht_bit, compiler
|
||||||
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/occt_macros")
|
||||||
|
|
||||||
|
OCCT_MAKE_OS_WITH_BITNESS()
|
||||||
|
OCCT_MAKE_COMPILER_SHORT_NAME()
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
# tk 8.6 requires zlib. install all dlls from tk bin folder that may contain zlib also
|
||||||
|
|
||||||
|
# collect and install all dlls from tk dll dirs
|
||||||
|
file (GLOB TK_DLLS "${3RDPARTY_TK_DLL_DIR}/*.dll")
|
||||||
|
|
||||||
|
if (SINGLE_GENERATOR)
|
||||||
|
install (FILES ${TK_DLLS} DESTINATION "${INSTALL_DIR_BIN}")
|
||||||
|
else()
|
||||||
|
install (FILES ${TK_DLLS}
|
||||||
|
CONFIGURATIONS Release
|
||||||
|
DESTINATION "${INSTALL_DIR_BIN}")
|
||||||
|
install (FILES ${TK_DLLS}
|
||||||
|
CONFIGURATIONS RelWithDebInfo
|
||||||
|
DESTINATION "${INSTALL_DIR_BIN}i")
|
||||||
|
install (FILES ${TK_DLLS}
|
||||||
|
CONFIGURATIONS Debug
|
||||||
|
DESTINATION "${INSTALL_DIR_BIN}d")
|
||||||
|
endif()
|
||||||
|
else()
|
||||||
|
get_filename_component(3RDPARTY_TK_LIBRARY_REALPATH ${3RDPARTY_TK_LIBRARY} REALPATH)
|
||||||
|
|
||||||
|
if (SINGLE_GENERATOR)
|
||||||
|
install (FILES ${3RDPARTY_TK_LIBRARY_REALPATH} DESTINATION "${INSTALL_DIR_LIB}")
|
||||||
|
else()
|
||||||
|
install (FILES ${3RDPARTY_TK_LIBRARY_REALPATH}
|
||||||
|
CONFIGURATIONS Release
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}/")
|
||||||
|
install (FILES ${3RDPARTY_TK_LIBRARY_REALPATH}
|
||||||
|
CONFIGURATIONS RelWithDebInfo
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}/i")
|
||||||
|
install (FILES ${3RDPARTY_TK_LIBRARY_REALPATH}
|
||||||
|
CONFIGURATIONS Debug
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}d")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (TCL_TCLSH_VERSION)
|
||||||
|
# tk is required to install in lib folder (without)
|
||||||
|
install (DIRECTORY "${3RDPARTY_TK_LIBRARY_DIR}/tk${TCL_TCLSH_VERSION}" DESTINATION "${INSTALL_DIR_LIB}")
|
||||||
|
else()
|
||||||
|
message (STATUS "\nWarning: tkX.X subdir won't be copyied during the installation process.")
|
||||||
|
message (STATUS "Try seeking tk within another folder by changing 3RDPARTY_TK_DIR variable.")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
set (USED_3RDPARTY_TK_DIR "")
|
||||||
else()
|
else()
|
||||||
message (STATUS "\nWarning: tkX.X subdir won't be copyied during the installation process.")
|
# the library directory for using by the executable
|
||||||
message (STATUS "Try seeking tk within another folder by changing 3RDPARTY_TK_DIR variable.")
|
if (WIN32)
|
||||||
|
set (USED_3RDPARTY_TK_DIR ${3RDPARTY_TK_DLL_DIR})
|
||||||
|
else()
|
||||||
|
set (USED_3RDPARTY_TK_DIR ${3RDPARTY_TK_LIBRARY_DIR})
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set (USED_3RDPARTY_TK_DIR "")
|
mark_as_advanced (3RDPARTY_TK_LIBRARY 3RDPARTY_TK_DLL)
|
||||||
else()
|
|
||||||
# the library directory for using by the executable
|
|
||||||
if (WIN32)
|
|
||||||
set (USED_3RDPARTY_TK_DIR ${3RDPARTY_TK_DLL_DIR})
|
|
||||||
else()
|
|
||||||
set (USED_3RDPARTY_TK_DIR ${3RDPARTY_TK_LIBRARY_DIR})
|
|
||||||
endif()
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
mark_as_advanced (3RDPARTY_TK_LIBRARY 3RDPARTY_TK_DLL)
|
|
||||||
|
|
||||||
# unset all redundant variables
|
# unset all redundant variables
|
||||||
#TCL
|
#TCL
|
||||||
OCCT_CHECK_AND_UNSET (TCL_LIBRARY)
|
OCCT_CHECK_AND_UNSET (TCL_LIBRARY)
|
||||||
@@ -268,3 +276,11 @@ OCCT_CHECK_AND_UNSET (TCL_TCLSH)
|
|||||||
OCCT_CHECK_AND_UNSET (TK_LIBRARY)
|
OCCT_CHECK_AND_UNSET (TK_LIBRARY)
|
||||||
OCCT_CHECK_AND_UNSET (TK_INCLUDE_PATH)
|
OCCT_CHECK_AND_UNSET (TK_INCLUDE_PATH)
|
||||||
OCCT_CHECK_AND_UNSET (TK_WISH)
|
OCCT_CHECK_AND_UNSET (TK_WISH)
|
||||||
|
|
||||||
|
if (NOT BUILD_SHARED_LIBS)
|
||||||
|
OCCT_CHECK_AND_UNSET (3RDPARTY_TK_LIBRARY)
|
||||||
|
OCCT_CHECK_AND_UNSET (3RDPARTY_TK_LIBRARY_DIR)
|
||||||
|
OCCT_CHECK_AND_UNSET (3RDPARTY_TK_DLL)
|
||||||
|
OCCT_CHECK_AND_UNSET (3RDPARTY_TK_DLL_DIR)
|
||||||
|
OCCT_CHECK_AND_UNSET (INSTALL_TK)
|
||||||
|
endif()
|
||||||
|
@@ -18,9 +18,20 @@ set (BUILD_YACCLEX_DESCR
|
|||||||
ExprIntrp functionality are generated automatically with Flex/Bison. Checking this options
|
ExprIntrp functionality are generated automatically with Flex/Bison. Checking this options
|
||||||
leads to automatic search of Flex/Bison binaries and regeneration of the mentioned files")
|
leads to automatic search of Flex/Bison binaries and regeneration of the mentioned files")
|
||||||
|
|
||||||
|
set (BUILD_RESOURCES_DESCR "Enables regeneration of OCCT resource files")
|
||||||
|
|
||||||
set (BUILD_WITH_DEBUG_DESCR
|
set (BUILD_WITH_DEBUG_DESCR
|
||||||
"Enables extended messages of many OCCT algorithms, usually printed to cout.
|
"Enables extended messages of many OCCT algorithms, usually printed to cout.
|
||||||
These include messages on internal errors and special cases encountered, timing etc")
|
These include messages on internal errors and special cases encountered, timing etc.
|
||||||
|
Applies only for Debug configuration.")
|
||||||
|
|
||||||
|
set (BUILD_SHARED_LIBRARY_NAME_POSTFIX_DESCR
|
||||||
|
"Append the postfix to names of output libraries")
|
||||||
|
|
||||||
|
set (BUILD_ENABLE_FPE_SIGNAL_HANDLER_DESCR
|
||||||
|
"Enable/Disable the floating point exceptions (FPE) during DRAW execution only.
|
||||||
|
Corresponding environment variable (CSF_FPE) can be changed manually
|
||||||
|
in custom.bat/sh scripts without regeneration by CMake.")
|
||||||
|
|
||||||
# install variables
|
# install variables
|
||||||
set (INSTALL_DIR_DESCR
|
set (INSTALL_DIR_DESCR
|
||||||
@@ -68,7 +79,8 @@ INSTALL_MESSAGE (INSTALL_SAMPLES "OCCT samples")
|
|||||||
INSTALL_MESSAGE (INSTALL_TEST_CASES "non-regression OCCT test scripts")
|
INSTALL_MESSAGE (INSTALL_TEST_CASES "non-regression OCCT test scripts")
|
||||||
INSTALL_MESSAGE (INSTALL_DOC_Overview "OCCT overview documentation (HTML format)")
|
INSTALL_MESSAGE (INSTALL_DOC_Overview "OCCT overview documentation (HTML format)")
|
||||||
INSTALL_MESSAGE (INSTALL_FREEIMAGE "FreeImage binaries")
|
INSTALL_MESSAGE (INSTALL_FREEIMAGE "FreeImage binaries")
|
||||||
INSTALL_MESSAGE (INSTALL_FREEIMAGEPLUS "FreeImagePlus binaries")
|
INSTALL_MESSAGE (INSTALL_EGL "EGL binaries")
|
||||||
|
INSTALL_MESSAGE (INSTALL_GLES2 "OpenGL ES 2.0 binaries")
|
||||||
INSTALL_MESSAGE (INSTALL_FREETYPE "FreeType binaries")
|
INSTALL_MESSAGE (INSTALL_FREETYPE "FreeType binaries")
|
||||||
INSTALL_MESSAGE (INSTALL_GL2PS "GL2PS binaries")
|
INSTALL_MESSAGE (INSTALL_GL2PS "GL2PS binaries")
|
||||||
INSTALL_MESSAGE (INSTALL_TBB "TBB binaries")
|
INSTALL_MESSAGE (INSTALL_TBB "TBB binaries")
|
||||||
@@ -105,6 +117,9 @@ set (BUILD_MODULE_MfcSamples_DESCR
|
|||||||
These samples show some possibilities of using OCCT and they can be executed
|
These samples show some possibilities of using OCCT and they can be executed
|
||||||
with script samples.bat from the installation directory (INSTALL_DIR)")
|
with script samples.bat from the installation directory (INSTALL_DIR)")
|
||||||
|
|
||||||
|
set (BUILD_MODULE_UwpSample_DESCR
|
||||||
|
"Indicates whether OCCT UWP sample should be built together with OCCT.")
|
||||||
|
|
||||||
set (BUILD_DOC_Overview_DESCR
|
set (BUILD_DOC_Overview_DESCR
|
||||||
"Indicates whether OCCT overview documentation project (Markdown format) should be
|
"Indicates whether OCCT overview documentation project (Markdown format) should be
|
||||||
created together with OCCT. It is not built together with OCCT. Checking this options
|
created together with OCCT. It is not built together with OCCT. Checking this options
|
||||||
@@ -121,6 +136,14 @@ set (USE_FREEIMAGE_DESCR
|
|||||||
"Indicates whether Freeimage product should be used in OCCT visualization
|
"Indicates whether Freeimage product should be used in OCCT visualization
|
||||||
module for support of popular graphics image formats (PNG, BMP etc)")
|
module for support of popular graphics image formats (PNG, BMP etc)")
|
||||||
|
|
||||||
|
set (USE_EGL_DESCR
|
||||||
|
"Indicates whether EGL should be used in OCCT visualization
|
||||||
|
module instead of conventional OpenGL context creation APIs")
|
||||||
|
|
||||||
|
set (USE_GLES2_DESCR
|
||||||
|
"Indicates whether OpenGL ES 2.0 should be used in OCCT visualization
|
||||||
|
module instead of desktop OpenGL")
|
||||||
|
|
||||||
set (USE_GL2PS_DESCR
|
set (USE_GL2PS_DESCR
|
||||||
"Indicates whether GL2PS product should be used in OCCT visualization
|
"Indicates whether GL2PS product should be used in OCCT visualization
|
||||||
module for support of vector image formats (PS, EPS etc)")
|
module for support of vector image formats (PS, EPS etc)")
|
||||||
@@ -141,5 +164,6 @@ set (USE_GLX_DESCR "Indicates whether X11 OpenGl on OSX is used or not")
|
|||||||
set (USE_D3D_DESCR "Indicates whether optional Direct3D wrapper in OCCT visualization module should be build or not")
|
set (USE_D3D_DESCR "Indicates whether optional Direct3D wrapper in OCCT visualization module should be build or not")
|
||||||
|
|
||||||
macro (BUILD_MODULE MODULE_NAME)
|
macro (BUILD_MODULE MODULE_NAME)
|
||||||
set (BUILD_MODULE_${MODULE_NAME} ON CACHE BOOL "${BUILD_MODULE_${MODULE_NAME}_DESCR}")
|
set (ENABLE_MODULE TRUE)
|
||||||
|
set (BUILD_MODULE_${MODULE_NAME} ${ENABLE_MODULE} CACHE BOOL "${BUILD_MODULE_${MODULE_NAME}_DESCR}")
|
||||||
endmacro()
|
endmacro()
|
||||||
|
@@ -31,23 +31,27 @@ if (NOT DEFINED 3RDPARTY_VTK_INCLUDE_DIR)
|
|||||||
set (3RDPARTY_VTK_INCLUDE_DIR "" CACHE PATH "The directory containing headers of VTK")
|
set (3RDPARTY_VTK_INCLUDE_DIR "" CACHE PATH "The directory containing headers of VTK")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# vtk library directory
|
if (BUILD_SHARED_LIBS)
|
||||||
if (NOT DEFINED 3RDPARTY_VTK_LIBRARY_DIR)
|
# vtk library directory
|
||||||
set (3RDPARTY_VTK_LIBRARY_DIR "" CACHE PATH "The directory containing VTK libraries")
|
if (NOT DEFINED 3RDPARTY_VTK_LIBRARY_DIR)
|
||||||
endif()
|
set (3RDPARTY_VTK_LIBRARY_DIR "" CACHE PATH "The directory containing VTK libraries")
|
||||||
|
endif()
|
||||||
|
|
||||||
# vtk dll directory
|
# vtk dll directory
|
||||||
if (WIN32 AND NOT DEFINED 3RDPARTY_VTK_DLL_DIR)
|
if (WIN32 AND NOT DEFINED 3RDPARTY_VTK_DLL_DIR)
|
||||||
set (3RDPARTY_VTK_DLL_DIR "" CACHE PATH "The directory containing VTK shared libraries")
|
set (3RDPARTY_VTK_DLL_DIR "" CACHE PATH "The directory containing VTK shared libraries")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# check 3RDPARTY_VTK_ paths for consistency with specified 3RDPARTY_VTK_DIR
|
# check 3RDPARTY_VTK_ paths for consistency with specified 3RDPARTY_VTK_DIR
|
||||||
if (3RDPARTY_VTK_DIR AND EXISTS "${3RDPARTY_VTK_DIR}")
|
if (3RDPARTY_VTK_DIR AND EXISTS "${3RDPARTY_VTK_DIR}")
|
||||||
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_VTK_DIR 3RDPARTY_VTK_INCLUDE_DIR PATH "The directory containing headers of VTK")
|
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_VTK_DIR 3RDPARTY_VTK_INCLUDE_DIR PATH "The directory containing headers of VTK")
|
||||||
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_VTK_DIR 3RDPARTY_VTK_LIBRARY_DIR PATH "The directory containing VTK libraries")
|
if (BUILD_SHARED_LIBS)
|
||||||
|
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_VTK_DIR 3RDPARTY_VTK_LIBRARY_DIR PATH "The directory containing VTK libraries")
|
||||||
|
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_VTK_DIR 3RDPARTY_VTK_DLL_DIR PATH "The directory containing VTK shared library")
|
CHECK_PATH_FOR_CONSISTENCY (3RDPARTY_VTK_DIR 3RDPARTY_VTK_DLL_DIR PATH "The directory containing VTK shared library")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -70,8 +74,11 @@ if (VTK_FOUND)
|
|||||||
if (VTK_LIBRARIES)
|
if (VTK_LIBRARIES)
|
||||||
|
|
||||||
set (3RDPARTY_VTK_INCLUDE_DIRS)
|
set (3RDPARTY_VTK_INCLUDE_DIRS)
|
||||||
set (3RDPARTY_VTK_LIBRARY_DIRS)
|
|
||||||
set (3RDPARTY_VTK_DLL_DIRS)
|
if (BUILD_SHARED_LIBS)
|
||||||
|
set (3RDPARTY_VTK_LIBRARY_DIRS)
|
||||||
|
set (3RDPARTY_VTK_DLL_DIRS)
|
||||||
|
endif()
|
||||||
|
|
||||||
foreach (VTK_LIBRARY ${VTK_LIBRARIES})
|
foreach (VTK_LIBRARY ${VTK_LIBRARIES})
|
||||||
string (REGEX MATCH "^vtk" IS_VTK_LIBRARY ${VTK_LIBRARY})
|
string (REGEX MATCH "^vtk" IS_VTK_LIBRARY ${VTK_LIBRARY})
|
||||||
@@ -81,70 +88,71 @@ if (VTK_FOUND)
|
|||||||
list (APPEND 3RDPARTY_VTK_INCLUDE_DIRS "${${VTK_LIBRARY}_INCLUDE_DIRS}")
|
list (APPEND 3RDPARTY_VTK_INCLUDE_DIRS "${${VTK_LIBRARY}_INCLUDE_DIRS}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (${VTK_LIBRARY}_LIBRARY_DIRS AND EXISTS "${${VTK_LIBRARY}_LIBRARY_DIRS}")
|
if (${VTK_LIBRARY}_LIBRARY_DIRS AND EXISTS "${${VTK_LIBRARY}_LIBRARY_DIRS}")
|
||||||
list (APPEND 3RDPARTY_VTK_LIBRARY_DIRS "${${VTK_LIBRARY}_LIBRARY_DIRS}")
|
list (APPEND 3RDPARTY_VTK_LIBRARY_DIRS "${${VTK_LIBRARY}_LIBRARY_DIRS}")
|
||||||
endif()
|
|
||||||
|
|
||||||
if (${VTK_LIBRARY}_RUNTIME_LIBRARY_DIRS AND EXISTS "${${VTK_LIBRARY}_RUNTIME_LIBRARY_DIRS}")
|
|
||||||
list (APPEND 3RDPARTY_VTK_DLL_DIRS "${${VTK_LIBRARY}_RUNTIME_LIBRARY_DIRS}")
|
|
||||||
if (NOT WIN32)
|
|
||||||
list (APPEND 3RDPARTY_VTK_LIBRARY_DIRS "${${VTK_LIBRARY}_RUNTIME_LIBRARY_DIRS}")
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# get paths from corresponding properties
|
|
||||||
get_target_property (TARGET_VTK_IMPORT_CONFS ${VTK_LIBRARY} IMPORTED_CONFIGURATIONS)
|
|
||||||
|
|
||||||
if (TARGET_VTK_IMPORT_CONFS)
|
|
||||||
list (GET TARGET_VTK_IMPORT_CONFS 0 CHOSEN_IMPORT_CONF)
|
|
||||||
|
|
||||||
# todo: choose configuration in connection with the build type
|
|
||||||
#if (CMAKE_BUILD_TYPE)
|
|
||||||
# foreach (IMPORT_CONF ${TARGET_VTK_IMPORT_CONFS})
|
|
||||||
# endforeach()
|
|
||||||
#endif()
|
|
||||||
|
|
||||||
# Work-around against link failure in case if VTK contains dependency
|
|
||||||
# on DirectX: its run-time is always present on Windows, but SDK can
|
|
||||||
# be absent on current workstation, while not actually needed for
|
|
||||||
# OCCT linking.
|
|
||||||
# VTK 6.1 for VC 10
|
|
||||||
get_target_property (TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES ${VTK_LIBRARY} IMPORTED_LINK_INTERFACE_LIBRARIES_${CHOSEN_IMPORT_CONF})
|
|
||||||
if(TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES)
|
|
||||||
string (REGEX MATCH "[^;]*d3d[0-9]+[.]lib" HARDCODED_D3D9_LIB "${TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES}")
|
|
||||||
if (HARDCODED_D3D9_LIB)
|
|
||||||
message (STATUS "Warning: ${HARDCODED_D3D9_LIB} has been removed from imported dependencies of ${VTK_LIBRARY}")
|
|
||||||
|
|
||||||
list (REMOVE_ITEM TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES ${HARDCODED_D3D9_LIB})
|
|
||||||
set_target_properties (${VTK_LIBRARY} PROPERTIES IMPORTED_LINK_INTERFACE_LIBRARIES_${CHOSEN_IMPORT_CONF} "${TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES}")
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
# VTK 6.1 for VC 12, 14
|
|
||||||
get_target_property (TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES ${VTK_LIBRARY} INTERFACE_LINK_LIBRARIES)
|
|
||||||
if(TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES)
|
|
||||||
string (REGEX MATCH "[^;]*d3d[0-9]+[.]lib" HARDCODED_D3D9_LIB "${TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES}")
|
|
||||||
if (HARDCODED_D3D9_LIB)
|
|
||||||
message (STATUS "Warning: ${HARDCODED_D3D9_LIB} has been removed from imported dependencies of ${VTK_LIBRARY}")
|
|
||||||
|
|
||||||
list (REMOVE_ITEM TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES ${HARDCODED_D3D9_LIB})
|
|
||||||
set_target_properties (${VTK_LIBRARY} PROPERTIES INTERFACE_LINK_LIBRARIES "${TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES}")
|
|
||||||
endif()
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
get_target_property (TARGET_PROPERTY_IMP_PATH ${VTK_LIBRARY} IMPORTED_IMPLIB_${CHOSEN_IMPORT_CONF})
|
if (${VTK_LIBRARY}_RUNTIME_LIBRARY_DIRS AND EXISTS "${${VTK_LIBRARY}_RUNTIME_LIBRARY_DIRS}")
|
||||||
if(TARGET_PROPERTY_IMP_PATH AND EXISTS "${TARGET_PROPERTY_IMP_PATH}")
|
list (APPEND 3RDPARTY_VTK_DLL_DIRS "${${VTK_LIBRARY}_RUNTIME_LIBRARY_DIRS}")
|
||||||
get_filename_component (TARGET_PROPERTY_IMP_DIR "${TARGET_PROPERTY_IMP_PATH}" PATH)
|
if (NOT WIN32)
|
||||||
list (APPEND 3RDPARTY_VTK_LIBRARY_DIRS "${TARGET_PROPERTY_IMP_DIR}")
|
list (APPEND 3RDPARTY_VTK_LIBRARY_DIRS "${${VTK_LIBRARY}_RUNTIME_LIBRARY_DIRS}")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
get_target_property (TARGET_PROPERTY_LOCATION_PATH ${VTK_LIBRARY} IMPORTED_LOCATION_${CHOSEN_IMPORT_CONF})
|
# get paths from corresponding properties
|
||||||
if(TARGET_PROPERTY_LOCATION_PATH AND EXISTS "${TARGET_PROPERTY_LOCATION_PATH}")
|
get_target_property (TARGET_VTK_IMPORT_CONFS ${VTK_LIBRARY} IMPORTED_CONFIGURATIONS)
|
||||||
get_filename_component (TARGET_PROPERTY_LOCATION_DIR "${TARGET_PROPERTY_LOCATION_PATH}" PATH)
|
|
||||||
|
|
||||||
if (WIN32)
|
if (TARGET_VTK_IMPORT_CONFS)
|
||||||
list (APPEND 3RDPARTY_VTK_DLL_DIRS "${TARGET_PROPERTY_LOCATION_DIR}")
|
list (GET TARGET_VTK_IMPORT_CONFS 0 CHOSEN_IMPORT_CONF)
|
||||||
else()
|
|
||||||
list (APPEND 3RDPARTY_VTK_LIBRARY_DIRS "${TARGET_PROPERTY_LOCATION_DIR}")
|
# todo: choose configuration in connection with the build type
|
||||||
|
#if (CMAKE_BUILD_TYPE)
|
||||||
|
# foreach (IMPORT_CONF ${TARGET_VTK_IMPORT_CONFS})
|
||||||
|
# endforeach()
|
||||||
|
#endif()
|
||||||
|
|
||||||
|
# Work-around against link failure in case if VTK contains dependency
|
||||||
|
# on DirectX: its run-time is always present on Windows, but SDK can
|
||||||
|
# be absent on current workstation, while not actually needed for
|
||||||
|
# OCCT linking.
|
||||||
|
# VTK 6.1 for VC 10
|
||||||
|
get_target_property (TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES ${VTK_LIBRARY} IMPORTED_LINK_INTERFACE_LIBRARIES_${CHOSEN_IMPORT_CONF})
|
||||||
|
if(TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES)
|
||||||
|
string (REGEX MATCH "[^;]*d3d[0-9]+[.]lib" HARDCODED_D3D9_LIB "${TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES}")
|
||||||
|
if (HARDCODED_D3D9_LIB)
|
||||||
|
message (STATUS "Warning: ${HARDCODED_D3D9_LIB} has been removed from imported dependencies of ${VTK_LIBRARY}")
|
||||||
|
|
||||||
|
list (REMOVE_ITEM TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES ${HARDCODED_D3D9_LIB})
|
||||||
|
set_target_properties (${VTK_LIBRARY} PROPERTIES IMPORTED_LINK_INTERFACE_LIBRARIES_${CHOSEN_IMPORT_CONF} "${TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES}")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
# VTK 6.1 for VC 12, 14
|
||||||
|
get_target_property (TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES ${VTK_LIBRARY} INTERFACE_LINK_LIBRARIES)
|
||||||
|
if(TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES)
|
||||||
|
string (REGEX MATCH "[^;]*d3d[0-9]+[.]lib" HARDCODED_D3D9_LIB "${TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES}")
|
||||||
|
if (HARDCODED_D3D9_LIB)
|
||||||
|
message (STATUS "Warning: ${HARDCODED_D3D9_LIB} has been removed from imported dependencies of ${VTK_LIBRARY}")
|
||||||
|
|
||||||
|
list (REMOVE_ITEM TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES ${HARDCODED_D3D9_LIB})
|
||||||
|
set_target_properties (${VTK_LIBRARY} PROPERTIES INTERFACE_LINK_LIBRARIES "${TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES}")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
get_target_property (TARGET_PROPERTY_IMP_PATH ${VTK_LIBRARY} IMPORTED_IMPLIB_${CHOSEN_IMPORT_CONF})
|
||||||
|
if(TARGET_PROPERTY_IMP_PATH AND EXISTS "${TARGET_PROPERTY_IMP_PATH}")
|
||||||
|
get_filename_component (TARGET_PROPERTY_IMP_DIR "${TARGET_PROPERTY_IMP_PATH}" PATH)
|
||||||
|
list (APPEND 3RDPARTY_VTK_LIBRARY_DIRS "${TARGET_PROPERTY_IMP_DIR}")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
get_target_property (TARGET_PROPERTY_LOCATION_PATH ${VTK_LIBRARY} IMPORTED_LOCATION_${CHOSEN_IMPORT_CONF})
|
||||||
|
if(TARGET_PROPERTY_LOCATION_PATH AND EXISTS "${TARGET_PROPERTY_LOCATION_PATH}")
|
||||||
|
get_filename_component (TARGET_PROPERTY_LOCATION_DIR "${TARGET_PROPERTY_LOCATION_PATH}" PATH)
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
list (APPEND 3RDPARTY_VTK_DLL_DIRS "${TARGET_PROPERTY_LOCATION_DIR}")
|
||||||
|
else()
|
||||||
|
list (APPEND 3RDPARTY_VTK_LIBRARY_DIRS "${TARGET_PROPERTY_LOCATION_DIR}")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
@@ -160,24 +168,25 @@ if (VTK_FOUND)
|
|||||||
set (3RDPARTY_VTK_INCLUDE_DIR "${3RDPARTY_VTK_INCLUDE_DIR}" CACHE PATH "The directory containing headers of VTK" FORCE)
|
set (3RDPARTY_VTK_INCLUDE_DIR "${3RDPARTY_VTK_INCLUDE_DIR}" CACHE PATH "The directory containing headers of VTK" FORCE)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (3RDPARTY_VTK_LIBRARY_DIRS)
|
if (BUILD_SHARED_LIBS)
|
||||||
list (REMOVE_DUPLICATES 3RDPARTY_VTK_LIBRARY_DIRS)
|
if (3RDPARTY_VTK_LIBRARY_DIRS)
|
||||||
list (APPEND 3RDPARTY_LIBRARY_DIRS ${3RDPARTY_VTK_LIBRARY_DIRS})
|
list (REMOVE_DUPLICATES 3RDPARTY_VTK_LIBRARY_DIRS)
|
||||||
|
list (APPEND 3RDPARTY_LIBRARY_DIRS ${3RDPARTY_VTK_LIBRARY_DIRS})
|
||||||
|
|
||||||
list (GET 3RDPARTY_VTK_LIBRARY_DIRS 0 3RDPARTY_VTK_LIBRARY_DIR)
|
list (GET 3RDPARTY_VTK_LIBRARY_DIRS 0 3RDPARTY_VTK_LIBRARY_DIR)
|
||||||
set (3RDPARTY_VTK_LIBRARY_DIR "${3RDPARTY_VTK_LIBRARY_DIR}" CACHE PATH "The directory containing VTK libraries" FORCE)
|
set (3RDPARTY_VTK_LIBRARY_DIR "${3RDPARTY_VTK_LIBRARY_DIR}" CACHE PATH "The directory containing VTK libraries" FORCE)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
if (3RDPARTY_VTK_DLL_DIRS)
|
if (3RDPARTY_VTK_DLL_DIRS)
|
||||||
list (REMOVE_DUPLICATES 3RDPARTY_VTK_DLL_DIRS)
|
list (REMOVE_DUPLICATES 3RDPARTY_VTK_DLL_DIRS)
|
||||||
list (APPEND 3RDPARTY_DLL_DIRS ${3RDPARTY_VTK_DLL_DIRS})
|
list (APPEND 3RDPARTY_DLL_DIRS ${3RDPARTY_VTK_DLL_DIRS})
|
||||||
|
|
||||||
list (GET 3RDPARTY_VTK_DLL_DIRS 0 3RDPARTY_VTK_DLL_DIR)
|
list (GET 3RDPARTY_VTK_DLL_DIRS 0 3RDPARTY_VTK_DLL_DIR)
|
||||||
set (3RDPARTY_VTK_DLL_DIR "${3RDPARTY_VTK_DLL_DIR}" CACHE PATH "The directory containing VTK shared libraries" FORCE)
|
set (3RDPARTY_VTK_DLL_DIR "${3RDPARTY_VTK_DLL_DIR}" CACHE PATH "The directory containing VTK shared libraries" FORCE)
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
if (3RDPARTY_VTK_INCLUDE_DIR AND EXISTS "${3RDPARTY_VTK_INCLUDE_DIR}")
|
if (3RDPARTY_VTK_INCLUDE_DIR AND EXISTS "${3RDPARTY_VTK_INCLUDE_DIR}")
|
||||||
list (APPEND 3RDPARTY_INCLUDE_DIRS ${3RDPARTY_VTK_INCLUDE_DIR})
|
list (APPEND 3RDPARTY_INCLUDE_DIRS ${3RDPARTY_VTK_INCLUDE_DIR})
|
||||||
@@ -185,17 +194,19 @@ else()
|
|||||||
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_VTK_INCLUDE_DIR)
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_VTK_INCLUDE_DIR)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (3RDPARTY_VTK_LIBRARY_DIR AND EXISTS "${3RDPARTY_VTK_LIBRARY_DIR}")
|
if (BUILD_SHARED_LIBS)
|
||||||
list (APPEND 3RDPARTY_LIBRARY_DIRS ${3RDPARTY_VTK_LIBRARY_DIR})
|
if (3RDPARTY_VTK_LIBRARY_DIR AND EXISTS "${3RDPARTY_VTK_LIBRARY_DIR}")
|
||||||
else()
|
list (APPEND 3RDPARTY_LIBRARY_DIRS ${3RDPARTY_VTK_LIBRARY_DIR})
|
||||||
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_VTK_LIBRARY_DIR)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (WIN32)
|
|
||||||
if (3RDPARTY_VTK_DLL_DIR OR EXISTS "${3RDPARTY_VTK_DLL_DIR}")
|
|
||||||
list (APPEND 3RDPARTY_DLL_DIRS ${3RDPARTY_VTK_DLL_DIR})
|
|
||||||
else()
|
else()
|
||||||
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_VTK_DLL_DIR)
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_VTK_LIBRARY_DIR)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
if (3RDPARTY_VTK_DLL_DIR OR EXISTS "${3RDPARTY_VTK_DLL_DIR}")
|
||||||
|
list (APPEND 3RDPARTY_DLL_DIRS ${3RDPARTY_VTK_DLL_DIR})
|
||||||
|
else()
|
||||||
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_VTK_DLL_DIR)
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
@@ -127,11 +127,24 @@ proc wokdep:gui:UpdateList {} {
|
|||||||
wokdep:SearchTclTk anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
wokdep:SearchTclTk anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
wokdep:SearchFreeType anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
wokdep:SearchFreeType anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
wokdep:SearchX11 anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
wokdep:SearchX11 anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
|
if { "$::HAVE_GLES2" == "true" } {
|
||||||
|
if { "$::HAVE_GL2PS" == "true" } {
|
||||||
|
lappend anIncErrs "Error: gl2ps can not be used within OpenGL ES"
|
||||||
|
}
|
||||||
|
if { "$::HAVE_D3D" == "true" } {
|
||||||
|
lappend anIncErrs "Error: Direct3D can not be used within OpenGL ES"
|
||||||
|
}
|
||||||
|
wokdep:SearchEGL anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
|
wokdep:SearchGLES anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
|
}
|
||||||
if { "$::HAVE_FREEIMAGE" == "true" } {
|
if { "$::HAVE_FREEIMAGE" == "true" } {
|
||||||
wokdep:SearchFreeImage anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
wokdep:SearchFreeImage anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
}
|
}
|
||||||
|
if { "$::HAVE_FFMPEG" == "true" } {
|
||||||
|
wokdep:SearchFFmpeg anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
|
}
|
||||||
if { "$::HAVE_GL2PS" == "true" } {
|
if { "$::HAVE_GL2PS" == "true" } {
|
||||||
wokdep:SearchGL2PS anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
wokdep:SearchStandardLibrary anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs "gl2ps" "gl2ps.h" "gl2ps" {"gl2ps"}
|
||||||
}
|
}
|
||||||
if { "$::HAVE_TBB" == "true" } {
|
if { "$::HAVE_TBB" == "true" } {
|
||||||
wokdep:SearchTBB anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
wokdep:SearchTBB anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
@@ -142,6 +155,18 @@ proc wokdep:gui:UpdateList {} {
|
|||||||
if { "$::HAVE_VTK" == "true" } {
|
if { "$::HAVE_VTK" == "true" } {
|
||||||
wokdep:SearchVTK anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
wokdep:SearchVTK anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if { "$::HAVE_ZLIB" == "true" } {
|
||||||
|
wokdep:SearchStandardLibrary anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs "zlib" "zlib.h" "zlib" {"zlib"}
|
||||||
|
}
|
||||||
|
if { "$::HAVE_LIBLZMA" == "true" } {
|
||||||
|
set aCheckLib "lzma"
|
||||||
|
if { "$::tcl_platform(platform)" == "windows" } {
|
||||||
|
set aCheckLib "liblzma"
|
||||||
|
}
|
||||||
|
wokdep:SearchStandardLibrary anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs "liblzma" "lzma.h" "$aCheckLib" {"lzma" "xz"}
|
||||||
|
}
|
||||||
|
|
||||||
if { "$::CHECK_QT4" == "true" } {
|
if { "$::CHECK_QT4" == "true" } {
|
||||||
wokdep:SearchQt4 anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
wokdep:SearchQt4 anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
}
|
}
|
||||||
@@ -371,8 +396,8 @@ entry .myFrame.myVcVarsEntry -textvariable VCVARS -width 70
|
|||||||
ttk::button .myFrame.myVcBrowseBtn -text "Browse" -command wokdep:gui:BrowseVcVars
|
ttk::button .myFrame.myVcBrowseBtn -text "Browse" -command wokdep:gui:BrowseVcVars
|
||||||
|
|
||||||
#
|
#
|
||||||
checkbutton .myFrame.myHxxChecks.myScutsCheck -offvalue "false" -onvalue "true" -variable SHORTCUT_HEADERS
|
ttk::combobox .myFrame.myHxxChecks.myScutsCombo -values { {ShortCut} {Copy} {HardLink} } -textvariable SHORTCUT_HEADERS -state readonly -width 12
|
||||||
ttk::label .myFrame.myHxxChecks.myScutsLbl -text "Create short-cuts to headers in inc folder instead of copying"
|
ttk::label .myFrame.myHxxChecks.myScutsLbl -text "Strategy for filling headers folder inc:"
|
||||||
|
|
||||||
#
|
#
|
||||||
ttk::label .myFrame.mySrchLbl -text "3rd-parties search path:" -padding {5 5 80 5}
|
ttk::label .myFrame.mySrchLbl -text "3rd-parties search path:" -padding {5 5 80 5}
|
||||||
@@ -384,12 +409,28 @@ checkbutton .myFrame.myChecks.myGl2psCheck -offvalue "false" -onvalue "true
|
|||||||
ttk::label .myFrame.myChecks.myGl2psLbl -text "Use GL2PS"
|
ttk::label .myFrame.myChecks.myGl2psLbl -text "Use GL2PS"
|
||||||
checkbutton .myFrame.myChecks.myTbbCheck -offvalue "false" -onvalue "true" -variable HAVE_TBB -command wokdep:gui:UpdateList
|
checkbutton .myFrame.myChecks.myTbbCheck -offvalue "false" -onvalue "true" -variable HAVE_TBB -command wokdep:gui:UpdateList
|
||||||
ttk::label .myFrame.myChecks.myTbbLbl -text "Use Intel TBB"
|
ttk::label .myFrame.myChecks.myTbbLbl -text "Use Intel TBB"
|
||||||
|
if { "$::tcl_platform(os)" != "Darwin" } {
|
||||||
|
checkbutton .myFrame.myChecks.myGlesCheck -offvalue "false" -onvalue "true" -variable HAVE_GLES2 -command wokdep:gui:UpdateList
|
||||||
|
ttk::label .myFrame.myChecks.myGlesLbl -text "Use OpenGL ES"
|
||||||
|
}
|
||||||
|
if { "$::tcl_platform(platform)" == "windows" } {
|
||||||
|
checkbutton .myFrame.myChecks.myD3dCheck -offvalue "false" -onvalue "true" -variable HAVE_D3D -command wokdep:gui:UpdateList
|
||||||
|
ttk::label .myFrame.myChecks.myD3dLbl -text "Use Direct3D"
|
||||||
|
}
|
||||||
|
checkbutton .myFrame.myChecks.myFFmpegCheck -offvalue "false" -onvalue "true" -variable HAVE_FFMPEG -command wokdep:gui:UpdateList
|
||||||
|
ttk::label .myFrame.myChecks.myFFmpegLbl -text "Use FFmpeg"
|
||||||
#checkbutton .myFrame.myChecks.myOpenClCheck -offvalue "false" -onvalue "true" -variable HAVE_OPENCL -command wokdep:gui:UpdateList
|
#checkbutton .myFrame.myChecks.myOpenClCheck -offvalue "false" -onvalue "true" -variable HAVE_OPENCL -command wokdep:gui:UpdateList
|
||||||
#ttk::label .myFrame.myChecks.myOpenClLbl -text "Use OpenCL"
|
#ttk::label .myFrame.myChecks.myOpenClLbl -text "Use OpenCL"
|
||||||
checkbutton .myFrame.myChecks.myMacGLXCheck -offvalue "false" -onvalue "true" -variable MACOSX_USE_GLX
|
checkbutton .myFrame.myChecks.myMacGLXCheck -offvalue "false" -onvalue "true" -variable MACOSX_USE_GLX
|
||||||
ttk::label .myFrame.myChecks.myMacGLXLbl -text "Use X11 for windows drawing"
|
ttk::label .myFrame.myChecks.myMacGLXLbl -text "Use X11 for windows drawing"
|
||||||
ttk::label .myFrame.myChecks.myVtkLbl -text "Use VTK"
|
ttk::label .myFrame.myChecks.myVtkLbl -text "Use VTK"
|
||||||
checkbutton .myFrame.myChecks.myVtkCheck -offvalue "false" -onvalue "true" -variable HAVE_VTK -command wokdep:gui:UpdateList
|
checkbutton .myFrame.myChecks.myVtkCheck -offvalue "false" -onvalue "true" -variable HAVE_VTK -command wokdep:gui:UpdateList
|
||||||
|
|
||||||
|
checkbutton .myFrame.myChecks.myZLibCheck -offvalue "false" -onvalue "true" -variable HAVE_ZLIB -command wokdep:gui:UpdateList
|
||||||
|
ttk::label .myFrame.myChecks.myZLibLbl -text "Use zlib"
|
||||||
|
checkbutton .myFrame.myChecks.myLzmaCheck -offvalue "false" -onvalue "true" -variable HAVE_LIBLZMA -command wokdep:gui:UpdateList
|
||||||
|
ttk::label .myFrame.myChecks.myLzmaLbl -text "Use liblzma"
|
||||||
|
|
||||||
checkbutton .myFrame.myChecks.myQt4Check -offvalue "false" -onvalue "true" -variable CHECK_QT4 -command wokdep:gui:UpdateList
|
checkbutton .myFrame.myChecks.myQt4Check -offvalue "false" -onvalue "true" -variable CHECK_QT4 -command wokdep:gui:UpdateList
|
||||||
ttk::label .myFrame.myChecks.myQt4Lbl -text "Search Qt4"
|
ttk::label .myFrame.myChecks.myQt4Lbl -text "Search Qt4"
|
||||||
checkbutton .myFrame.myChecks.myJDKCheck -offvalue "false" -onvalue "true" -variable CHECK_JDK -command wokdep:gui:UpdateList
|
checkbutton .myFrame.myChecks.myJDKCheck -offvalue "false" -onvalue "true" -variable CHECK_JDK -command wokdep:gui:UpdateList
|
||||||
@@ -465,8 +506,8 @@ if { "$tcl_platform(platform)" == "windows" } {
|
|||||||
|
|
||||||
#
|
#
|
||||||
grid .myFrame.myHxxChecks -row $aRowIter -column 0 -columnspan 10 -sticky w
|
grid .myFrame.myHxxChecks -row $aRowIter -column 0 -columnspan 10 -sticky w
|
||||||
grid .myFrame.myHxxChecks.myScutsCheck -row 0 -column 0
|
grid .myFrame.myHxxChecks.myScutsLbl -row 0 -column 0
|
||||||
grid .myFrame.myHxxChecks.myScutsLbl -row 0 -column 1
|
grid .myFrame.myHxxChecks.myScutsCombo -row 0 -column 1
|
||||||
incr aRowIter
|
incr aRowIter
|
||||||
#
|
#
|
||||||
grid .myFrame.mySrchLbl -row $aRowIter -column 0 -columnspan 10 -sticky w
|
grid .myFrame.mySrchLbl -row $aRowIter -column 0 -columnspan 10 -sticky w
|
||||||
@@ -481,17 +522,35 @@ grid .myFrame.myChecks.myFImageCheck -row $aCheckRowIter -column 0 -sticky e
|
|||||||
grid .myFrame.myChecks.myFImageLbl -row $aCheckRowIter -column 1 -sticky w
|
grid .myFrame.myChecks.myFImageLbl -row $aCheckRowIter -column 1 -sticky w
|
||||||
grid .myFrame.myChecks.myTbbCheck -row $aCheckRowIter -column 2 -sticky e
|
grid .myFrame.myChecks.myTbbCheck -row $aCheckRowIter -column 2 -sticky e
|
||||||
grid .myFrame.myChecks.myTbbLbl -row $aCheckRowIter -column 3 -sticky w
|
grid .myFrame.myChecks.myTbbLbl -row $aCheckRowIter -column 3 -sticky w
|
||||||
grid .myFrame.myChecks.myQt4Check -row $aCheckRowIter -column 4 -sticky e
|
if { "$::tcl_platform(os)" != "Darwin" } {
|
||||||
grid .myFrame.myChecks.myQt4Lbl -row $aCheckRowIter -column 5 -sticky w
|
grid .myFrame.myChecks.myGlesCheck -row $aCheckRowIter -column 4 -sticky e
|
||||||
|
grid .myFrame.myChecks.myGlesLbl -row $aCheckRowIter -column 5 -sticky w
|
||||||
|
}
|
||||||
#grid .myFrame.myChecks.myOpenClCheck -row $aCheckRowIter -column 6 -sticky e
|
#grid .myFrame.myChecks.myOpenClCheck -row $aCheckRowIter -column 6 -sticky e
|
||||||
#grid .myFrame.myChecks.myOpenClLbl -row $aCheckRowIter -column 7 -sticky w
|
#grid .myFrame.myChecks.myOpenClLbl -row $aCheckRowIter -column 7 -sticky w
|
||||||
|
grid .myFrame.myChecks.myZLibCheck -row $aCheckRowIter -column 6 -sticky e
|
||||||
|
grid .myFrame.myChecks.myZLibLbl -row $aCheckRowIter -column 7 -sticky w
|
||||||
|
|
||||||
|
grid .myFrame.myChecks.myGl2psCheck -row $aCheckRowIter -column 8 -sticky e
|
||||||
|
grid .myFrame.myChecks.myGl2psLbl -row $aCheckRowIter -column 9 -sticky w
|
||||||
|
|
||||||
|
grid .myFrame.myChecks.myQt4Check -row $aCheckRowIter -column 10 -sticky e
|
||||||
|
grid .myFrame.myChecks.myQt4Lbl -row $aCheckRowIter -column 11 -sticky w
|
||||||
|
|
||||||
incr aCheckRowIter
|
incr aCheckRowIter
|
||||||
grid .myFrame.myChecks.myGl2psCheck -row $aCheckRowIter -column 0 -sticky e
|
grid .myFrame.myChecks.myFFmpegCheck -row $aCheckRowIter -column 0 -sticky e
|
||||||
grid .myFrame.myChecks.myGl2psLbl -row $aCheckRowIter -column 1 -sticky w
|
grid .myFrame.myChecks.myFFmpegLbl -row $aCheckRowIter -column 1 -sticky w
|
||||||
grid .myFrame.myChecks.myVtkCheck -row $aCheckRowIter -column 2 -sticky e
|
grid .myFrame.myChecks.myVtkCheck -row $aCheckRowIter -column 2 -sticky e
|
||||||
grid .myFrame.myChecks.myVtkLbl -row $aCheckRowIter -column 3 -sticky w
|
grid .myFrame.myChecks.myVtkLbl -row $aCheckRowIter -column 3 -sticky w
|
||||||
grid .myFrame.myChecks.myJDKCheck -row $aCheckRowIter -column 4 -sticky e
|
if { "$::tcl_platform(platform)" == "windows" } {
|
||||||
grid .myFrame.myChecks.myJDKLbl -row $aCheckRowIter -column 5 -sticky w
|
grid .myFrame.myChecks.myD3dCheck -row $aCheckRowIter -column 4 -sticky e
|
||||||
|
grid .myFrame.myChecks.myD3dLbl -row $aCheckRowIter -column 5 -sticky w
|
||||||
|
}
|
||||||
|
grid .myFrame.myChecks.myLzmaCheck -row $aCheckRowIter -column 6 -sticky e
|
||||||
|
grid .myFrame.myChecks.myLzmaLbl -row $aCheckRowIter -column 7 -sticky w
|
||||||
|
grid .myFrame.myChecks.myJDKCheck -row $aCheckRowIter -column 10 -sticky e
|
||||||
|
grid .myFrame.myChecks.myJDKLbl -row $aCheckRowIter -column 11 -sticky w
|
||||||
|
|
||||||
incr aCheckRowIter
|
incr aCheckRowIter
|
||||||
if { "$::tcl_platform(os)" == "Darwin" } {
|
if { "$::tcl_platform(os)" == "Darwin" } {
|
||||||
grid .myFrame.myChecks.myMacGLXCheck -row $aCheckRowIter -column 0 -sticky e
|
grid .myFrame.myChecks.myMacGLXCheck -row $aCheckRowIter -column 0 -sticky e
|
||||||
|
@@ -41,16 +41,8 @@ if { "$tcl_platform(platform)" == "unix" } {
|
|||||||
set VCVARS ""
|
set VCVARS ""
|
||||||
}
|
}
|
||||||
|
|
||||||
set SHORTCUT_HEADERS "true"
|
set SHORTCUT_HEADERS "ShortCut"
|
||||||
|
|
||||||
set HAVE_FREEIMAGE "false"
|
|
||||||
set HAVE_GL2PS "false"
|
|
||||||
set HAVE_TBB "false"
|
|
||||||
set HAVE_OPENCL "false"
|
|
||||||
set HAVE_VTK "false"
|
|
||||||
set MACOSX_USE_GLX "false"
|
|
||||||
set CHECK_QT4 "false"
|
|
||||||
set CHECK_JDK "false"
|
|
||||||
set PRODUCTS_PATH ""
|
set PRODUCTS_PATH ""
|
||||||
set CSF_OPT_INC [list]
|
set CSF_OPT_INC [list]
|
||||||
set CSF_OPT_LIB32 [list]
|
set CSF_OPT_LIB32 [list]
|
||||||
@@ -64,42 +56,37 @@ if { "$tcl_platform(pointerSize)" == "4" } {
|
|||||||
if { [info exists ::env(ARCH)] } {
|
if { [info exists ::env(ARCH)] } {
|
||||||
set ARCH "$::env(ARCH)"
|
set ARCH "$::env(ARCH)"
|
||||||
}
|
}
|
||||||
if { [info exists ::env(VCVER)] } {
|
|
||||||
set VCVER "$::env(VCVER)"
|
|
||||||
}
|
|
||||||
if { [info exists ::env(VCVARS)] } {
|
|
||||||
set VCVARS "$::env(VCVARS)"
|
|
||||||
}
|
|
||||||
if { [info exists ::env(SHORTCUT_HEADERS)] } {
|
if { [info exists ::env(SHORTCUT_HEADERS)] } {
|
||||||
set SHORTCUT_HEADERS "$::env(SHORTCUT_HEADERS)"
|
set SHORTCUT_HEADERS "$::env(SHORTCUT_HEADERS)"
|
||||||
|
if { $SHORTCUT_HEADERS == "true" } {
|
||||||
|
set SHORTCUT_HEADERS "ShortCut"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if { [info exists ::env(HAVE_FREEIMAGE)] } {
|
|
||||||
set HAVE_FREEIMAGE "$::env(HAVE_FREEIMAGE)"
|
# fetch environment variables (e.g. set by custom.sh or custom.bat) and set them as tcl variables with the same name
|
||||||
|
set THE_ENV_VARIABLES {HAVE_FREEIMAGE HAVE_FFMPEG HAVE_TBB HAVE_GLES2 HAVE_D3D HAVE_VTK HAVE_GL2PS HAVE_ZLIB HAVE_LIBLZMA HAVE_OPENCL CHECK_QT4 CHECK_JDK MACOSX_USE_GLX}
|
||||||
|
foreach anEnvIter $THE_ENV_VARIABLES {
|
||||||
|
set ${anEnvIter} "false"
|
||||||
|
if { [info exists ::env(${anEnvIter})] } {
|
||||||
|
set ${anEnvIter} "$::env(${anEnvIter})"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if { [info exists ::env(HAVE_GL2PS)] } {
|
# do not export platform-specific variables
|
||||||
set HAVE_GL2PS "$::env(HAVE_GL2PS)"
|
if { "$::tcl_platform(os)" == "Darwin" } {
|
||||||
|
set HAVE_GLES2 ""
|
||||||
|
} else {
|
||||||
|
set MACOSX_USE_GLX ""
|
||||||
|
if { "$tcl_platform(platform)" != "windows" } {
|
||||||
|
set HAVE_D3D ""
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if { [info exists ::env(HAVE_TBB)] } {
|
foreach anEnvIter {ARCH VCVER VCVARS PRODUCTS_PATH} {
|
||||||
set HAVE_TBB "$::env(HAVE_TBB)"
|
if { [info exists ::env(${anEnvIter})] } {
|
||||||
}
|
set ${anEnvIter} "$::env(${anEnvIter})"
|
||||||
if { [info exists ::env(HAVE_OPENCL)] } {
|
}
|
||||||
set HAVE_OPENCL "$::env(HAVE_OPENCL)"
|
|
||||||
}
|
|
||||||
if { [info exists ::env(HAVE_VTK)] } {
|
|
||||||
set HAVE_VTK "$::env(HAVE_VTK)"
|
|
||||||
}
|
|
||||||
if { [info exists ::env(MACOSX_USE_GLX)] } {
|
|
||||||
set MACOSX_USE_GLX "$::env(MACOSX_USE_GLX)"
|
|
||||||
}
|
|
||||||
if { [info exists ::env(CHECK_QT4)] } {
|
|
||||||
set CHECK_QT4 "$::env(CHECK_QT4)"
|
|
||||||
}
|
|
||||||
if { [info exists ::env(CHECK_JDK)] } {
|
|
||||||
set CHECK_JDK "$::env(CHECK_JDK)"
|
|
||||||
}
|
|
||||||
if { [info exists ::env(PRODUCTS_PATH)] } {
|
|
||||||
set PRODUCTS_PATH "$::env(PRODUCTS_PATH)"
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if { [info exists ::env(CSF_OPT_INC)] } {
|
if { [info exists ::env(CSF_OPT_INC)] } {
|
||||||
set CSF_OPT_INC [split "$::env(CSF_OPT_INC)" $::SYS_PATH_SPLITTER]
|
set CSF_OPT_INC [split "$::env(CSF_OPT_INC)" $::SYS_PATH_SPLITTER]
|
||||||
}
|
}
|
||||||
@@ -241,6 +228,83 @@ proc wokdep:Preferred {theList theCmpl theArch} {
|
|||||||
return [lindex [lsort -decreasing $aVeryShortList] 0]
|
return [lindex [lsort -decreasing $aVeryShortList] 0]
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Search library placement
|
||||||
|
proc wokdep:SearchStandardLibrary {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64 theName theCheckHeader theCheckLib theCheckFolders} {
|
||||||
|
upvar $theErrInc anErrInc
|
||||||
|
upvar $theErrLib32 anErrLib32
|
||||||
|
upvar $theErrLib64 anErrLib64
|
||||||
|
upvar $theErrBin32 anErrBin32
|
||||||
|
upvar $theErrBin64 anErrBin64
|
||||||
|
|
||||||
|
set isFound "true"
|
||||||
|
set aHeaderPath [wokdep:SearchHeader "$theCheckHeader"]
|
||||||
|
if { "$aHeaderPath" == "" } {
|
||||||
|
set hasHeader false
|
||||||
|
foreach aFolderIter $theCheckFolders {
|
||||||
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{$aFolderIter}*] "$::VCVER" "$::ARCH" ]
|
||||||
|
if { "$aPath" != "" && [file exists "$aPath/include/$theCheckHeader"] } {
|
||||||
|
lappend ::CSF_OPT_INC "$aPath/include"
|
||||||
|
set hasHeader true
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if { !$hasHeader } {
|
||||||
|
lappend anErrInc "Error: '$theCheckHeader' not found ($theName)"
|
||||||
|
set isFound "false"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach anArchIter {64 32} {
|
||||||
|
set aLibPath [wokdep:SearchLib "$theCheckLib" "$anArchIter"]
|
||||||
|
if { "$aLibPath" == "" } {
|
||||||
|
set hasLib false
|
||||||
|
foreach aFolderIter $theCheckFolders {
|
||||||
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{$aFolderIter}*] "$::VCVER" "$anArchIter" ]
|
||||||
|
set aLibPath [wokdep:SearchLib "$theCheckLib" "$anArchIter" "$aPath/lib"]
|
||||||
|
if { "$aLibPath" != "" } {
|
||||||
|
lappend ::CSF_OPT_LIB$anArchIter "$aPath/lib"
|
||||||
|
lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin"
|
||||||
|
set hasLib true
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if { !$hasLib } {
|
||||||
|
lappend anErrLib$anArchIter "Error: '${::SYS_LIB_PREFIX}$theCheckLib.${::SYS_LIB_SUFFIX}' not found ($theName)"
|
||||||
|
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if { "$::tcl_platform(platform)" == "windows" } {
|
||||||
|
set aDllPath [wokdep:SearchBin "$theCheckLib.dll" "$anArchIter"]
|
||||||
|
if { "$aDllPath" == "" } {
|
||||||
|
set hasDll false
|
||||||
|
foreach aFolderIter $theCheckFolders {
|
||||||
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{$aFolderIter}*] "$::VCVER" "$anArchIter" ]
|
||||||
|
set aDllPath [wokdep:SearchBin "$theCheckLib.dll" "$anArchIter" "$aPath/bin"]
|
||||||
|
if { "$aDllPath" != "" } {
|
||||||
|
lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin"
|
||||||
|
set hasDll true
|
||||||
|
break
|
||||||
|
} else {
|
||||||
|
set aDllPath [wokdep:SearchBin "$theCheckLib.dll" "$anArchIter" "$aPath/lib"]
|
||||||
|
if { "$aDllPath" != "" } {
|
||||||
|
lappend ::CSF_OPT_BIN$anArchIter "$aPath/lib"
|
||||||
|
set hasDll true
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if { !$hasDll } {
|
||||||
|
lappend anErrBin$anArchIter "Error: '$theCheckLib.dll' not found ($theName)"
|
||||||
|
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return "$isFound"
|
||||||
|
}
|
||||||
|
|
||||||
# Search Tcl/Tk libraries placement
|
# Search Tcl/Tk libraries placement
|
||||||
proc wokdep:SearchTclTk {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64} {
|
proc wokdep:SearchTclTk {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64} {
|
||||||
upvar $theErrInc anErrInc
|
upvar $theErrInc anErrInc
|
||||||
@@ -423,7 +487,6 @@ proc wokdep:SearchFreeImage {theErrInc theErrLib32 theErrLib64 theErrBin32 theEr
|
|||||||
|
|
||||||
# binary distribution has another layout
|
# binary distribution has another layout
|
||||||
set aFImageDist "Dist"
|
set aFImageDist "Dist"
|
||||||
set aFImagePlusDist "Wrapper/FreeImagePlus/dist"
|
|
||||||
|
|
||||||
set isFound "true"
|
set isFound "true"
|
||||||
set aFImageHPath [wokdep:SearchHeader "FreeImage.h"]
|
set aFImageHPath [wokdep:SearchHeader "FreeImage.h"]
|
||||||
@@ -433,21 +496,12 @@ proc wokdep:SearchFreeImage {theErrInc theErrLib32 theErrLib64 theErrBin32 theEr
|
|||||||
lappend ::CSF_OPT_INC "$aPath/include"
|
lappend ::CSF_OPT_INC "$aPath/include"
|
||||||
} elseif { "$aPath" != "" && [file exists "$aPath/$aFImageDist/FreeImage.h"] } {
|
} elseif { "$aPath" != "" && [file exists "$aPath/$aFImageDist/FreeImage.h"] } {
|
||||||
lappend ::CSF_OPT_INC "$aPath/$aFImageDist"
|
lappend ::CSF_OPT_INC "$aPath/$aFImageDist"
|
||||||
if { [file exists "$aPath/$aFImagePlusDist/FreeImagePlus.h"] } {
|
|
||||||
lappend ::CSF_OPT_INC "$aPath/$aFImagePlusDist"
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
lappend anErrInc "Error: 'FreeImage.h' not found (FreeImage)"
|
lappend anErrInc "Error: 'FreeImage.h' not found (FreeImage)"
|
||||||
set isFound "false"
|
set isFound "false"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
set aFImagePlusHPath [wokdep:SearchHeader "FreeImagePlus.h"]
|
|
||||||
if { "$::tcl_platform(platform)" == "windows" && "$aFImagePlusHPath" == "" } {
|
|
||||||
lappend anErrInc "Error: 'FreeImagePlus.h' not found (FreeImage)"
|
|
||||||
set isFound "false"
|
|
||||||
}
|
|
||||||
|
|
||||||
foreach anArchIter {64 32} {
|
foreach anArchIter {64 32} {
|
||||||
set aFImageLibPath [wokdep:SearchLib "freeimage" "$anArchIter"]
|
set aFImageLibPath [wokdep:SearchLib "freeimage" "$anArchIter"]
|
||||||
if { "$aFImageLibPath" == "" } {
|
if { "$aFImageLibPath" == "" } {
|
||||||
@@ -459,10 +513,6 @@ proc wokdep:SearchFreeImage {theErrInc theErrLib32 theErrLib64 theErrBin32 theEr
|
|||||||
set aFImageLibPath [wokdep:SearchLib "freeimage" "$anArchIter" "$aPath/$aFImageDist"]
|
set aFImageLibPath [wokdep:SearchLib "freeimage" "$anArchIter" "$aPath/$aFImageDist"]
|
||||||
if { "$aFImageLibPath" != "" } {
|
if { "$aFImageLibPath" != "" } {
|
||||||
lappend ::CSF_OPT_LIB$anArchIter "$aPath/$aFImageDist"
|
lappend ::CSF_OPT_LIB$anArchIter "$aPath/$aFImageDist"
|
||||||
set aFImagePlusLibPath [wokdep:SearchLib "freeimageplus" "$anArchIter" "$aPath/$aFImagePlusDist"]
|
|
||||||
if { "$aFImagePlusLibPath" != "" } {
|
|
||||||
lappend ::CSF_OPT_LIB$anArchIter "$aPath/$aFImagePlusDist"
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
lappend anErrLib$anArchIter "Error: '${::SYS_LIB_PREFIX}freeimage.${::SYS_LIB_SUFFIX}' not found (FreeImage)"
|
lappend anErrLib$anArchIter "Error: '${::SYS_LIB_PREFIX}freeimage.${::SYS_LIB_SUFFIX}' not found (FreeImage)"
|
||||||
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
||||||
@@ -470,28 +520,18 @@ proc wokdep:SearchFreeImage {theErrInc theErrLib32 theErrLib64 theErrBin32 theEr
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if { "$::tcl_platform(platform)" == "windows" } {
|
if { "$::tcl_platform(platform)" == "windows" } {
|
||||||
set aFImagePlusLibPath [wokdep:SearchLib "freeimageplus" "$anArchIter"]
|
set aFImageDllPath [wokdep:SearchBin "freeimage.dll" "$anArchIter"]
|
||||||
if { "$aFImagePlusLibPath" == "" } {
|
if { "$aFImageDllPath" == "" } {
|
||||||
lappend anErrLib$anArchIter "Error: '${::SYS_LIB_PREFIX}freeimageplus.${::SYS_LIB_SUFFIX}' not found (FreeImage)"
|
|
||||||
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
|
||||||
}
|
|
||||||
|
|
||||||
set aFImageDllPath [wokdep:SearchBin "freeimage.dll" "$anArchIter"]
|
|
||||||
set aFImagePlusDllPath [wokdep:SearchBin "freeimageplus.dll" "$anArchIter"]
|
|
||||||
if { "$aFImageDllPath" == "" || "$aFImagePlusDllPath" == "" } {
|
|
||||||
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{freeimage}*] "$::VCVER" "$anArchIter" ]
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{freeimage}*] "$::VCVER" "$anArchIter" ]
|
||||||
set aFImageDllPath [wokdep:SearchBin "freeimage.dll" "$anArchIter" "$aPath/bin"]
|
set aFImageDllPath [wokdep:SearchBin "freeimage.dll" "$anArchIter" "$aPath/bin"]
|
||||||
set aFImagePlusDllPath [wokdep:SearchBin "freeimageplus.dll" "$anArchIter" "$aPath/bin"]
|
if { "$aFImageDllPath" != "" } {
|
||||||
if { "$aFImageDllPath" != "" && "$aFImagePlusDllPath" != "" } {
|
|
||||||
lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin"
|
lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin"
|
||||||
} else {
|
} else {
|
||||||
set aFImageDllPath [wokdep:SearchBin "freeimage.dll" "$anArchIter" "$aPath/$aFImageDist"]
|
set aFImageDllPath [wokdep:SearchBin "freeimage.dll" "$anArchIter" "$aPath/$aFImageDist"]
|
||||||
set aFImagePlusDllPath [wokdep:SearchBin "freeimageplus.dll" "$anArchIter" "$aPath/$aFImagePlusDist"]
|
if { "$aFImageDllPath" != "" } {
|
||||||
if { "$aFImageDllPath" != "" && "$aFImagePlusDllPath" != "" } {
|
|
||||||
lappend ::CSF_OPT_BIN$anArchIter "$aPath/$aFImageDist"
|
lappend ::CSF_OPT_BIN$anArchIter "$aPath/$aFImageDist"
|
||||||
lappend ::CSF_OPT_BIN$anArchIter "$aPath/$aFImagePlusDist"
|
|
||||||
} else {
|
} else {
|
||||||
lappend anErrBin$anArchIter "Error: 'freeimage.dll' or 'freeimageplus.dll' not found (FreeImage)"
|
lappend anErrBin$anArchIter "Error: 'freeimage.dll' is not found (FreeImage)"
|
||||||
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -502,8 +542,8 @@ proc wokdep:SearchFreeImage {theErrInc theErrLib32 theErrLib64 theErrBin32 theEr
|
|||||||
return "$isFound"
|
return "$isFound"
|
||||||
}
|
}
|
||||||
|
|
||||||
# Search GL2PS library placement
|
# Search FFmpeg framework placement
|
||||||
proc wokdep:SearchGL2PS {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64} {
|
proc wokdep:SearchFFmpeg {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64} {
|
||||||
upvar $theErrInc anErrInc
|
upvar $theErrInc anErrInc
|
||||||
upvar $theErrLib32 anErrLib32
|
upvar $theErrLib32 anErrLib32
|
||||||
upvar $theErrLib64 anErrLib64
|
upvar $theErrLib64 anErrLib64
|
||||||
@@ -511,47 +551,30 @@ proc wokdep:SearchGL2PS {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin
|
|||||||
upvar $theErrBin64 anErrBin64
|
upvar $theErrBin64 anErrBin64
|
||||||
|
|
||||||
set isFound "true"
|
set isFound "true"
|
||||||
set aGl2psHPath [wokdep:SearchHeader "gl2ps.h"]
|
set aFFmpegHPath [wokdep:SearchHeader "libavutil/avutil.h"]
|
||||||
if { "$aGl2psHPath" == "" } {
|
if { "$aFFmpegHPath" == "" } {
|
||||||
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{gl2ps}*] "$::VCVER" "$::ARCH" ]
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{ffmpeg}*] "$::VCVER" "$::ARCH" ]
|
||||||
if { "$aPath" != "" && [file exists "$aPath/include/gl2ps.h"] } {
|
if { "$aPath" != "" && [file exists "$aPath/include/libavutil/avutil.h"] } {
|
||||||
lappend ::CSF_OPT_INC "$aPath/include"
|
lappend ::CSF_OPT_INC "$aPath/include"
|
||||||
} else {
|
} else {
|
||||||
lappend anErrInc "Error: 'gl2ps.h' not found (GL2PS)"
|
lappend anErrInc "Error: 'libavutil/avutil.h' not found (FFmpeg)"
|
||||||
set isFound "false"
|
set isFound "false"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
foreach anArchIter {64 32} {
|
foreach anArchIter {64 32} {
|
||||||
set aGl2psLibPath [wokdep:SearchLib "gl2ps" "$anArchIter"]
|
set aFFmpegLibPath [wokdep:SearchLib "avutil" "$anArchIter"]
|
||||||
if { "$aGl2psLibPath" == "" } {
|
if { "$aFFmpegLibPath" == "" } {
|
||||||
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{gl2ps}*] "$::VCVER" "$anArchIter" ]
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{ffmpeg}*] "$::VCVER" "$anArchIter" ]
|
||||||
set aGl2psLibPath [wokdep:SearchLib "gl2ps" "$anArchIter" "$aPath/lib"]
|
set aFFmpegLibPath [wokdep:SearchLib "avutil" "$anArchIter" "$aPath/lib"]
|
||||||
if { "$aGl2psLibPath" != "" } {
|
if { "$aFFmpegLibPath" != "" } {
|
||||||
lappend ::CSF_OPT_LIB$anArchIter "$aPath/lib"
|
lappend ::CSF_OPT_LIB$anArchIter "$aPath/lib"
|
||||||
|
lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin"
|
||||||
} else {
|
} else {
|
||||||
lappend anErrLib$anArchIter "Error: '${::SYS_LIB_PREFIX}gl2ps.${::SYS_LIB_SUFFIX}' not found (GL2PS)"
|
lappend anErrLib$anArchIter "Error: '${::SYS_LIB_PREFIX}avutil.${::SYS_LIB_SUFFIX}' not found (FFmpeg)"
|
||||||
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if { "$::tcl_platform(platform)" == "windows" } {
|
|
||||||
set aGl2psDllPath [wokdep:SearchBin "gl2ps.dll" "$anArchIter"]
|
|
||||||
if { "$aGl2psDllPath" == "" } {
|
|
||||||
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{gl2ps}*] "$::VCVER" "$anArchIter" ]
|
|
||||||
set aGl2psDllPath [wokdep:SearchBin "gl2ps.dll" "$anArchIter" "$aPath/bin"]
|
|
||||||
if { "$aGl2psDllPath" != "" } {
|
|
||||||
lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin"
|
|
||||||
} else {
|
|
||||||
set aGl2psDllPath [wokdep:SearchBin "gl2ps.dll" "$anArchIter" "$aPath/lib"]
|
|
||||||
if { "$aGl2psDllPath" != "" } {
|
|
||||||
lappend ::CSF_OPT_BIN$anArchIter "$aPath/lib"
|
|
||||||
} else {
|
|
||||||
lappend anErrBin$anArchIter "Error: 'gl2ps.dll' not found (GL2PS)"
|
|
||||||
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return "$isFound"
|
return "$isFound"
|
||||||
@@ -664,6 +687,148 @@ proc wokdep:SearchOpenCL {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBi
|
|||||||
return "$isFound"
|
return "$isFound"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Search EGL library placement
|
||||||
|
proc wokdep:SearchEGL {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64} {
|
||||||
|
upvar $theErrInc anErrInc
|
||||||
|
upvar $theErrLib32 anErrLib32
|
||||||
|
upvar $theErrLib64 anErrLib64
|
||||||
|
upvar $theErrBin32 anErrBin32
|
||||||
|
upvar $theErrBin64 anErrBin64
|
||||||
|
|
||||||
|
set isFound "true"
|
||||||
|
set aHeaderPath [wokdep:SearchHeader "EGL/egl.h"]
|
||||||
|
if { "$aHeaderPath" == "" } {
|
||||||
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{EGL}*] "$::VCVER" "$::ARCH" ]
|
||||||
|
if { "$aPath" == "" || ![file exists "$aPath/include/EGL/egl.h"] } {
|
||||||
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{angle}*] "$::VCVER" "$::ARCH" ]
|
||||||
|
}
|
||||||
|
|
||||||
|
if { "$aPath" != "" && [file exists "$aPath/include/EGL/egl.h"] } {
|
||||||
|
lappend ::CSF_OPT_INC "$aPath/include"
|
||||||
|
} else {
|
||||||
|
lappend anErrInc "Error: 'EGL/egl.h' not found (EGL)"
|
||||||
|
set isFound "false"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
set aLibName "EGL"
|
||||||
|
if { "$::tcl_platform(platform)" == "windows" } {
|
||||||
|
# awkward exception
|
||||||
|
set aLibName "libEGL"
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach anArchIter {64 32} {
|
||||||
|
set aLibPath [wokdep:SearchLib "$aLibName" "$anArchIter"]
|
||||||
|
if { "$aLibPath" == "" } {
|
||||||
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{EGL}*] "$::VCVER" "$anArchIter" ]
|
||||||
|
set aLibPath [wokdep:SearchLib "$aLibName" "$anArchIter" "$aPath/lib"]
|
||||||
|
if { "$aLibPath" == "" } {
|
||||||
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{angle}*] "$::VCVER" "$anArchIter" ]
|
||||||
|
set aLibPath [wokdep:SearchLib "$aLibName" "$anArchIter" "$aPath/lib"]
|
||||||
|
}
|
||||||
|
|
||||||
|
if { "$aLibPath" != "" } {
|
||||||
|
lappend ::CSF_OPT_LIB$anArchIter "$aPath/lib"
|
||||||
|
} else {
|
||||||
|
lappend anErrLib$anArchIter "Error: '${::SYS_LIB_PREFIX}${aLibName}.${::SYS_LIB_SUFFIX}' not found (EGL)"
|
||||||
|
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if { "$::tcl_platform(platform)" == "windows" } {
|
||||||
|
set aDllPath [wokdep:SearchBin "libEGL.dll" "$anArchIter"]
|
||||||
|
if { "$aDllPath" == "" } {
|
||||||
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{EGL}*] "$::VCVER" "$anArchIter" ]
|
||||||
|
set aDllPath [wokdep:SearchBin "libEGL.dll" "$anArchIter" "$aPath/bin"]
|
||||||
|
if { "$aDllPath" == "" } {
|
||||||
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{angle}*] "$::VCVER" "$anArchIter" ]
|
||||||
|
set aDllPath [wokdep:SearchBin "libEGL.dll" "$anArchIter" "$aPath/bin"]
|
||||||
|
}
|
||||||
|
|
||||||
|
if { "$aDllPath" != "" } {
|
||||||
|
lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin"
|
||||||
|
} else {
|
||||||
|
lappend anErrBin$anArchIter "Error: 'libEGL.dll' not found (EGL)"
|
||||||
|
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return "$isFound"
|
||||||
|
}
|
||||||
|
|
||||||
|
# Search OpenGL ES 2.0 library placement
|
||||||
|
proc wokdep:SearchGLES {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64} {
|
||||||
|
upvar $theErrInc anErrInc
|
||||||
|
upvar $theErrLib32 anErrLib32
|
||||||
|
upvar $theErrLib64 anErrLib64
|
||||||
|
upvar $theErrBin32 anErrBin32
|
||||||
|
upvar $theErrBin64 anErrBin64
|
||||||
|
|
||||||
|
set isFound "true"
|
||||||
|
set aHeaderPath [wokdep:SearchHeader "GLES2/gl2.h"]
|
||||||
|
if { "$aHeaderPath" == "" } {
|
||||||
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{GLES}*] "$::VCVER" "$::ARCH" ]
|
||||||
|
if { "$aPath" == "" || ![file exists "$aPath/include/GLES2/gl2.h"] } {
|
||||||
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{angle}*] "$::VCVER" "$::ARCH" ]
|
||||||
|
}
|
||||||
|
|
||||||
|
if { "$aPath" != "" && [file exists "$aPath/include/GLES2/gl2.h"] } {
|
||||||
|
lappend ::CSF_OPT_INC "$aPath/include"
|
||||||
|
} else {
|
||||||
|
lappend anErrInc "Error: 'GLES2/gl2.h' not found (OpenGL ES 2.0)"
|
||||||
|
set isFound "false"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
set aLibName "GLESv2"
|
||||||
|
if { "$::tcl_platform(platform)" == "windows" } {
|
||||||
|
# awkward exception
|
||||||
|
set aLibName "libGLESv2"
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach anArchIter {64 32} {
|
||||||
|
set aLibPath [wokdep:SearchLib "$aLibName" "$anArchIter"]
|
||||||
|
if { "$aLibPath" == "" } {
|
||||||
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{GLES}*] "$::VCVER" "$anArchIter" ]
|
||||||
|
set aLibPath [wokdep:SearchLib "$aLibName" "$anArchIter" "$aPath/lib"]
|
||||||
|
if { "$aLibPath" == "" } {
|
||||||
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{angle}*] "$::VCVER" "$anArchIter" ]
|
||||||
|
set aLibPath [wokdep:SearchLib "$aLibName" "$anArchIter" "$aPath/lib"]
|
||||||
|
}
|
||||||
|
|
||||||
|
if { "$aLibPath" != "" } {
|
||||||
|
lappend ::CSF_OPT_LIB$anArchIter "$aPath/lib"
|
||||||
|
} else {
|
||||||
|
lappend anErrLib$anArchIter "Error: '${::SYS_LIB_PREFIX}${aLibName}.${::SYS_LIB_SUFFIX}' not found (OpenGL ES 2.0)"
|
||||||
|
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if { "$::tcl_platform(platform)" == "windows" } {
|
||||||
|
set aDllPath [wokdep:SearchBin "libGLESv2.dll" "$anArchIter"]
|
||||||
|
if { "$aDllPath" == "" } {
|
||||||
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{EGL}*] "$::VCVER" "$anArchIter" ]
|
||||||
|
set aDllPath [wokdep:SearchBin "libGLESv2.dll" "$anArchIter" "$aPath/bin"]
|
||||||
|
if { "$aDllPath" == "" } {
|
||||||
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{angle}*] "$::VCVER" "$anArchIter" ]
|
||||||
|
set aDllPath [wokdep:SearchBin "libGLESv2.dll" "$anArchIter" "$aPath/bin"]
|
||||||
|
}
|
||||||
|
|
||||||
|
if { "$aDllPath" != "" } {
|
||||||
|
lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin"
|
||||||
|
} else {
|
||||||
|
lappend anErrBin$anArchIter "Error: 'libGLESv2.dll' not found (OpenGL ES 2.0)"
|
||||||
|
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return "$isFound"
|
||||||
|
}
|
||||||
|
|
||||||
# Auxiliary function, gets VTK version to set default search directory
|
# Auxiliary function, gets VTK version to set default search directory
|
||||||
proc wokdep:VtkVersion { thePath } {
|
proc wokdep:VtkVersion { thePath } {
|
||||||
set aResult "6.1"
|
set aResult "6.1"
|
||||||
@@ -946,13 +1111,13 @@ proc wokdep:SaveCustom {} {
|
|||||||
|
|
||||||
puts $aFile ""
|
puts $aFile ""
|
||||||
puts $aFile "rem Optional 3rd-parties switches"
|
puts $aFile "rem Optional 3rd-parties switches"
|
||||||
puts $aFile "set HAVE_FREEIMAGE=$::HAVE_FREEIMAGE"
|
foreach anEnvIter $::THE_ENV_VARIABLES {
|
||||||
puts $aFile "set HAVE_GL2PS=$::HAVE_GL2PS"
|
set aName ${anEnvIter}
|
||||||
puts $aFile "set HAVE_TBB=$::HAVE_TBB"
|
set aValue [set ::${anEnvIter}]
|
||||||
puts $aFile "set HAVE_OPENCL=$::HAVE_OPENCL"
|
if { "$aValue" != "" } {
|
||||||
puts $aFile "set HAVE_VTK=$::HAVE_VTK"
|
puts $aFile "set ${aName}=$aValue"
|
||||||
puts $aFile "set CHECK_QT4=$::CHECK_QT4"
|
}
|
||||||
puts $aFile "set CHECK_JDK=$::CHECK_JDK"
|
}
|
||||||
|
|
||||||
set aStringInc [join $::CSF_OPT_INC $::SYS_PATH_SPLITTER]
|
set aStringInc [join $::CSF_OPT_INC $::SYS_PATH_SPLITTER]
|
||||||
puts $aFile ""
|
puts $aFile ""
|
||||||
@@ -995,16 +1160,13 @@ proc wokdep:SaveCustom {} {
|
|||||||
|
|
||||||
puts $aFile ""
|
puts $aFile ""
|
||||||
puts $aFile "# Optional 3rd-parties switches"
|
puts $aFile "# Optional 3rd-parties switches"
|
||||||
puts $aFile "export HAVE_FREEIMAGE=$::HAVE_FREEIMAGE"
|
foreach anEnvIter $::THE_ENV_VARIABLES {
|
||||||
puts $aFile "export HAVE_GL2PS=$::HAVE_GL2PS"
|
set aName ${anEnvIter}
|
||||||
puts $aFile "export HAVE_TBB=$::HAVE_TBB"
|
set aValue [set ::${anEnvIter}]
|
||||||
puts $aFile "export HAVE_OPENCL=$::HAVE_OPENCL"
|
if { "$aValue" != "" } {
|
||||||
puts $aFile "export HAVE_VTK=$::HAVE_VTK"
|
puts $aFile "export ${aName}=${aValue}"
|
||||||
if { "$::tcl_platform(os)" == "Darwin" } {
|
}
|
||||||
puts $aFile "export MACOSX_USE_GLX=$::MACOSX_USE_GLX"
|
|
||||||
}
|
}
|
||||||
puts $aFile "export CHECK_QT4=$::CHECK_QT4"
|
|
||||||
puts $aFile "export CHECK_JDK=$::CHECK_JDK"
|
|
||||||
|
|
||||||
set aStringInc [join $::CSF_OPT_INC $::SYS_PATH_SPLITTER]
|
set aStringInc [join $::CSF_OPT_INC $::SYS_PATH_SPLITTER]
|
||||||
puts $aFile ""
|
puts $aFile ""
|
||||||
|
@@ -70,7 +70,7 @@ proc gendoc {args} {
|
|||||||
set DOCLABEL ""
|
set DOCLABEL ""
|
||||||
set VERB_MODE "NO"
|
set VERB_MODE "NO"
|
||||||
set SEARCH_MODE "none"
|
set SEARCH_MODE "none"
|
||||||
set MATHJAX_LOCATION "http://cdn.mathjax.org/mathjax/latest"
|
set MATHJAX_LOCATION "https://cdn.mathjax.org/mathjax/latest"
|
||||||
set mathjax_js_name "MathJax.js"
|
set mathjax_js_name "MathJax.js"
|
||||||
set DOCTYPE_COMBO_FLAG 0
|
set DOCTYPE_COMBO_FLAG 0
|
||||||
set GENMODE_COMBO_FLAG 0
|
set GENMODE_COMBO_FLAG 0
|
||||||
|
428
adm/genproj.tcl
@@ -108,9 +108,155 @@ proc osutils:findSrcSubPath {theSubPath} {
|
|||||||
return "$::THE_CASROOT/src/$theSubPath"
|
return "$::THE_CASROOT/src/$theSubPath"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Auxiliary tool comparing content of two files line-by-line.
|
||||||
|
proc osutils:isEqualContent { theContent1 theContent2 } {
|
||||||
|
set aLen1 [llength $theContent1]
|
||||||
|
set aLen2 [llength $theContent2]
|
||||||
|
if { $aLen1 != $aLen2 } {
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
|
||||||
|
for {set aLineIter 0} {$aLineIter < $aLen1} {incr aLineIter} {
|
||||||
|
set aLine1 [lindex $theContent1 $aLineIter]
|
||||||
|
set aLine2 [lindex $theContent2 $aLineIter]
|
||||||
|
if { $aLine1 != $aLine2 } {
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
|
||||||
|
# Auxiliary function for writing new file content only if it has been actually changed
|
||||||
|
# (e.g. to preserve file timestamp on no change).
|
||||||
|
# Useful for automatically (re)generated files.
|
||||||
|
proc osutils:writeTextFile { theFile theContent {theEol lf} } {
|
||||||
|
if {[file exists "${theFile}"]} {
|
||||||
|
set aFileOld [open "${theFile}" rb]
|
||||||
|
fconfigure $aFileOld -translation crlf
|
||||||
|
set aLineListOld [split [read $aFileOld] "\n"]
|
||||||
|
close $aFileOld
|
||||||
|
|
||||||
|
# append empty line for proper comparison (which will be implicitly added by last puts below)
|
||||||
|
set aContent $theContent
|
||||||
|
lappend aContent ""
|
||||||
|
if { [osutils:isEqualContent $aLineListOld $aContent] == true } {
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
|
||||||
|
file delete -force "${theFile}"
|
||||||
|
}
|
||||||
|
|
||||||
|
set anOutFile [open "$theFile" "w"]
|
||||||
|
fconfigure $anOutFile -translation $theEol
|
||||||
|
foreach aLine ${theContent} {
|
||||||
|
puts $anOutFile "${aLine}"
|
||||||
|
}
|
||||||
|
close $anOutFile
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
|
||||||
|
# Function re-generating header files for specified text resource
|
||||||
|
proc genResources { theResource } {
|
||||||
|
global path
|
||||||
|
|
||||||
|
set aResFileList {}
|
||||||
|
set aResourceAbsPath [file normalize "${path}/src/${theResource}"]
|
||||||
|
set aResourceDirectory ""
|
||||||
|
set isResDirectory false
|
||||||
|
|
||||||
|
if {[file isdirectory "${aResourceAbsPath}"]} {
|
||||||
|
if {[file exists "${aResourceAbsPath}/FILES"]} {
|
||||||
|
set aFilesFile [open "${aResourceAbsPath}/FILES" rb]
|
||||||
|
set aResFileList [split [read $aFilesFile] "\n"]
|
||||||
|
close $aFilesFile
|
||||||
|
}
|
||||||
|
set aResFileList [lsearch -inline -all -not -exact $aResFileList ""]
|
||||||
|
set aResourceDirectory "${theResource}"
|
||||||
|
set isResDirectory true
|
||||||
|
} else {
|
||||||
|
set aResourceName [file tail "${theResource}"]
|
||||||
|
lappend aResFileList "res:::${aResourceName}"
|
||||||
|
set aResourceDirectory [file dirname "${theResource}"]
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach aResFileIter ${aResFileList} {
|
||||||
|
if {![regexp {^[^:]+:::(.+)} "${aResFileIter}" dump aResFileIter]} {
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
|
set aResFileName [file tail "${aResFileIter}"]
|
||||||
|
regsub -all {\.} "${aResFileName}" {_} aResFileName
|
||||||
|
set aHeaderFileName "${aResourceDirectory}_${aResFileName}.pxx"
|
||||||
|
if { $isResDirectory == true && [lsearch $aResFileList $aHeaderFileName] == -1 } {
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
|
# generate
|
||||||
|
set aContent {}
|
||||||
|
lappend aContent "// This file has been automatically generated from resource file src/${aResourceDirectory}/${aResFileIter}"
|
||||||
|
lappend aContent ""
|
||||||
|
|
||||||
|
# generate necessary structures
|
||||||
|
set aLineList {}
|
||||||
|
if {[file exists "${path}/src/${aResourceDirectory}/${aResFileIter}"]} {
|
||||||
|
set anInputFile [open "${path}/src/${aResourceDirectory}/${aResFileIter}" rb]
|
||||||
|
fconfigure $anInputFile -translation crlf
|
||||||
|
set aLineList [split [read $anInputFile] "\n"]
|
||||||
|
close $anInputFile
|
||||||
|
}
|
||||||
|
|
||||||
|
# drop empty trailing line
|
||||||
|
set anEndOfFile ""
|
||||||
|
if { [lindex $aLineList end] == "" } {
|
||||||
|
set aLineList [lreplace $aLineList end end]
|
||||||
|
set anEndOfFile "\\n"
|
||||||
|
}
|
||||||
|
|
||||||
|
lappend aContent "static const char ${aResourceDirectory}_${aResFileName}\[\] ="
|
||||||
|
set aNbLines [llength $aLineList]
|
||||||
|
set aLastLine [expr $aNbLines - 1]
|
||||||
|
for {set aLineIter 0} {$aLineIter < $aNbLines} {incr aLineIter} {
|
||||||
|
set aLine [lindex $aLineList $aLineIter]
|
||||||
|
regsub -all {\"} "${aLine}" {\\"} aLine
|
||||||
|
if { $aLineIter == $aLastLine } {
|
||||||
|
lappend aContent " \"${aLine}${anEndOfFile}\";"
|
||||||
|
} else {
|
||||||
|
lappend aContent " \"${aLine}\\n\""
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
# Save generated content to header file
|
||||||
|
set aHeaderFilePath "${path}/src/${aResourceDirectory}/${aHeaderFileName}"
|
||||||
|
if { [osutils:writeTextFile $aHeaderFilePath $aContent] == true } {
|
||||||
|
puts "Generating header file from resource file: ${path}/src/${aResourceDirectory}/${aResFileIter}"
|
||||||
|
} else {
|
||||||
|
#puts "Header file from resource ${path}/src/${aResourceDirectory}/${aResFileIter} is up-to-date"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
# Function re-generating header files for all text resources
|
||||||
|
proc genAllResources {} {
|
||||||
|
global path
|
||||||
|
set aCasRoot [file normalize $path]
|
||||||
|
if {![file exists "$aCasRoot/adm/RESOURCES"]} {
|
||||||
|
puts "OCCT directory is not defined correctly: $aCasRoot"
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
set aFileResources [open "$aCasRoot/adm/RESOURCES" rb]
|
||||||
|
set anAdmResources [split [read $aFileResources] "\r\n"]
|
||||||
|
close $aFileResources
|
||||||
|
set anAdmResources [lsearch -inline -all -not -exact $anAdmResources ""]
|
||||||
|
|
||||||
|
foreach line $anAdmResources {
|
||||||
|
genResources "${line}"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
# Wrapper-function to generate VS project files
|
# Wrapper-function to generate VS project files
|
||||||
proc genproj {theIDE args} {
|
proc genproj {theIDE args} {
|
||||||
set aSupportedIDEs { "vc7" "vc8" "vc9" "vc10" "vc11" "vc12" "vc14" "cbp" "xcd" }
|
set aSupportedIDEs { "vc7" "vc8" "vc9" "vc10" "vc11" "vc12" "vc14" "vc14-uwp" "cbp" "xcd"}
|
||||||
set aSupportedPlatforms { "wnt" "lin" "mac" "ios" "qnx" }
|
set aSupportedPlatforms { "wnt" "lin" "mac" "ios" "qnx" }
|
||||||
set isHelpRequire false
|
set isHelpRequire false
|
||||||
|
|
||||||
@@ -159,14 +305,15 @@ proc genproj {theIDE args} {
|
|||||||
puts "usage: genproj IDE \[Platform\] \[-static\] \[-h|-help|--help\]
|
puts "usage: genproj IDE \[Platform\] \[-static\] \[-h|-help|--help\]
|
||||||
|
|
||||||
IDE must be one of:
|
IDE must be one of:
|
||||||
vc8 - Visual Studio 2005
|
vc8 - Visual Studio 2005
|
||||||
vc9 - Visual Studio 2008
|
vc9 - Visual Studio 2008
|
||||||
vc10 - Visual Studio 2010
|
vc10 - Visual Studio 2010
|
||||||
vc11 - Visual Studio 2012
|
vc11 - Visual Studio 2012
|
||||||
vc12 - Visual Studio 2013
|
vc12 - Visual Studio 2013
|
||||||
vc14 - Visual Studio 2015
|
vc14 - Visual Studio 2015
|
||||||
cbp - CodeBlocks
|
vc14-uwp - Visual Studio 2015 for Universal Windows Platform project
|
||||||
xcd - XCode
|
cbp - CodeBlocks
|
||||||
|
xcd - XCode
|
||||||
|
|
||||||
Platform (optional, only for CodeBlocks and XCode):
|
Platform (optional, only for CodeBlocks and XCode):
|
||||||
wnt - Windows
|
wnt - Windows
|
||||||
@@ -193,6 +340,7 @@ proc genproj {theIDE args} {
|
|||||||
OS:MKPRC "$anAdmPath" "$theIDE" "$aLibType" "$aPlatform" "$aCmpl"
|
OS:MKPRC "$anAdmPath" "$theIDE" "$aLibType" "$aPlatform" "$aCmpl"
|
||||||
|
|
||||||
genprojbat "$theIDE" $aPlatform
|
genprojbat "$theIDE" $aPlatform
|
||||||
|
genAllResources
|
||||||
}
|
}
|
||||||
|
|
||||||
proc genprojbat {theIDE thePlatform} {
|
proc genprojbat {theIDE thePlatform} {
|
||||||
@@ -223,7 +371,7 @@ proc genprojbat {theIDE thePlatform} {
|
|||||||
file copy -force -- "$::THE_CASROOT/adm/templates/draw.${aTargetPlatformExt}" "$::path/draw.${aTargetPlatformExt}"
|
file copy -force -- "$::THE_CASROOT/adm/templates/draw.${aTargetPlatformExt}" "$::path/draw.${aTargetPlatformExt}"
|
||||||
}
|
}
|
||||||
|
|
||||||
if {[regexp {(vc)[0-9]*$} $theIDE] == 1} {
|
if {[regexp {(vc)[0-9]*$} $theIDE] == 1 || [regexp {(vc)[0-9]*-uwp$} $theIDE] == 1} {
|
||||||
file copy -force -- "$::THE_CASROOT/adm/templates/msvc.bat" "$::path/msvc.bat"
|
file copy -force -- "$::THE_CASROOT/adm/templates/msvc.bat" "$::path/msvc.bat"
|
||||||
} else {
|
} else {
|
||||||
switch -exact -- "$theIDE" {
|
switch -exact -- "$theIDE" {
|
||||||
@@ -266,7 +414,7 @@ proc OS:MKPRC { theOutDir theIDE theLibType thePlatform theCmpl } {
|
|||||||
|
|
||||||
# Create output directory
|
# Create output directory
|
||||||
set aWokStation "$thePlatform"
|
set aWokStation "$thePlatform"
|
||||||
if { [lsearch -exact {vc7 vc8 vc9 vc10 vc11 vc12 vc14} $theIDE] != -1 } {
|
if { [lsearch -exact {vc7 vc8 vc9 vc10 vc11 vc12 vc14 vc14-uwp} $theIDE] != -1 } {
|
||||||
set aWokStation "msvc"
|
set aWokStation "msvc"
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -294,6 +442,14 @@ proc OS:MKPRC { theOutDir theIDE theLibType thePlatform theCmpl } {
|
|||||||
set aModules [osutils:juststation $goaway $aModules]
|
set aModules [osutils:juststation $goaway $aModules]
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Draw module is turned off due to it is not supported on UWP
|
||||||
|
if { [regexp {(vc)[0-9]*-uwp$} $theIDE] == 1 } {
|
||||||
|
set aDrawIndex [lsearch -exact ${aModules} "Draw"]
|
||||||
|
if { ${aDrawIndex} != -1 } {
|
||||||
|
set aModules [lreplace ${aModules} ${aDrawIndex} ${aDrawIndex}]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
# generate one solution for all projects if complete OS or VAS is processed
|
# generate one solution for all projects if complete OS or VAS is processed
|
||||||
set anAllSolution "OCCT"
|
set anAllSolution "OCCT"
|
||||||
|
|
||||||
@@ -318,12 +474,13 @@ proc OS:MKPRC { theOutDir theIDE theLibType thePlatform theCmpl } {
|
|||||||
"vc7" -
|
"vc7" -
|
||||||
"vc8" -
|
"vc8" -
|
||||||
"vc9" -
|
"vc9" -
|
||||||
"vc10" -
|
"vc10" -
|
||||||
"vc11" -
|
"vc11" -
|
||||||
"vc12" -
|
"vc12" -
|
||||||
"vc14" { OS:MKVC $anOutDir $aModules $anAllSolution $theIDE }
|
"vc14" -
|
||||||
"cbp" { OS:MKCBP $anOutDir $aModules $anAllSolution $thePlatform $theCmpl }
|
"vc14-uwp" { OS:MKVC $anOutDir $aModules $anAllSolution $theIDE }
|
||||||
"xcd" {
|
"cbp" { OS:MKCBP $anOutDir $aModules $anAllSolution $thePlatform $theCmpl }
|
||||||
|
"xcd" {
|
||||||
set ::THE_GUIDS_LIST($::aTKNullKey) "000000000000000000000000"
|
set ::THE_GUIDS_LIST($::aTKNullKey) "000000000000000000000000"
|
||||||
OS:MKXCD $anOutDir $aModules $anAllSolution $theLibType $thePlatform
|
OS:MKXCD $anOutDir $aModules $anAllSolution $theLibType $thePlatform
|
||||||
}
|
}
|
||||||
@@ -639,16 +796,28 @@ proc osutils:collectinc {theModules theIncPath} {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
lsort -unique $anUsedToolKits
|
set anUsedToolKits [lsort -unique $anUsedToolKits]
|
||||||
|
|
||||||
set anUnits {}
|
set anUnits {}
|
||||||
foreach anUsedToolKit $anUsedToolKits {
|
foreach anUsedToolKit $anUsedToolKits {
|
||||||
set anUnits [concat $anUnits [osutils:tk:units $anUsedToolKit]]
|
set anUnits [concat $anUnits [osutils:tk:units $anUsedToolKit]]
|
||||||
}
|
}
|
||||||
lsort -unique $anUnits
|
set anUnits [lsort -unique $anUnits]
|
||||||
|
|
||||||
if { [info exists ::env(SHORTCUT_HEADERS)] &&
|
# define copying style
|
||||||
$::env(SHORTCUT_HEADERS) == "true" } {
|
set aCopyType "copy"
|
||||||
|
if { [info exists ::env(SHORTCUT_HEADERS)] } {
|
||||||
|
if { [string equal -nocase $::env(SHORTCUT_HEADERS) "hard"]
|
||||||
|
|| [string equal -nocase $::env(SHORTCUT_HEADERS) "hardlink"] } {
|
||||||
|
set aCopyType "hardlink"
|
||||||
|
} elseif { [string equal -nocase $::env(SHORTCUT_HEADERS) "true"]
|
||||||
|
|| [string equal -nocase $::env(SHORTCUT_HEADERS) "shortcut"] } {
|
||||||
|
set aCopyType "shortcut"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
set allHeaderFiles {}
|
||||||
|
if { $aCopyType == "shortcut" } {
|
||||||
# template preparation
|
# template preparation
|
||||||
if { ![file exists $::THE_CASROOT/adm/templates/header.in] } {
|
if { ![file exists $::THE_CASROOT/adm/templates/header.in] } {
|
||||||
puts "template file does not exist: $::THE_CASROOT/adm/templates/header.in"
|
puts "template file does not exist: $::THE_CASROOT/adm/templates/header.in"
|
||||||
@@ -661,11 +830,14 @@ proc osutils:collectinc {theModules theIncPath} {
|
|||||||
|
|
||||||
# create and copy short-cut header files
|
# create and copy short-cut header files
|
||||||
foreach anUnit $anUnits {
|
foreach anUnit $anUnits {
|
||||||
set aHFiles [glob -nocomplain -dir $aCasRoot/src/$anUnit "*.h"]
|
osutils:checksrcfiles ${anUnit}
|
||||||
foreach aHeaderFile [concat [glob -nocomplain -dir $aCasRoot/src/$anUnit "*.\[hgl\]xx"] $aHFiles] {
|
|
||||||
set aHeaderFileName [file tail $aHeaderFile]
|
|
||||||
|
|
||||||
regsub -all -- {@OCCT_HEADER_FILE@} $aHeaderTmpl "$aFromBuildIncToSrcPath/$anUnit/$aHeaderFileName" aShortCutHeaderFileContent
|
set aHFiles [_get_used_files ${anUnit} true false]
|
||||||
|
foreach aHeaderFile ${aHFiles} {
|
||||||
|
set aHeaderFileName [lindex ${aHeaderFile} 1]
|
||||||
|
lappend allHeaderFiles "${aHeaderFileName}"
|
||||||
|
|
||||||
|
regsub -all -- {@OCCT_HEADER_FILE_CONTENT@} $aHeaderTmpl "#include \"$aFromBuildIncToSrcPath/$anUnit/$aHeaderFileName\"" aShortCutHeaderFileContent
|
||||||
|
|
||||||
if {[file exists "$theIncPath/$aHeaderFileName"] && [file readable "$theIncPath/$aHeaderFileName"]} {
|
if {[file exists "$theIncPath/$aHeaderFileName"] && [file readable "$theIncPath/$aHeaderFileName"]} {
|
||||||
set fp [open "$theIncPath/$aHeaderFileName" r]
|
set fp [open "$theIncPath/$aHeaderFileName" r]
|
||||||
@@ -683,6 +855,7 @@ proc osutils:collectinc {theModules theIncPath} {
|
|||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
file delete -force "$theIncPath/$aHeaderFileName"
|
||||||
}
|
}
|
||||||
|
|
||||||
set aShortCutHeaderFile [open "$theIncPath/$aHeaderFileName" "w"]
|
set aShortCutHeaderFile [open "$theIncPath/$aHeaderFileName" "w"]
|
||||||
@@ -690,31 +863,49 @@ proc osutils:collectinc {theModules theIncPath} {
|
|||||||
puts $aShortCutHeaderFile $aShortCutHeaderFileContent
|
puts $aShortCutHeaderFile $aShortCutHeaderFileContent
|
||||||
close $aShortCutHeaderFile
|
close $aShortCutHeaderFile
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
set nbcopied 0
|
set nbcopied 0
|
||||||
foreach anUnit $anUnits {
|
foreach anUnit $anUnits {
|
||||||
set aHFiles [glob -nocomplain -dir $aCasRoot/src/$anUnit "*.h"]
|
osutils:checksrcfiles ${anUnit}
|
||||||
foreach aHeaderFile [concat [glob -nocomplain -dir $aCasRoot/src/$anUnit "*.\[hgl\]xx"] $aHFiles] {
|
|
||||||
set aHeaderFileName [file tail $aHeaderFile]
|
set aHFiles [_get_used_files ${anUnit} true false]
|
||||||
|
foreach aHeaderFile ${aHFiles} {
|
||||||
|
set aHeaderFileName [lindex ${aHeaderFile} 1]
|
||||||
|
lappend allHeaderFiles "${aHeaderFileName}"
|
||||||
|
|
||||||
# copy file only if target does not exist or is older than original
|
# copy file only if target does not exist or is older than original
|
||||||
set torig [file mtime $aHeaderFile]
|
set torig [file mtime $aCasRoot/src/$anUnit/$aHeaderFileName]
|
||||||
if { ! [file isfile $anIncPath/$aHeaderFileName] } {
|
set tcopy 0
|
||||||
set tcopy 0
|
if { [file isfile $anIncPath/$aHeaderFileName] } {
|
||||||
} else {
|
|
||||||
set tcopy [file mtime $anIncPath/$aHeaderFileName]
|
set tcopy [file mtime $anIncPath/$aHeaderFileName]
|
||||||
}
|
}
|
||||||
if { $tcopy < $torig } {
|
if { $tcopy < $torig } {
|
||||||
incr nbcopied
|
incr nbcopied
|
||||||
file copy -force $aHeaderFile $anIncPath/$aHeaderFileName
|
if { $aCopyType == "hardlink" } {
|
||||||
|
if { $tcopy != 0 } {
|
||||||
|
file delete -force "$theIncPath/$aHeaderFileName"
|
||||||
|
}
|
||||||
|
file link -hard $anIncPath/$aHeaderFileName $aCasRoot/src/$anUnit/$aHeaderFileName
|
||||||
|
} else {
|
||||||
|
file copy -force $aCasRoot/src/$anUnit/$aHeaderFileName $anIncPath/$aHeaderFileName
|
||||||
|
}
|
||||||
} elseif { $tcopy != $torig } {
|
} elseif { $tcopy != $torig } {
|
||||||
puts "Warning: file $anIncPath/$aHeaderFileName is newer than $aHeaderFile, not changed!"
|
puts "Warning: file $anIncPath/$aHeaderFileName is newer than $aCasRoot/src/$anUnit/$aHeaderFileName, not changed!"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
puts "Info: $nbcopied files updated"
|
puts "Info: $nbcopied files updated"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# remove header files not listed in FILES
|
||||||
|
set anIncFiles [glob -tails -nocomplain -dir ${anIncPath} "*"]
|
||||||
|
foreach anIncFile ${anIncFiles} {
|
||||||
|
if { [lsearch -exact ${allHeaderFiles} ${anIncFile}] == -1 } {
|
||||||
|
puts "Warning: file ${anIncPath}/${anIncFile} is not presented in the sources and will be removed from ${theIncPath}!"
|
||||||
|
file delete -force "${theIncPath}/${anIncFile}"
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
# Generate header for VS solution file
|
# Generate header for VS solution file
|
||||||
@@ -742,7 +933,7 @@ proc osutils:vcsolution:header { vcversion } {
|
|||||||
append var \
|
append var \
|
||||||
"Microsoft Visual Studio Solution File, Format Version 13.00\n" \
|
"Microsoft Visual Studio Solution File, Format Version 13.00\n" \
|
||||||
"# Visual Studio 2013\n"
|
"# Visual Studio 2013\n"
|
||||||
} elseif { "$vcversion" == "vc14" } {
|
} elseif { "$vcversion" == "vc14" || "$vcversion" == "vc14-uwp"} {
|
||||||
append var \
|
append var \
|
||||||
"Microsoft Visual Studio Solution File, Format Version 12.00\n" \
|
"Microsoft Visual Studio Solution File, Format Version 12.00\n" \
|
||||||
"# Visual Studio 14\n"
|
"# Visual Studio 14\n"
|
||||||
@@ -979,19 +1170,40 @@ proc osutils:vcproj:readtemplate {theVcVer isexec} {
|
|||||||
set aVerExt "v${aVerExt}0"
|
set aVerExt "v${aVerExt}0"
|
||||||
set aCmpl32 ""
|
set aCmpl32 ""
|
||||||
set aCmpl64 ""
|
set aCmpl64 ""
|
||||||
|
set aCharSet "Unicode"
|
||||||
if { $isexec } {
|
if { $isexec } {
|
||||||
set anExt "${anExt}x"
|
set anExt "${anExt}x"
|
||||||
set what "$what executable"
|
set what "$what executable"
|
||||||
}
|
}
|
||||||
if { "$theVcVer" == "vc10" } {
|
if { "$theVcVer" == "vc10" } {
|
||||||
# SSE2 is enabled by default in vc11+, but not in vc10 for 32-bit target
|
# SSE2 is enabled by default in vc11+, but not in vc10 for 32-bit target
|
||||||
set aCmpl32 "\n <EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>"
|
set aCmpl32 "<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>"
|
||||||
}
|
}
|
||||||
set aTmpl [osutils:readtemplate $anExt "MS VC++ project ($what)"]
|
set aTmpl [osutils:readtemplate $anExt "MS VC++ project ($what)"]
|
||||||
regsub -all -- {__VCVER__} $aTmpl $theVcVer aTmpl
|
|
||||||
regsub -all -- {__VCVEREXT__} $aTmpl $aVerExt aTmpl
|
if { $theVcVer == "vc14-uwp" } {
|
||||||
regsub -all -- {__VCMPL32__} $aTmpl $aCmpl32 aTmpl
|
set aVerExt "v140"
|
||||||
regsub -all -- {__VCMPL64__} $aTmpl $aCmpl64 aTmpl
|
set UwpWinRt "<CompileAsWinRT>false</CompileAsWinRT>"
|
||||||
|
foreach bitness {32 64} {
|
||||||
|
set indent ""
|
||||||
|
if {"[set aCmpl${bitness}]" != ""} {
|
||||||
|
set indent "\n "
|
||||||
|
}
|
||||||
|
set aCmpl${bitness} "[set aCmpl${bitness}]${indent}${UwpWinRt}"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach bitness {32 64} {
|
||||||
|
set format_template ""
|
||||||
|
if {"[set aCmpl${bitness}]" == ""} {
|
||||||
|
set format_template "\[\\r\\n\\s\]*"
|
||||||
|
}
|
||||||
|
regsub -all -- "${format_template}__VCMPL${bitness}__" $aTmpl "[set aCmpl${bitness}]" aTmpl
|
||||||
|
}
|
||||||
|
|
||||||
|
regsub -all -- {__VCVER__} $aTmpl $theVcVer aTmpl
|
||||||
|
regsub -all -- {__VCVEREXT__} $aTmpl $aVerExt aTmpl
|
||||||
|
regsub -all -- {__VCCHARSET__} $aTmpl $aCharSet aTmpl
|
||||||
return $aTmpl
|
return $aTmpl
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1058,11 +1270,14 @@ proc osutils:csfList { theOS theCsfLibsMap theCsfFrmsMap } {
|
|||||||
set aLibsMap(CSF_TclTkLibs) "tk8.6"
|
set aLibsMap(CSF_TclTkLibs) "tk8.6"
|
||||||
if { "$::HAVE_FREEIMAGE" == "true" } {
|
if { "$::HAVE_FREEIMAGE" == "true" } {
|
||||||
if { "$theOS" == "wnt" } {
|
if { "$theOS" == "wnt" } {
|
||||||
set aLibsMap(CSF_FreeImagePlus) "FreeImage FreeImagePlus"
|
set aLibsMap(CSF_FreeImagePlus) "FreeImage"
|
||||||
} else {
|
} else {
|
||||||
set aLibsMap(CSF_FreeImagePlus) "freeimage"
|
set aLibsMap(CSF_FreeImagePlus) "freeimage"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if { "$::HAVE_FFMPEG" == "true" } {
|
||||||
|
set aLibsMap(CSF_FFmpeg) "avcodec avformat swscale avutil"
|
||||||
|
}
|
||||||
if { "$::HAVE_GL2PS" == "true" } {
|
if { "$::HAVE_GL2PS" == "true" } {
|
||||||
set aLibsMap(CSF_GL2PS) "gl2ps"
|
set aLibsMap(CSF_GL2PS) "gl2ps"
|
||||||
}
|
}
|
||||||
@@ -1076,6 +1291,12 @@ proc osutils:csfList { theOS theCsfLibsMap theCsfFrmsMap } {
|
|||||||
set aLibsMap(CSF_VTK) [osutils:vtkCsf "unix"]
|
set aLibsMap(CSF_VTK) [osutils:vtkCsf "unix"]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if { "$::HAVE_ZLIB" == "true" } {
|
||||||
|
set aLibsMap(CSF_ZLIB) "zlib"
|
||||||
|
}
|
||||||
|
if { "$::HAVE_LIBLZMA" == "true" } {
|
||||||
|
set aLibsMap(CSF_LIBLZMA) "liblzma"
|
||||||
|
}
|
||||||
|
|
||||||
if { "$theOS" == "wnt" } {
|
if { "$theOS" == "wnt" } {
|
||||||
# WinAPI libraries
|
# WinAPI libraries
|
||||||
@@ -1086,9 +1307,10 @@ proc osutils:csfList { theOS theCsfLibsMap theCsfFrmsMap } {
|
|||||||
set aLibsMap(CSF_opengl32) "opengl32"
|
set aLibsMap(CSF_opengl32) "opengl32"
|
||||||
set aLibsMap(CSF_wsock32) "wsock32"
|
set aLibsMap(CSF_wsock32) "wsock32"
|
||||||
set aLibsMap(CSF_netapi32) "netapi32"
|
set aLibsMap(CSF_netapi32) "netapi32"
|
||||||
set aLibsMap(CSF_AviLibs) "ws2_32 vfw32"
|
|
||||||
set aLibsMap(CSF_OpenGlLibs) "opengl32"
|
set aLibsMap(CSF_OpenGlLibs) "opengl32"
|
||||||
set aLibsMap(CSF_winspool) "Winspool"
|
if { "$::HAVE_GLES2" == "true" } {
|
||||||
|
set aLibsMap(CSF_OpenGlLibs) "libEGL libGLESv2"
|
||||||
|
}
|
||||||
set aLibsMap(CSF_psapi) "Psapi"
|
set aLibsMap(CSF_psapi) "Psapi"
|
||||||
set aLibsMap(CSF_d3d9) "d3d9"
|
set aLibsMap(CSF_d3d9) "d3d9"
|
||||||
|
|
||||||
@@ -1121,6 +1343,10 @@ proc osutils:csfList { theOS theCsfLibsMap theCsfFrmsMap } {
|
|||||||
set aLibsMap(CSF_XwLibs) "X11 Xext Xmu Xi"
|
set aLibsMap(CSF_XwLibs) "X11 Xext Xmu Xi"
|
||||||
set aLibsMap(CSF_MotifLibs) "X11"
|
set aLibsMap(CSF_MotifLibs) "X11"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if { "$::HAVE_GLES2" == "true" } {
|
||||||
|
set aLibsMap(CSF_OpenGlLibs) "EGL GLESv2"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1429,7 +1655,14 @@ proc osutils:vcproj { theVcVer theOutDir theToolKit theGuidsMap {theProjTmpl {}
|
|||||||
}
|
}
|
||||||
regsub -all -- {__PROJECT_GUID__} $theProjTmpl $aGuidsMap($theToolKit) theProjTmpl
|
regsub -all -- {__PROJECT_GUID__} $theProjTmpl $aGuidsMap($theToolKit) theProjTmpl
|
||||||
|
|
||||||
|
set theProjTmpl [osutils:uwp:proj ${theVcVer} ${theProjTmpl}]
|
||||||
|
|
||||||
set aUsedLibs [list]
|
set aUsedLibs [list]
|
||||||
|
|
||||||
|
if { "$theVcVer" == "vc14-uwp" } {
|
||||||
|
lappend aUsedLibs "WindowsApp.lib"
|
||||||
|
}
|
||||||
|
|
||||||
foreach tkx [osutils:commonUsedTK $theToolKit] {
|
foreach tkx [osutils:commonUsedTK $theToolKit] {
|
||||||
lappend aUsedLibs "${tkx}.lib"
|
lappend aUsedLibs "${tkx}.lib"
|
||||||
}
|
}
|
||||||
@@ -2136,6 +2369,9 @@ proc osutils:cbp { theCmpl theOutDir theProjName thePlatform theSrcFiles theLibs
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
puts $aFile "\t\t\t\t\t<Add option=\"\$(CSF_OPT_LNK${aWokArch})\" />"
|
puts $aFile "\t\t\t\t\t<Add option=\"\$(CSF_OPT_LNK${aWokArch})\" />"
|
||||||
|
if { "$aWokStation" == "lin" } {
|
||||||
|
puts $aFile "\t\t\t\t\t<Add option=\"-Wl,-rpath-link=../../../${aWokStation}/cbp/lib\" />"
|
||||||
|
}
|
||||||
puts $aFile "\t\t\t\t</Linker>"
|
puts $aFile "\t\t\t\t</Linker>"
|
||||||
|
|
||||||
puts $aFile "\t\t\t</Target>"
|
puts $aFile "\t\t\t</Target>"
|
||||||
@@ -2183,6 +2419,9 @@ proc osutils:cbp { theCmpl theOutDir theProjName thePlatform theSrcFiles theLibs
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
puts $aFile "\t\t\t\t\t<Add option=\"\$(CSF_OPT_LNK${aWokArch}D)\" />"
|
puts $aFile "\t\t\t\t\t<Add option=\"\$(CSF_OPT_LNK${aWokArch}D)\" />"
|
||||||
|
if { "$aWokStation" == "lin" } {
|
||||||
|
puts $aFile "\t\t\t\t\t<Add option=\"-Wl,-rpath-link=../../../${aWokStation}/cbp/libd\" />"
|
||||||
|
}
|
||||||
puts $aFile "\t\t\t\t</Linker>"
|
puts $aFile "\t\t\t\t</Linker>"
|
||||||
|
|
||||||
puts $aFile "\t\t\t</Target>"
|
puts $aFile "\t\t\t</Target>"
|
||||||
@@ -2527,6 +2766,9 @@ proc osutils:xcdtk { theOutDir theToolKit theGuidsMap theIsStatic thePlatform {t
|
|||||||
set anExecPrefix "\t\t\t\tEXECUTABLE_PREFIX = lib;"
|
set anExecPrefix "\t\t\t\tEXECUTABLE_PREFIX = lib;"
|
||||||
set aWrapperExtension "\t\t\t\tWRAPPER_EXTENSION = dylib;"
|
set aWrapperExtension "\t\t\t\tWRAPPER_EXTENSION = dylib;"
|
||||||
set aTKDefines [list "OCC_CONVERT_SIGNALS"]
|
set aTKDefines [list "OCC_CONVERT_SIGNALS"]
|
||||||
|
if { $theIsStatic == 1 } {
|
||||||
|
lappend aTKDefines "OCCT_NO_PLUGINS"
|
||||||
|
}
|
||||||
|
|
||||||
if { "$theTargetType" == "executable" } {
|
if { "$theTargetType" == "executable" } {
|
||||||
set aPBXBuildPhase "CopyFiles"
|
set aPBXBuildPhase "CopyFiles"
|
||||||
@@ -2819,12 +3061,12 @@ proc osutils:xcdtk { theOutDir theToolKit theGuidsMap theIsStatic thePlatform {t
|
|||||||
if { "$thePlatform" == "ios" } {
|
if { "$thePlatform" == "ios" } {
|
||||||
puts $aPbxprojFile "\t\t\t\t\"ARCHS\[sdk=iphoneos\*\]\" = \"\$(ARCHS_STANDARD)\";";
|
puts $aPbxprojFile "\t\t\t\t\"ARCHS\[sdk=iphoneos\*\]\" = \"\$(ARCHS_STANDARD)\";";
|
||||||
puts $aPbxprojFile "\t\t\t\t\"ARCHS\[sdk=iphonesimulator\*\]\" = \"x86_64\";";
|
puts $aPbxprojFile "\t\t\t\t\"ARCHS\[sdk=iphonesimulator\*\]\" = \"x86_64\";";
|
||||||
puts $aPbxprojFile "\t\t\t\tCLANG_CXX_LIBRARY = \"libc++\";"
|
|
||||||
puts $aPbxprojFile "\t\t\t\tCLANG_ENABLE_MODULES = YES;"
|
puts $aPbxprojFile "\t\t\t\tCLANG_ENABLE_MODULES = YES;"
|
||||||
puts $aPbxprojFile "\t\t\t\tCLANG_ENABLE_OBJC_ARC = YES;"
|
puts $aPbxprojFile "\t\t\t\tCLANG_ENABLE_OBJC_ARC = YES;"
|
||||||
}
|
}
|
||||||
puts $aPbxprojFile "\t\t\t\tARCHS = \"\$(ARCHS_STANDARD_64_BIT)\";"
|
puts $aPbxprojFile "\t\t\t\tARCHS = \"\$(ARCHS_STANDARD_64_BIT)\";"
|
||||||
puts $aPbxprojFile "\t\t\t\tCLANG_CXX_LANGUAGE_STANDARD = \"gnu++0x\";"
|
puts $aPbxprojFile "\t\t\t\tCLANG_CXX_LIBRARY = \"libc++\";"
|
||||||
|
puts $aPbxprojFile "\t\t\t\tCLANG_CXX_LANGUAGE_STANDARD = \"c++0x\";"
|
||||||
puts $aPbxprojFile "\t\t\t\tCOPY_PHASE_STRIP = NO;"
|
puts $aPbxprojFile "\t\t\t\tCOPY_PHASE_STRIP = NO;"
|
||||||
puts $aPbxprojFile "\t\t\t\tGCC_C_LANGUAGE_STANDARD = gnu99;"
|
puts $aPbxprojFile "\t\t\t\tGCC_C_LANGUAGE_STANDARD = gnu99;"
|
||||||
puts $aPbxprojFile "\t\t\t\tGCC_DYNAMIC_NO_PIC = NO;"
|
puts $aPbxprojFile "\t\t\t\tGCC_DYNAMIC_NO_PIC = NO;"
|
||||||
@@ -2862,12 +3104,12 @@ proc osutils:xcdtk { theOutDir theToolKit theGuidsMap theIsStatic thePlatform {t
|
|||||||
if { "$thePlatform" == "ios" } {
|
if { "$thePlatform" == "ios" } {
|
||||||
puts $aPbxprojFile "\t\t\t\t\"ARCHS\[sdk=iphoneos\*\]\" = \"\$(ARCHS_STANDARD)\";";
|
puts $aPbxprojFile "\t\t\t\t\"ARCHS\[sdk=iphoneos\*\]\" = \"\$(ARCHS_STANDARD)\";";
|
||||||
puts $aPbxprojFile "\t\t\t\t\"ARCHS\[sdk=iphonesimulator\*\]\" = \"x86_64\";";
|
puts $aPbxprojFile "\t\t\t\t\"ARCHS\[sdk=iphonesimulator\*\]\" = \"x86_64\";";
|
||||||
puts $aPbxprojFile "\t\t\t\tCLANG_CXX_LIBRARY = \"libc++\";"
|
|
||||||
puts $aPbxprojFile "\t\t\t\tCLANG_ENABLE_MODULES = YES;"
|
puts $aPbxprojFile "\t\t\t\tCLANG_ENABLE_MODULES = YES;"
|
||||||
puts $aPbxprojFile "\t\t\t\tCLANG_ENABLE_OBJC_ARC = YES;"
|
puts $aPbxprojFile "\t\t\t\tCLANG_ENABLE_OBJC_ARC = YES;"
|
||||||
}
|
}
|
||||||
puts $aPbxprojFile "\t\t\t\tARCHS = \"\$(ARCHS_STANDARD_64_BIT)\";"
|
puts $aPbxprojFile "\t\t\t\tARCHS = \"\$(ARCHS_STANDARD_64_BIT)\";"
|
||||||
puts $aPbxprojFile "\t\t\t\tCLANG_CXX_LANGUAGE_STANDARD = \"gnu++0x\";"
|
puts $aPbxprojFile "\t\t\t\tCLANG_CXX_LIBRARY = \"libc++\";"
|
||||||
|
puts $aPbxprojFile "\t\t\t\tCLANG_CXX_LANGUAGE_STANDARD = \"c++0x\";"
|
||||||
puts $aPbxprojFile "\t\t\t\tCOPY_PHASE_STRIP = YES;"
|
puts $aPbxprojFile "\t\t\t\tCOPY_PHASE_STRIP = YES;"
|
||||||
puts $aPbxprojFile "\t\t\t\tGCC_C_LANGUAGE_STANDARD = gnu99;"
|
puts $aPbxprojFile "\t\t\t\tGCC_C_LANGUAGE_STANDARD = gnu99;"
|
||||||
puts $aPbxprojFile "\t\t\t\tGCC_ENABLE_OBJC_EXCEPTIONS = YES;"
|
puts $aPbxprojFile "\t\t\t\tGCC_ENABLE_OBJC_EXCEPTIONS = YES;"
|
||||||
@@ -3047,3 +3289,93 @@ proc osutils:xcdx { theOutDir theExecutable theGuidsMap } {
|
|||||||
puts $aPlistFile $aPlistTmpl
|
puts $aPlistFile $aPlistTmpl
|
||||||
close $aPlistFile
|
close $aPlistFile
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Returns available Windows SDKs versions
|
||||||
|
proc osutils:sdk { theSdkMajorVer {isQuietMode false} {theSdkDirectories {}} } {
|
||||||
|
if { ![llength ${theSdkDirectories}] } {
|
||||||
|
foreach anEnvVar { "ProgramFiles" "ProgramFiles\(x86\)" "ProgramW6432" } {
|
||||||
|
if {[ info exists ::env(${anEnvVar}) ]} {
|
||||||
|
lappend theSdkDirectories "$::env(${anEnvVar})/Windows Kits/${theSdkMajorVer}/Include"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
set sdk_versions {}
|
||||||
|
foreach sdk_dir ${theSdkDirectories} {
|
||||||
|
if { [file isdirectory ${sdk_dir}] } {
|
||||||
|
lappend sdk_versions [glob -tails -directory "${sdk_dir}" -type d *]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if {![llength ${sdk_versions}] && !${isQuietMode}} {
|
||||||
|
error "Error : Could not find Windows SDK ${theSdkMajorVer}"
|
||||||
|
}
|
||||||
|
|
||||||
|
return [join [lsort -unique ${sdk_versions}] " "]
|
||||||
|
}
|
||||||
|
|
||||||
|
# Generate global properties to Visual Studio project file for UWP solution
|
||||||
|
proc osutils:uwp:proj { theVcVer theProjTmpl } {
|
||||||
|
|
||||||
|
set uwp_properties ""
|
||||||
|
set uwp_generate_metadata ""
|
||||||
|
set uwp_app_container ""
|
||||||
|
|
||||||
|
set format_template ""
|
||||||
|
|
||||||
|
if { ${theVcVer} == "vc14-uwp" } {
|
||||||
|
set sdk_versions [osutils:sdk 10]
|
||||||
|
set sdk_max_ver [lindex ${sdk_versions} end]
|
||||||
|
|
||||||
|
set uwp_properties "<DefaultLanguage>en-US</DefaultLanguage>\n \
|
||||||
|
<ApplicationType>Windows Store</ApplicationType>\n \
|
||||||
|
<ApplicationTypeRevision>10.0</ApplicationTypeRevision>\n \
|
||||||
|
<MinimumVisualStudioVersion>14.0</MinimumVisualStudioVersion>\n \
|
||||||
|
<AppContainerApplication>true</AppContainerApplication>\n \
|
||||||
|
<WindowsTargetPlatformVersion>${sdk_max_ver}</WindowsTargetPlatformVersion>\n \
|
||||||
|
<WindowsTargetPlatformMinVersion>${sdk_max_ver}</WindowsTargetPlatformMinVersion>"
|
||||||
|
|
||||||
|
set uwp_generate_metadata "<GenerateWindowsMetadata>false</GenerateWindowsMetadata>"
|
||||||
|
|
||||||
|
regsub -all -- {[\r\n\s]*<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>} ${theProjTmpl} "" theProjTmpl
|
||||||
|
} else {
|
||||||
|
set format_template "\[\\r\\n\\s\]*"
|
||||||
|
}
|
||||||
|
|
||||||
|
regsub -all -- "${format_template}__UWP_PROPERTIES__" ${theProjTmpl} "${uwp_properties}" theProjTmpl
|
||||||
|
regsub -all -- "${format_template}__UWP_GENERATE_METADATA__" ${theProjTmpl} "${uwp_generate_metadata}" theProjTmpl
|
||||||
|
|
||||||
|
return ${theProjTmpl}
|
||||||
|
}
|
||||||
|
|
||||||
|
# Report all files found in package directory but not listed in FILES
|
||||||
|
proc osutils:checksrcfiles { theUnit } {
|
||||||
|
global path
|
||||||
|
set aCasRoot [file normalize ${path}]
|
||||||
|
|
||||||
|
if {![file isdirectory ${aCasRoot}]} {
|
||||||
|
puts "OCCT directory is not defined correctly: ${aCasRoot}"
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
set anUnitAbsPath [file normalize "${aCasRoot}/src/${theUnit}"]
|
||||||
|
|
||||||
|
if {[file exists "${anUnitAbsPath}/FILES"]} {
|
||||||
|
set aFilesFile [open "${anUnitAbsPath}/FILES" rb]
|
||||||
|
set aFilesFileList [split [read ${aFilesFile}] "\n"]
|
||||||
|
close ${aFilesFile}
|
||||||
|
|
||||||
|
set aFilesFileList [lsearch -inline -all -not -exact ${aFilesFileList} ""]
|
||||||
|
|
||||||
|
# report all files not listed in FILES
|
||||||
|
set anAllFiles [glob -tails -nocomplain -dir ${anUnitAbsPath} "*"]
|
||||||
|
foreach aFile ${anAllFiles} {
|
||||||
|
if { "${aFile}" == "FILES" } {
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
if { [lsearch -exact ${aFilesFileList} ${aFile}] == -1 } {
|
||||||
|
puts "Warning: file ${anUnitAbsPath}/${aFile} is not listed in ${anUnitAbsPath}/FILES!"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@@ -2,6 +2,7 @@
|
|||||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|@X_COMPILER_BITNESS@'">
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|@X_COMPILER_BITNESS@'">
|
||||||
<LocalDebuggerEnvironment>CASROOT=@CMAKE_SOURCE_DIR@
|
<LocalDebuggerEnvironment>CASROOT=@CMAKE_SOURCE_DIR@
|
||||||
|
CSF_FPE=@BUILD_ENABLE_FPE_SIGNAL_HANDLER@
|
||||||
CSF_OCCTResourcePath=@CMAKE_SOURCE_DIR@/src
|
CSF_OCCTResourcePath=@CMAKE_SOURCE_DIR@/src
|
||||||
CSF_OCCTDataPath=@CMAKE_SOURCE_DIR@/data
|
CSF_OCCTDataPath=@CMAKE_SOURCE_DIR@/data
|
||||||
CSF_OCCTSamplesPath=@CMAKE_SOURCE_DIR@/samples
|
CSF_OCCTSamplesPath=@CMAKE_SOURCE_DIR@/samples
|
||||||
@@ -14,6 +15,7 @@ PATH=@3RDPARTY_DLL_DIRS_FOR_PATH@;%PATH%
|
|||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='RelWithDebInfo|@X_COMPILER_BITNESS@'">
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='RelWithDebInfo|@X_COMPILER_BITNESS@'">
|
||||||
<LocalDebuggerEnvironment>CASROOT=@CMAKE_SOURCE_DIR@
|
<LocalDebuggerEnvironment>CASROOT=@CMAKE_SOURCE_DIR@
|
||||||
|
CSF_FPE=@BUILD_ENABLE_FPE_SIGNAL_HANDLER@
|
||||||
CSF_OCCTResourcePath=@CMAKE_SOURCE_DIR@/src
|
CSF_OCCTResourcePath=@CMAKE_SOURCE_DIR@/src
|
||||||
CSF_OCCTDataPath=@CMAKE_SOURCE_DIR@/data
|
CSF_OCCTDataPath=@CMAKE_SOURCE_DIR@/data
|
||||||
CSF_OCCTSamplesPath=@CMAKE_SOURCE_DIR@/samples
|
CSF_OCCTSamplesPath=@CMAKE_SOURCE_DIR@/samples
|
||||||
@@ -26,6 +28,7 @@ PATH=@3RDPARTY_DLL_DIRS_FOR_PATH@;%PATH%
|
|||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|@X_COMPILER_BITNESS@'">
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|@X_COMPILER_BITNESS@'">
|
||||||
<LocalDebuggerEnvironment>CASROOT=@CMAKE_SOURCE_DIR@
|
<LocalDebuggerEnvironment>CASROOT=@CMAKE_SOURCE_DIR@
|
||||||
|
CSF_FPE=@BUILD_ENABLE_FPE_SIGNAL_HANDLER@
|
||||||
CSF_OCCTResourcePath=@CMAKE_SOURCE_DIR@/src
|
CSF_OCCTResourcePath=@CMAKE_SOURCE_DIR@/src
|
||||||
CSF_OCCTDataPath=@CMAKE_SOURCE_DIR@/data
|
CSF_OCCTDataPath=@CMAKE_SOURCE_DIR@/data
|
||||||
CSF_OCCTSamplesPath=@CMAKE_SOURCE_DIR@/samples
|
CSF_OCCTSamplesPath=@CMAKE_SOURCE_DIR@/samples
|
||||||
|
14
adm/templates/OpenCASCADECompileDefinitionsAndFlags.cmake.in
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
#-----------------------------------------------------------------------------
|
||||||
|
#
|
||||||
|
# OpenCASCADECompileDefinitionsAndFlags-@OCCT_CONFIGURATION_LOWER@.cmake - OpenCASCADE CMake file
|
||||||
|
# with compile definitions and C/C++ flags for @OCCT_CONFIGURATION@ configuration.
|
||||||
|
#
|
||||||
|
# This file is configured by OpenCASCADE.
|
||||||
|
#
|
||||||
|
|
||||||
|
# The C and C++ flags added by OpenCASCADE to the cmake-configured flags.
|
||||||
|
set (OpenCASCADE_C_FLAGS_@OCCT_CONFIGURATION_UPPER@ "@SET_OpenCASCADE_CMAKE_C_FLAGS@")
|
||||||
|
set (OpenCASCADE_CXX_FLAGS_@OCCT_CONFIGURATION_UPPER@ "@SET_OpenCASCADE_CMAKE_CXX_FLAGS@")
|
||||||
|
|
||||||
|
# The compile definitions used by OpenCASCADE.
|
||||||
|
@SET_OpenCASCADE_COMPILE_DEFINITIONS@
|
@@ -54,16 +54,23 @@ set (OpenCASCADE_BUILD_WITH_DEBUG @BUILD_WITH_DEBUG@)
|
|||||||
set (OpenCASCADE_BUILD_SHARED_LIBS @BUILD_SHARED_LIBS@)
|
set (OpenCASCADE_BUILD_SHARED_LIBS @BUILD_SHARED_LIBS@)
|
||||||
@SET_OpenCASCADE_BUILD_TYPE@
|
@SET_OpenCASCADE_BUILD_TYPE@
|
||||||
|
|
||||||
# Use of third-party libraries
|
# Use of third-party libraries.
|
||||||
set (OpenCASCADE_WITH_TCL @USE_TCL@)
|
set (OpenCASCADE_WITH_TCL @USE_TCL@)
|
||||||
set (OpenCASCADE_WITH_FREETYPE @USE_FREETYPE@)
|
set (OpenCASCADE_WITH_FREETYPE @USE_FREETYPE@)
|
||||||
set (OpenCASCADE_WITH_FREEIMAGE @USE_FREEIMAGE@)
|
set (OpenCASCADE_WITH_FREEIMAGE @USE_FREEIMAGE@)
|
||||||
set (OpenCASCADE_WITH_GL2PS @USE_GL2PS@)
|
set (OpenCASCADE_WITH_GL2PS @USE_GL2PS@)
|
||||||
set (OpenCASCADE_WITH_TBB @USE_TBB@)
|
set (OpenCASCADE_WITH_TBB @USE_TBB@)
|
||||||
set (OpenCASCADE_WITH_VTK @USE_VTK@)
|
set (OpenCASCADE_WITH_VTK @USE_VTK@)
|
||||||
|
set (OpenCASCADE_WITH_GLES2 @USE_GLES2@)
|
||||||
@SET_OpenCASCADE_WITH_D3D@
|
@SET_OpenCASCADE_WITH_D3D@
|
||||||
@SET_OpenCASCADE_WITH_GLX@
|
@SET_OpenCASCADE_WITH_GLX@
|
||||||
|
|
||||||
|
# Import OpenCASCADE compile definitions, C and C++ flags for each installed configuration.
|
||||||
|
file(GLOB CONFIG_FILES "${CMAKE_CURRENT_LIST_DIR}/OpenCASCADECompileDefinitionsAndFlags-*.cmake")
|
||||||
|
foreach(f ${CONFIG_FILES})
|
||||||
|
include(${f})
|
||||||
|
endforeach()
|
||||||
|
|
||||||
if (NOT OpenCASCADE_FIND_COMPONENTS)
|
if (NOT OpenCASCADE_FIND_COMPONENTS)
|
||||||
set (OpenCASCADE_FIND_COMPONENTS ${OpenCASCADE_MODULES})
|
set (OpenCASCADE_FIND_COMPONENTS ${OpenCASCADE_MODULES})
|
||||||
endif ()
|
endif ()
|
||||||
|
8
adm/templates/android.toolchain.config.cmake
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
# A toolchain file to configure a Makefile Generators or the Ninja generator to target Android for cross-compiling.
|
||||||
|
# Set CMAKE_ANDROID_NDK variable equal to your Android NDK path.
|
||||||
|
|
||||||
|
set (CMAKE_SYSTEM_NAME Android)
|
||||||
|
set (CMAKE_SYSTEM_VERSION 15) # API level
|
||||||
|
set (CMAKE_ANDROID_ARCH_ABI armeabi-v7a)
|
||||||
|
set (CMAKE_ANDROID_NDK "")
|
||||||
|
set (CMAKE_ANDROID_STL_TYPE gnustl_shared)
|
@@ -2,11 +2,15 @@ echo off
|
|||||||
|
|
||||||
if /I "%VCVER%" == "@COMPILER@" (
|
if /I "%VCVER%" == "@COMPILER@" (
|
||||||
if "%ARCH%" == "@COMPILER_BITNESS@" (
|
if "%ARCH%" == "@COMPILER_BITNESS@" (
|
||||||
|
rem set environment variables used by OCCT
|
||||||
|
set CSF_FPE=@BUILD_ENABLE_FPE_SIGNAL_HANDLER@
|
||||||
|
|
||||||
set "TCL_DIR=@3RDPARTY_TCL_DLL_DIR@"
|
set "TCL_DIR=@3RDPARTY_TCL_DLL_DIR@"
|
||||||
set "TK_DIR=@3RDPARTY_TK_DLL_DIR@"
|
set "TK_DIR=@3RDPARTY_TK_DLL_DIR@"
|
||||||
set "FREETYPE_DIR=@3RDPARTY_FREETYPE_DLL_DIR@"
|
set "FREETYPE_DIR=@3RDPARTY_FREETYPE_DLL_DIR@"
|
||||||
set "FREEIMAGE_DIR=@3RDPARTY_FREEIMAGE_DLL_DIR@"
|
set "FREEIMAGE_DIR=@3RDPARTY_FREEIMAGE_DLL_DIR@"
|
||||||
set "FREEIMAGEPLUS_DIR=@3RDPARTY_FREEIMAGEPLUS_DLL_DIR@"
|
set "EGL_DIR=@3RDPARTY_EGL_DLL_DIR@"
|
||||||
|
set "GLES2_DIR=@3RDPARTY_GLES2_DLL_DIR@"
|
||||||
set "GL2PS_DIR=@3RDPARTY_GL2PS_DLL_DIR@"
|
set "GL2PS_DIR=@3RDPARTY_GL2PS_DLL_DIR@"
|
||||||
set "TBB_DIR=@3RDPARTY_TBB_DLL_DIR@"
|
set "TBB_DIR=@3RDPARTY_TBB_DLL_DIR@"
|
||||||
set "VTK_DIR=@3RDPARTY_VTK_DLL_DIR@"
|
set "VTK_DIR=@3RDPARTY_VTK_DLL_DIR@"
|
||||||
|
@@ -2,6 +2,9 @@
|
|||||||
|
|
||||||
if [ "$1" == "@BIN_LETTER@" ]; then
|
if [ "$1" == "@BIN_LETTER@" ]; then
|
||||||
if [ "$2" == "@COMPILER_BITNESS@" ]; then
|
if [ "$2" == "@COMPILER_BITNESS@" ]; then
|
||||||
|
# set environment variables used by OCCT
|
||||||
|
export CSF_FPE=@BUILD_ENABLE_FPE_SIGNAL_HANDLER@
|
||||||
|
|
||||||
export TCL_DIR="@3RDPARTY_TCL_LIBRARY_DIR@"
|
export TCL_DIR="@3RDPARTY_TCL_LIBRARY_DIR@"
|
||||||
export TK_DIR="@3RDPARTY_TK_LIBRARY_DIR@"
|
export TK_DIR="@3RDPARTY_TK_LIBRARY_DIR@"
|
||||||
export FREETYPE_DIR="@3RDPARTY_FREETYPE_LIBRARY_DIR@"
|
export FREETYPE_DIR="@3RDPARTY_FREETYPE_LIBRARY_DIR@"
|
||||||
|
@@ -4,11 +4,15 @@ rem CASDEB comes as third argument
|
|||||||
|
|
||||||
if /I "%VCVER%" == "@COMPILER@" (
|
if /I "%VCVER%" == "@COMPILER@" (
|
||||||
if "%ARCH%" == "@COMPILER_BITNESS@" (
|
if "%ARCH%" == "@COMPILER_BITNESS@" (
|
||||||
|
rem set environment variables used by OCCT
|
||||||
|
set CSF_FPE=@BUILD_ENABLE_FPE_SIGNAL_HANDLER@
|
||||||
|
|
||||||
set "TCL_DIR=@USED_3RDPARTY_TCL_DIR@"
|
set "TCL_DIR=@USED_3RDPARTY_TCL_DIR@"
|
||||||
set "TK_DIR=@USED_3RDPARTY_TK_DIR@"
|
set "TK_DIR=@USED_3RDPARTY_TK_DIR@"
|
||||||
set "FREETYPE_DIR=@USED_3RDPARTY_FREETYPE_DIR@"
|
set "FREETYPE_DIR=@USED_3RDPARTY_FREETYPE_DIR@"
|
||||||
set "FREEIMAGE_DIR=@USED_3RDPARTY_FREEIMAGE_DIR@"
|
set "FREEIMAGE_DIR=@USED_3RDPARTY_FREEIMAGE_DIR@"
|
||||||
set "FREEIMAGEPLUS_DIR=@USED_3RDPARTY_FREEIMAGEPLUS_DIR@"
|
set "EGL_DIR=@USED_3RDPARTY_EGL_DIR@"
|
||||||
|
set "GLES2_DIR=@USED_3RDPARTY_GLES2_DIR@"
|
||||||
set "GL2PS_DIR=@USED_3RDPARTY_GL2PS_DIR@"
|
set "GL2PS_DIR=@USED_3RDPARTY_GL2PS_DIR@"
|
||||||
set "TBB_DIR=@USED_3RDPARTY_TBB_DIR@"
|
set "TBB_DIR=@USED_3RDPARTY_TBB_DIR@"
|
||||||
set "VTK_DIR=@USED_3RDPARTY_VTK_DIR@"
|
set "VTK_DIR=@USED_3RDPARTY_VTK_DIR@"
|
||||||
@@ -16,18 +20,18 @@ if /I "%VCVER%" == "@COMPILER@" (
|
|||||||
set "TCL_VERSION_WITH_DOT=@3RDPARTY_TCL_LIBRARY_VERSION_WITH_DOT@"
|
set "TCL_VERSION_WITH_DOT=@3RDPARTY_TCL_LIBRARY_VERSION_WITH_DOT@"
|
||||||
set "TK_VERSION_WITH_DOT=@3RDPARTY_TK_LIBRARY_VERSION_WITH_DOT@"
|
set "TK_VERSION_WITH_DOT=@3RDPARTY_TK_LIBRARY_VERSION_WITH_DOT@"
|
||||||
|
|
||||||
set "CSF_OCCTBinPath=@INSTALL_DIR@/@INSTALL_DIR_BIN@%3"
|
set "CSF_OCCTBinPath=@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_BIN@%3"
|
||||||
set "CSF_OCCTLibPath=@INSTALL_DIR@/@INSTALL_DIR_LIB@%3"
|
set "CSF_OCCTLibPath=@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_LIB@%3"
|
||||||
|
|
||||||
set "CSF_OCCTIncludePath=@INSTALL_DIR@/@INSTALL_DIR_INCLUDE@"
|
set "CSF_OCCTIncludePath=@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_INCLUDE@"
|
||||||
set "CSF_OCCTResourcePath=@INSTALL_DIR@/@INSTALL_DIR_RESOURCE@"
|
set "CSF_OCCTResourcePath=@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_RESOURCE@"
|
||||||
set "CSF_OCCTDataPath=@INSTALL_DIR@/@INSTALL_DIR_DATA@"
|
set "CSF_OCCTDataPath=@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_DATA@"
|
||||||
set "CSF_OCCTSamplesPath=@INSTALL_DIR@/@INSTALL_DIR_SAMPLES@"
|
set "CSF_OCCTSamplesPath=@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_SAMPLES@"
|
||||||
set "CSF_OCCTTestsPath=@INSTALL_DIR@/@INSTALL_DIR_TESTS@"
|
set "CSF_OCCTTestsPath=@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_TESTS@"
|
||||||
set "CSF_OCCTDocPath=@INSTALL_DIR@/@INSTALL_DIR_DOC@"
|
set "CSF_OCCTDocPath=@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_DOC@"
|
||||||
|
|
||||||
rem for compatability with external application using CASROOT
|
rem for compatability with external application using CASROOT
|
||||||
set "CASROOT=@INSTALL_DIR@"
|
set "CASROOT=@INSTALL_DIR_ABSOLUTE@"
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@@ -2,6 +2,9 @@
|
|||||||
|
|
||||||
if [ "$1" == "@BIN_LETTER@" ]; then
|
if [ "$1" == "@BIN_LETTER@" ]; then
|
||||||
if [ "$2" == "@COMPILER_BITNESS@" ]; then
|
if [ "$2" == "@COMPILER_BITNESS@" ]; then
|
||||||
|
# set environment variables used by OCCT
|
||||||
|
export CSF_FPE=@BUILD_ENABLE_FPE_SIGNAL_HANDLER@
|
||||||
|
|
||||||
export TCL_DIR="@USED_3RDPARTY_TCL_DIR@"
|
export TCL_DIR="@USED_3RDPARTY_TCL_DIR@"
|
||||||
export TK_DIR="@USED_3RDPARTY_TK_DIR@"
|
export TK_DIR="@USED_3RDPARTY_TK_DIR@"
|
||||||
export FREETYPE_DIR="@USED_3RDPARTY_FREETYPE_DIR@"
|
export FREETYPE_DIR="@USED_3RDPARTY_FREETYPE_DIR@"
|
||||||
@@ -13,17 +16,17 @@ if [ "$1" == "@BIN_LETTER@" ]; then
|
|||||||
export TCL_VERSION_WITH_DOT="@3RDPARTY_TCL_LIBRARY_VERSION_WITH_DOT@"
|
export TCL_VERSION_WITH_DOT="@3RDPARTY_TCL_LIBRARY_VERSION_WITH_DOT@"
|
||||||
export TK_VERSION_WITH_DOT="@3RDPARTY_TK_LIBRARY_VERSION_WITH_DOT@"
|
export TK_VERSION_WITH_DOT="@3RDPARTY_TK_LIBRARY_VERSION_WITH_DOT@"
|
||||||
|
|
||||||
export CSF_OCCTBinPath="@INSTALL_DIR@/@INSTALL_DIR_BIN@"
|
export CSF_OCCTBinPath="@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_BIN@"
|
||||||
export CSF_OCCTLibPath="@INSTALL_DIR@/@INSTALL_DIR_LIB@"
|
export CSF_OCCTLibPath="@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_LIB@"
|
||||||
export CSF_OCCTIncludePath="@INSTALL_DIR@/@INSTALL_DIR_INCLUDE@"
|
export CSF_OCCTIncludePath="@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_INCLUDE@"
|
||||||
export CSF_OCCTResourcePath="@INSTALL_DIR@/@INSTALL_DIR_RESOURCE@"
|
export CSF_OCCTResourcePath="@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_RESOURCE@"
|
||||||
export CSF_OCCTDataPath="@INSTALL_DIR@/@INSTALL_DIR_DATA@"
|
export CSF_OCCTDataPath="@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_DATA@"
|
||||||
export CSF_OCCTSamplesPath="@INSTALL_DIR@/@INSTALL_DIR_SAMPLES@"
|
export CSF_OCCTSamplesPath="@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_SAMPLES@"
|
||||||
export CSF_OCCTTestsPath="@INSTALL_DIR@/@INSTALL_DIR_TESTS@"
|
export CSF_OCCTTestsPath="@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_TESTS@"
|
||||||
export CSF_OCCTDocPath="@INSTALL_DIR@/@INSTALL_DIR_DOC@"
|
export CSF_OCCTDocPath="@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_DOC@"
|
||||||
|
|
||||||
# for compatability with external application using CASROOT
|
# for compatability with external application using CASROOT
|
||||||
export CASROOT="@INSTALL_DIR@"
|
export CASROOT="@INSTALL_DIR_ABSOLUTE@"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@@ -18,9 +18,13 @@ set "VCVARS="
|
|||||||
set "HAVE_TBB=false"
|
set "HAVE_TBB=false"
|
||||||
set "HAVE_OPENCL=false"
|
set "HAVE_OPENCL=false"
|
||||||
set "HAVE_FREEIMAGE=false"
|
set "HAVE_FREEIMAGE=false"
|
||||||
|
set "HAVE_FFMPEG=false"
|
||||||
set "HAVE_GL2PS=false"
|
set "HAVE_GL2PS=false"
|
||||||
set "HAVE_VTK=false"
|
set "HAVE_VTK=false"
|
||||||
|
set "HAVE_GLES2=false"
|
||||||
set "HAVE_D3D=false"
|
set "HAVE_D3D=false"
|
||||||
|
set "HAVE_ZLIB=false"
|
||||||
|
set "HAVE_LIBLZMA=false"
|
||||||
set "CSF_OPT_INC="
|
set "CSF_OPT_INC="
|
||||||
set "CSF_OPT_LIB32="
|
set "CSF_OPT_LIB32="
|
||||||
set "CSF_OPT_LIB64="
|
set "CSF_OPT_LIB64="
|
||||||
@@ -57,18 +61,16 @@ set "CSF_OPT_BIN64I=%CSF_OPT_BIN64%"
|
|||||||
rem ----- Optional 3rd-parties should be enabled by HAVE macros -----
|
rem ----- Optional 3rd-parties should be enabled by HAVE macros -----
|
||||||
set "CSF_OPT_CMPL="
|
set "CSF_OPT_CMPL="
|
||||||
set "PRODUCTS_DEFINES="
|
set "PRODUCTS_DEFINES="
|
||||||
if ["%HAVE_TBB%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_TBB"
|
if ["%HAVE_TBB%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_TBB" & set "CSF_DEFINES=HAVE_TBB;%CSF_DEFINES%"
|
||||||
if ["%HAVE_OPENCL%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_OPENCL"
|
if ["%HAVE_OPENCL%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_OPENCL" & set "CSF_DEFINES=HAVE_OPENCL;%CSF_DEFINES%"
|
||||||
if ["%HAVE_GL2PS%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_GL2PS"
|
if ["%HAVE_GL2PS%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_GL2PS" & set "CSF_DEFINES=HAVE_GL2PS;%CSF_DEFINES%"
|
||||||
if ["%HAVE_FREEIMAGE%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_FREEIMAGE"
|
if ["%HAVE_FREEIMAGE%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_FREEIMAGE" & set "CSF_DEFINES=HAVE_FREEIMAGE;%CSF_DEFINES%"
|
||||||
if ["%HAVE_VTK%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_VTK"
|
if ["%HAVE_FFMPEG%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_FFMPEG" & set "CSF_DEFINES=HAVE_FFMPEG;%CSF_DEFINES%"
|
||||||
if ["%HAVE_D3D%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_D3D"
|
if ["%HAVE_VTK%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_VTK" & set "CSF_DEFINES=HAVE_VTK;%CSF_DEFINES%"
|
||||||
if ["%HAVE_TBB%"] == ["true"] set "CSF_DEFINES=HAVE_TBB;%CSF_DEFINES%"
|
if ["%HAVE_GLES2%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_GLES2" & set "CSF_DEFINES=HAVE_GLES2;%CSF_DEFINES%"
|
||||||
if ["%HAVE_OPENCL%"] == ["true"] set "CSF_DEFINES=HAVE_OPENCL;%CSF_DEFINES%"
|
if ["%HAVE_D3D%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_D3D" & set "CSF_DEFINES=HAVE_D3D;%CSF_DEFINES%"
|
||||||
if ["%HAVE_GL2PS%"] == ["true"] set "CSF_DEFINES=HAVE_GL2PS;%CSF_DEFINES%"
|
if ["%HAVE_ZLIB%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_ZLIB" & set "CSF_DEFINES=HAVE_ZLIB;%CSF_DEFINES%"
|
||||||
if ["%HAVE_FREEIMAGE%"] == ["true"] set "CSF_DEFINES=HAVE_FREEIMAGE;%CSF_DEFINES%"
|
if ["%HAVE_LIBLZMA%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_LIBLZMA" & set "CSF_DEFINES=HAVE_LIBLZMA;%CSF_DEFINES%"
|
||||||
if ["%HAVE_VTK%"] == ["true"] set "CSF_DEFINES=HAVE_VTK;%CSF_DEFINES%"
|
|
||||||
if ["%HAVE_D3D%"] == ["true"] set "CSF_DEFINES=HAVE_D3D;%CSF_DEFINES%"
|
|
||||||
|
|
||||||
rem Eliminate VS warning
|
rem Eliminate VS warning
|
||||||
if ["%CSF_DEFINES%"] == [""] set "CSF_DEFINES=;"
|
if ["%CSF_DEFINES%"] == [""] set "CSF_DEFINES=;"
|
||||||
@@ -134,8 +136,6 @@ set "CSF_PluginDefaults=%CSF_OCCTResourcePath%\StdResource"
|
|||||||
set "CSF_XCAFDefaults=%CSF_OCCTResourcePath%\StdResource"
|
set "CSF_XCAFDefaults=%CSF_OCCTResourcePath%\StdResource"
|
||||||
set "CSF_TObjDefaults=%CSF_OCCTResourcePath%\StdResource"
|
set "CSF_TObjDefaults=%CSF_OCCTResourcePath%\StdResource"
|
||||||
set "CSF_StandardLiteDefaults=%CSF_OCCTResourcePath%\StdResource"
|
set "CSF_StandardLiteDefaults=%CSF_OCCTResourcePath%\StdResource"
|
||||||
set "CSF_UnitsLexicon=%CSF_OCCTResourcePath%\UnitsAPI\Lexi_Expr.dat"
|
|
||||||
set "CSF_UnitsDefinition=%CSF_OCCTResourcePath%\UnitsAPI\Units.dat"
|
|
||||||
set "CSF_IGESDefaults=%CSF_OCCTResourcePath%\XSTEPResource"
|
set "CSF_IGESDefaults=%CSF_OCCTResourcePath%\XSTEPResource"
|
||||||
set "CSF_STEPDefaults=%CSF_OCCTResourcePath%\XSTEPResource"
|
set "CSF_STEPDefaults=%CSF_OCCTResourcePath%\XSTEPResource"
|
||||||
set "CSF_XmlOcafResource=%CSF_OCCTResourcePath%\XmlOcafResource"
|
set "CSF_XmlOcafResource=%CSF_OCCTResourcePath%\XmlOcafResource"
|
||||||
|
@@ -29,7 +29,8 @@ if not ["%TCL_DIR%"] == [""] set "PATH=%TCL_DIR%;%PATH%"
|
|||||||
if not ["%TK_DIR%"] == [""] set "PATH=%TK_DIR%;%PATH%"
|
if not ["%TK_DIR%"] == [""] set "PATH=%TK_DIR%;%PATH%"
|
||||||
if not ["%FREETYPE_DIR%"] == [""] set "PATH=%FREETYPE_DIR%;%PATH%"
|
if not ["%FREETYPE_DIR%"] == [""] set "PATH=%FREETYPE_DIR%;%PATH%"
|
||||||
if not ["%FREEIMAGE_DIR%"] == [""] set "PATH=%FREEIMAGE_DIR%;%PATH%"
|
if not ["%FREEIMAGE_DIR%"] == [""] set "PATH=%FREEIMAGE_DIR%;%PATH%"
|
||||||
if not ["%FREEIMAGEPLUS_DIR%"] == [""] set "PATH=%FREEIMAGEPLUS_DIR%;%PATH%"
|
if not ["%EGL_DIR%"] == [""] set "PATH=%EGL_DIR%;%PATH%"
|
||||||
|
if not ["%GLES2_DIR%"] == [""] set "PATH=%GLES2_DIR%;%PATH%"
|
||||||
if not ["%GL2PS_DIR%"] == [""] set "PATH=%GL2PS_DIR%;%PATH%"
|
if not ["%GL2PS_DIR%"] == [""] set "PATH=%GL2PS_DIR%;%PATH%"
|
||||||
if not ["%TBB_DIR%"] == [""] set "PATH=%TBB_DIR%;%PATH%"
|
if not ["%TBB_DIR%"] == [""] set "PATH=%TBB_DIR%;%PATH%"
|
||||||
if not ["%VTK_DIR%"] == [""] set "PATH=%VTK_DIR%;%PATH%"
|
if not ["%VTK_DIR%"] == [""] set "PATH=%VTK_DIR%;%PATH%"
|
||||||
@@ -57,8 +58,6 @@ set "CSF_PluginDefaults=%CSF_OCCTResourcePath%\StdResource"
|
|||||||
set "CSF_XCAFDefaults=%CSF_OCCTResourcePath%\StdResource"
|
set "CSF_XCAFDefaults=%CSF_OCCTResourcePath%\StdResource"
|
||||||
set "CSF_TObjDefaults=%CSF_OCCTResourcePath%\StdResource"
|
set "CSF_TObjDefaults=%CSF_OCCTResourcePath%\StdResource"
|
||||||
set "CSF_StandardLiteDefaults=%CSF_OCCTResourcePath%\StdResource"
|
set "CSF_StandardLiteDefaults=%CSF_OCCTResourcePath%\StdResource"
|
||||||
set "CSF_UnitsLexicon=%CSF_OCCTResourcePath%\UnitsAPI\Lexi_Expr.dat"
|
|
||||||
set "CSF_UnitsDefinition=%CSF_OCCTResourcePath%\UnitsAPI\Units.dat"
|
|
||||||
set "CSF_IGESDefaults=%CSF_OCCTResourcePath%\XSTEPResource"
|
set "CSF_IGESDefaults=%CSF_OCCTResourcePath%\XSTEPResource"
|
||||||
set "CSF_STEPDefaults=%CSF_OCCTResourcePath%\XSTEPResource"
|
set "CSF_STEPDefaults=%CSF_OCCTResourcePath%\XSTEPResource"
|
||||||
set "CSF_XmlOcafResource=%CSF_OCCTResourcePath%\XmlOcafResource"
|
set "CSF_XmlOcafResource=%CSF_OCCTResourcePath%\XmlOcafResource"
|
||||||
|
@@ -4,7 +4,7 @@ if exist "%~dp0custom.bat" (
|
|||||||
call "%~dp0custom.bat" %1 %2 %3
|
call "%~dp0custom.bat" %1 %2 %3
|
||||||
)
|
)
|
||||||
|
|
||||||
call "@INSTALL_DIR@\@INSTALL_DIR_SCRIPT@\env.bat" %1 %2 %3
|
call "@INSTALL_DIR_ABSOLUTE@\@INSTALL_DIR_SCRIPT@\env.bat" %1 %2 %3
|
||||||
|
|
||||||
set "BIN_DIR=win%ARCH%\%VCVER%\bind"
|
set "BIN_DIR=win%ARCH%\%VCVER%\bind"
|
||||||
set "LIB_DIR=win%ARCH%\%VCVER%\libd"
|
set "LIB_DIR=win%ARCH%\%VCVER%\libd"
|
||||||
|
@@ -6,8 +6,8 @@ if [ -e "custom.sh" ]; then
|
|||||||
source "custom.sh";
|
source "custom.sh";
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -e "@INSTALL_DIR@/@INSTALL_DIR_SCRIPT@/env.sh" ]; then
|
if [ -e "@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_SCRIPT@/env.sh" ]; then
|
||||||
source "@INSTALL_DIR@/@INSTALL_DIR_SCRIPT@/env.sh";
|
source "@INSTALL_DIR_ABSOLUTE@/@INSTALL_DIR_SCRIPT@/env.sh";
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "${QTDIR}" == ""; then
|
if test "${QTDIR}" == ""; then
|
||||||
|
@@ -10,8 +10,12 @@ export TARGET="";
|
|||||||
export HAVE_TBB="false";
|
export HAVE_TBB="false";
|
||||||
export HAVE_OPENCL="false";
|
export HAVE_OPENCL="false";
|
||||||
export HAVE_FREEIMAGE="false";
|
export HAVE_FREEIMAGE="false";
|
||||||
|
export HAVE_FFMPEG="false";
|
||||||
export HAVE_GL2PS="false";
|
export HAVE_GL2PS="false";
|
||||||
export HAVE_VTK="false";
|
export HAVE_VTK="false";
|
||||||
|
export HAVE_GLES2="false";
|
||||||
|
export HAVE_ZLIB="false";
|
||||||
|
export HAVE_LIBLZMA="false";
|
||||||
export MACOSX_USE_GLX="false";
|
export MACOSX_USE_GLX="false";
|
||||||
export CSF_OPT_INC=""
|
export CSF_OPT_INC=""
|
||||||
export CSF_OPT_LIB32=""
|
export CSF_OPT_LIB32=""
|
||||||
@@ -90,25 +94,17 @@ fi
|
|||||||
export CSF_OPT_CMPL=""
|
export CSF_OPT_CMPL=""
|
||||||
|
|
||||||
# Optiona 3rd-parties should be enabled by HAVE macros
|
# Optiona 3rd-parties should be enabled by HAVE macros
|
||||||
if [ "$HAVE_TBB" == "true" ]; then
|
if [ "$HAVE_TBB" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_TBB"; fi
|
||||||
export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_TBB"
|
if [ "$HAVE_OPENCL" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_OPENCL"; fi
|
||||||
fi
|
if [ "$HAVE_FREEIMAGE" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_FREEIMAGE"; fi
|
||||||
if [ "$HAVE_OPENCL" == "true" ]; then
|
if [ "$HAVE_FFMPEG" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_FFMPEG"; fi
|
||||||
export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_OPENCL"
|
if [ "$HAVE_GL2PS" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_GL2PS"; fi
|
||||||
fi
|
if [ "$HAVE_GLES2" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_GLES2"; fi
|
||||||
if [ "$HAVE_FREEIMAGE" == "true" ]; then
|
if [ "$HAVE_VTK" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_VTK"; fi
|
||||||
export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_FREEIMAGE"
|
if [ "$HAVE_ZLIB" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_ZLIB"; fi
|
||||||
fi
|
if [ "$HAVE_LIBLZMA" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_LIBLZMA"; fi
|
||||||
if [ "$HAVE_GL2PS" == "true" ]; then
|
|
||||||
export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_GL2PS"
|
|
||||||
fi
|
|
||||||
if [ "$HAVE_VTK" == "true" ]; then
|
|
||||||
export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_VTK"
|
|
||||||
fi
|
|
||||||
# Option to compile OCCT with X11 libs on Mac OS X
|
# Option to compile OCCT with X11 libs on Mac OS X
|
||||||
if [ "$MACOSX_USE_GLX" == "true" ]; then
|
if [ "$MACOSX_USE_GLX" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DMACOSX_USE_GLX"; fi
|
||||||
export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DMACOSX_USE_GLX"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# To split string into array
|
# To split string into array
|
||||||
aDelimBack=$IFS
|
aDelimBack=$IFS
|
||||||
@@ -213,8 +209,6 @@ export CSF_PluginDefaults="${CASROOT}/src/StdResource"
|
|||||||
export CSF_XCAFDefaults="${CASROOT}/src/StdResource"
|
export CSF_XCAFDefaults="${CASROOT}/src/StdResource"
|
||||||
export CSF_TObjDefaults="${CASROOT}/src/StdResource"
|
export CSF_TObjDefaults="${CASROOT}/src/StdResource"
|
||||||
export CSF_StandardLiteDefaults="${CASROOT}/src/StdResource"
|
export CSF_StandardLiteDefaults="${CASROOT}/src/StdResource"
|
||||||
export CSF_UnitsLexicon="${CASROOT}/src/UnitsAPI/Lexi_Expr.dat"
|
|
||||||
export CSF_UnitsDefinition="${CASROOT}/src/UnitsAPI/Units.dat"
|
|
||||||
export CSF_IGESDefaults="${CASROOT}/src/XSTEPResource"
|
export CSF_IGESDefaults="${CASROOT}/src/XSTEPResource"
|
||||||
export CSF_STEPDefaults="${CASROOT}/src/XSTEPResource"
|
export CSF_STEPDefaults="${CASROOT}/src/XSTEPResource"
|
||||||
export CSF_XmlOcafResource="${CASROOT}/src/XmlOcafResource"
|
export CSF_XmlOcafResource="${CASROOT}/src/XmlOcafResource"
|
||||||
|
@@ -114,8 +114,6 @@ export CSF_PluginDefaults="${CSF_OCCTResourcePath}/StdResource"
|
|||||||
export CSF_XCAFDefaults="${CSF_OCCTResourcePath}/StdResource"
|
export CSF_XCAFDefaults="${CSF_OCCTResourcePath}/StdResource"
|
||||||
export CSF_TObjDefaults="${CSF_OCCTResourcePath}/StdResource"
|
export CSF_TObjDefaults="${CSF_OCCTResourcePath}/StdResource"
|
||||||
export CSF_StandardLiteDefaults="${CSF_OCCTResourcePath}/StdResource"
|
export CSF_StandardLiteDefaults="${CSF_OCCTResourcePath}/StdResource"
|
||||||
export CSF_UnitsLexicon="${CSF_OCCTResourcePath}/UnitsAPI/Lexi_Expr.dat"
|
|
||||||
export CSF_UnitsDefinition="${CSF_OCCTResourcePath}/UnitsAPI/Units.dat"
|
|
||||||
export CSF_IGESDefaults="${CSF_OCCTResourcePath}/XSTEPResource"
|
export CSF_IGESDefaults="${CSF_OCCTResourcePath}/XSTEPResource"
|
||||||
export CSF_STEPDefaults="${CSF_OCCTResourcePath}/XSTEPResource"
|
export CSF_STEPDefaults="${CSF_OCCTResourcePath}/XSTEPResource"
|
||||||
export CSF_XmlOcafResource="${CSF_OCCTResourcePath}/XmlOcafResource"
|
export CSF_XmlOcafResource="${CSF_OCCTResourcePath}/XmlOcafResource"
|
||||||
|
@@ -1 +1 @@
|
|||||||
#include "@OCCT_HEADER_FILE@"
|
@OCCT_HEADER_FILE_CONTENT@
|
||||||
|
@@ -28,6 +28,8 @@ if /I "%VCVER%" == "vc8" (
|
|||||||
set "VisualStudioExpressName=WDExpress"
|
set "VisualStudioExpressName=WDExpress"
|
||||||
) else if /I "%VCVER%" == "vc14" (
|
) else if /I "%VCVER%" == "vc14" (
|
||||||
set "DevEnvDir=%VS140COMNTOOLS%..\IDE"
|
set "DevEnvDir=%VS140COMNTOOLS%..\IDE"
|
||||||
|
) else if /I "%VCVER%" == "vc14-uwp" (
|
||||||
|
set "DevEnvDir=%VS140COMNTOOLS%..\IDE"
|
||||||
) else (
|
) else (
|
||||||
echo Error: wrong VS identifier
|
echo Error: wrong VS identifier
|
||||||
exit /B
|
exit /B
|
||||||
|
@@ -20,23 +20,28 @@
|
|||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>__PROJECT_GUID__</ProjectGuid>
|
<ProjectGuid>__PROJECT_GUID__</ProjectGuid>
|
||||||
|
__UWP_PROPERTIES__
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||||
<PlatformToolset>__VCVEREXT__</PlatformToolset>
|
<PlatformToolset>__VCVEREXT__</PlatformToolset>
|
||||||
|
<CharacterSet>__VCCHARSET__</CharacterSet>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||||
<PlatformToolset>__VCVEREXT__</PlatformToolset>
|
<PlatformToolset>__VCVEREXT__</PlatformToolset>
|
||||||
|
<CharacterSet>__VCCHARSET__</CharacterSet>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||||
<PlatformToolset>__VCVEREXT__</PlatformToolset>
|
<PlatformToolset>__VCVEREXT__</PlatformToolset>
|
||||||
|
<CharacterSet>__VCCHARSET__</CharacterSet>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||||
<PlatformToolset>__VCVEREXT__</PlatformToolset>
|
<PlatformToolset>__VCVEREXT__</PlatformToolset>
|
||||||
|
<CharacterSet>__VCCHARSET__</CharacterSet>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||||
<ImportGroup Label="ExtensionSettings">
|
<ImportGroup Label="ExtensionSettings">
|
||||||
@@ -96,14 +101,16 @@
|
|||||||
<WarningLevel>Level4</WarningLevel>
|
<WarningLevel>Level4</WarningLevel>
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||||
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||||
<FloatingPointModel>Precise</FloatingPointModel>__VCMPL32__
|
<FloatingPointModel>Precise</FloatingPointModel>
|
||||||
|
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||||
|
__VCMPL32__
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
<ResourceCompile>
|
<ResourceCompile>
|
||||||
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>NDEBUG;No_Exception;$(CSF_DEFINES)__TKDEFS__;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>NDEBUG;No_Exception;$(CSF_DEFINES)__TKDEFS__;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
</ResourceCompile>
|
</ResourceCompile>
|
||||||
<Link>
|
<Link>
|
||||||
<AdditionalDependencies>__TKDEP__;ws2_32.lib;vfw32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
<AdditionalDependencies>__TKDEP__;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||||
<OutputFile>.\..\..\..\win32\__VCVER__\bin\__TKNAM__.dll</OutputFile>
|
<OutputFile>.\..\..\..\win32\__VCVER__\bin\__TKNAM__.dll</OutputFile>
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||||
<AdditionalLibraryDirectories>..\..\..\win32\__VCVER__\lib;$(CSF_OPT_LIB32);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
<AdditionalLibraryDirectories>..\..\..\win32\__VCVER__\lib;$(CSF_OPT_LIB32);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||||
@@ -111,6 +118,7 @@
|
|||||||
<ProgramDatabaseFile>.\..\..\..\win32\__VCVER__\bin\__TKNAM__.pdb</ProgramDatabaseFile>
|
<ProgramDatabaseFile>.\..\..\..\win32\__VCVER__\bin\__TKNAM__.pdb</ProgramDatabaseFile>
|
||||||
<SubSystem>Console</SubSystem>
|
<SubSystem>Console</SubSystem>
|
||||||
<ImportLibrary>..\..\..\win32\__VCVER__\lib\__TKNAM__.lib</ImportLibrary>
|
<ImportLibrary>..\..\..\win32\__VCVER__\lib\__TKNAM__.lib</ImportLibrary>
|
||||||
|
__UWP_GENERATE_METADATA__
|
||||||
</Link>
|
</Link>
|
||||||
</ItemDefinitionGroup>
|
</ItemDefinitionGroup>
|
||||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||||
@@ -141,14 +149,16 @@
|
|||||||
<CompileAs>Default</CompileAs>
|
<CompileAs>Default</CompileAs>
|
||||||
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||||
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
||||||
<FloatingPointModel>Precise</FloatingPointModel>__VCMPL32__
|
<FloatingPointModel>Precise</FloatingPointModel>
|
||||||
|
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||||
|
__VCMPL32__
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
<ResourceCompile>
|
<ResourceCompile>
|
||||||
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>_DEBUG;$(CSF_DEFINES)__TKDEFS__;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>_DEBUG;$(CSF_DEFINES)__TKDEFS__;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
</ResourceCompile>
|
</ResourceCompile>
|
||||||
<Link>
|
<Link>
|
||||||
<AdditionalDependencies>__TKDEP__;ws2_32.lib;vfw32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
<AdditionalDependencies>__TKDEP__;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||||
<OutputFile>.\..\..\..\win32\__VCVER__\bind\__TKNAM__.dll</OutputFile>
|
<OutputFile>.\..\..\..\win32\__VCVER__\bind\__TKNAM__.dll</OutputFile>
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||||
<AdditionalLibraryDirectories>..\..\..\win32\__VCVER__\libd;$(CSF_OPT_LIB32D);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
<AdditionalLibraryDirectories>..\..\..\win32\__VCVER__\libd;$(CSF_OPT_LIB32D);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||||
@@ -156,6 +166,7 @@
|
|||||||
<ProgramDatabaseFile>..\..\..\win32\__VCVER__\bind\__TKNAM__.pdb</ProgramDatabaseFile>
|
<ProgramDatabaseFile>..\..\..\win32\__VCVER__\bind\__TKNAM__.pdb</ProgramDatabaseFile>
|
||||||
<SubSystem>Console</SubSystem>
|
<SubSystem>Console</SubSystem>
|
||||||
<ImportLibrary>..\..\..\win32\__VCVER__\libd\__TKNAM__.lib</ImportLibrary>
|
<ImportLibrary>..\..\..\win32\__VCVER__\libd\__TKNAM__.lib</ImportLibrary>
|
||||||
|
__UWP_GENERATE_METADATA__
|
||||||
</Link>
|
</Link>
|
||||||
</ItemDefinitionGroup>
|
</ItemDefinitionGroup>
|
||||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||||
@@ -185,14 +196,16 @@
|
|||||||
<WarningLevel>Level4</WarningLevel>
|
<WarningLevel>Level4</WarningLevel>
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||||
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||||
<FloatingPointModel>Precise</FloatingPointModel>__VCMPL64__
|
<FloatingPointModel>Precise</FloatingPointModel>
|
||||||
|
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||||
|
__VCMPL64__
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
<ResourceCompile>
|
<ResourceCompile>
|
||||||
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>NDEBUG;No_Exception;$(CSF_DEFINES)__TKDEFS__;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>NDEBUG;No_Exception;$(CSF_DEFINES)__TKDEFS__;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
</ResourceCompile>
|
</ResourceCompile>
|
||||||
<Link>
|
<Link>
|
||||||
<AdditionalDependencies>__TKDEP__;ws2_32.lib;vfw32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
<AdditionalDependencies>__TKDEP__;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||||
<OutputFile>.\..\..\..\win64\__VCVER__\bin\__TKNAM__.dll</OutputFile>
|
<OutputFile>.\..\..\..\win64\__VCVER__\bin\__TKNAM__.dll</OutputFile>
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||||
<AdditionalLibraryDirectories>..\..\..\win64\__VCVER__\lib;$(CSF_OPT_LIB64);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
<AdditionalLibraryDirectories>..\..\..\win64\__VCVER__\lib;$(CSF_OPT_LIB64);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||||
@@ -200,6 +213,7 @@
|
|||||||
<ProgramDatabaseFile>.\..\..\..\win64\__VCVER__\bin\__TKNAM__.pdb</ProgramDatabaseFile>
|
<ProgramDatabaseFile>.\..\..\..\win64\__VCVER__\bin\__TKNAM__.pdb</ProgramDatabaseFile>
|
||||||
<SubSystem>Console</SubSystem>
|
<SubSystem>Console</SubSystem>
|
||||||
<ImportLibrary>..\..\..\win64\__VCVER__\lib\__TKNAM__.lib</ImportLibrary>
|
<ImportLibrary>..\..\..\win64\__VCVER__\lib\__TKNAM__.lib</ImportLibrary>
|
||||||
|
__UWP_GENERATE_METADATA__
|
||||||
</Link>
|
</Link>
|
||||||
</ItemDefinitionGroup>
|
</ItemDefinitionGroup>
|
||||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||||
@@ -230,14 +244,16 @@
|
|||||||
<CompileAs>Default</CompileAs>
|
<CompileAs>Default</CompileAs>
|
||||||
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||||
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
||||||
<FloatingPointModel>Precise</FloatingPointModel>__VCMPL64__
|
<FloatingPointModel>Precise</FloatingPointModel>
|
||||||
|
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||||
|
__VCMPL64__
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
<ResourceCompile>
|
<ResourceCompile>
|
||||||
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>_DEBUG;$(CSF_DEFINES)__TKDEFS__;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>_DEBUG;$(CSF_DEFINES)__TKDEFS__;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
</ResourceCompile>
|
</ResourceCompile>
|
||||||
<Link>
|
<Link>
|
||||||
<AdditionalDependencies>__TKDEP__;ws2_32.lib;vfw32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
<AdditionalDependencies>__TKDEP__;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||||
<OutputFile>.\..\..\..\win64\__VCVER__\bind\__TKNAM__.dll</OutputFile>
|
<OutputFile>.\..\..\..\win64\__VCVER__\bind\__TKNAM__.dll</OutputFile>
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||||
<AdditionalLibraryDirectories>..\..\..\win64\__VCVER__\libd;$(CSF_OPT_LIB64D);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
<AdditionalLibraryDirectories>..\..\..\win64\__VCVER__\libd;$(CSF_OPT_LIB64D);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||||
@@ -245,6 +261,7 @@
|
|||||||
<ProgramDatabaseFile>..\..\..\win64\__VCVER__\bind\__TKNAM__.pdb</ProgramDatabaseFile>
|
<ProgramDatabaseFile>..\..\..\win64\__VCVER__\bind\__TKNAM__.pdb</ProgramDatabaseFile>
|
||||||
<SubSystem>Console</SubSystem>
|
<SubSystem>Console</SubSystem>
|
||||||
<ImportLibrary>..\..\..\win64\__VCVER__\libd\__TKNAM__.lib</ImportLibrary>
|
<ImportLibrary>..\..\..\win64\__VCVER__\libd\__TKNAM__.lib</ImportLibrary>
|
||||||
|
__UWP_GENERATE_METADATA__
|
||||||
</Link>
|
</Link>
|
||||||
</ItemDefinitionGroup>
|
</ItemDefinitionGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
@@ -36,7 +36,7 @@
|
|||||||
Name="VCCustomBuildTool"/>
|
Name="VCCustomBuildTool"/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCLinkerTool"
|
Name="VCLinkerTool"
|
||||||
AdditionalDependencies="__TKDEP__ opengl32.lib glu32.lib ws2_32.lib vfw32.lib odbc32.lib odbccp32.lib"
|
AdditionalDependencies="__TKDEP__ opengl32.lib ws2_32.lib odbc32.lib odbccp32.lib"
|
||||||
OutputFile=".\..\..\..\win32\vc7\bin\__TKNAM__.dll"
|
OutputFile=".\..\..\..\win32\vc7\bin\__TKNAM__.dll"
|
||||||
LinkIncremental="1"
|
LinkIncremental="1"
|
||||||
SuppressStartupBanner="TRUE"
|
SuppressStartupBanner="TRUE"
|
||||||
@@ -105,7 +105,7 @@
|
|||||||
Name="VCCustomBuildTool"/>
|
Name="VCCustomBuildTool"/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCLinkerTool"
|
Name="VCLinkerTool"
|
||||||
AdditionalDependencies="__TKDEP__ opengl32.lib glu32.lib ws2_32.lib vfw32.lib odbc32.lib odbccp32.lib"
|
AdditionalDependencies="__TKDEP__ opengl32.lib ws2_32.lib odbc32.lib odbccp32.lib"
|
||||||
OutputFile=".\..\..\..\win32\vc7\bind\__TKNAM__.dll"
|
OutputFile=".\..\..\..\win32\vc7\bind\__TKNAM__.dll"
|
||||||
LinkIncremental="1"
|
LinkIncremental="1"
|
||||||
SuppressStartupBanner="TRUE"
|
SuppressStartupBanner="TRUE"
|
||||||
|
@@ -78,7 +78,7 @@
|
|||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCLinkerTool"
|
Name="VCLinkerTool"
|
||||||
AdditionalDependencies="__TKDEP__ opengl32.lib glu32.lib ws2_32.lib vfw32.lib odbc32.lib odbccp32.lib"
|
AdditionalDependencies="__TKDEP__ opengl32.lib ws2_32.lib odbc32.lib odbccp32.lib"
|
||||||
OutputFile=".\..\..\..\win32\vc8\bin\__TKNAM__.dll"
|
OutputFile=".\..\..\..\win32\vc8\bin\__TKNAM__.dll"
|
||||||
LinkIncremental="1"
|
LinkIncremental="1"
|
||||||
SuppressStartupBanner="true"
|
SuppressStartupBanner="true"
|
||||||
@@ -178,7 +178,7 @@
|
|||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCLinkerTool"
|
Name="VCLinkerTool"
|
||||||
AdditionalDependencies="__TKDEP__ opengl32.lib glu32.lib ws2_32.lib vfw32.lib odbc32.lib odbccp32.lib"
|
AdditionalDependencies="__TKDEP__ opengl32.lib ws2_32.lib odbc32.lib odbccp32.lib"
|
||||||
OutputFile=".\..\..\..\win32\vc8\bind\__TKNAM__.dll"
|
OutputFile=".\..\..\..\win32\vc8\bind\__TKNAM__.dll"
|
||||||
LinkIncremental="1"
|
LinkIncremental="1"
|
||||||
SuppressStartupBanner="true"
|
SuppressStartupBanner="true"
|
||||||
@@ -276,7 +276,7 @@
|
|||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCLinkerTool"
|
Name="VCLinkerTool"
|
||||||
AdditionalDependencies="__TKDEP__ opengl32.lib glu32.lib ws2_32.lib vfw32.lib odbc32.lib odbccp32.lib"
|
AdditionalDependencies="__TKDEP__ opengl32.lib ws2_32.lib odbc32.lib odbccp32.lib"
|
||||||
OutputFile=".\..\..\..\win64\vc8\bin\__TKNAM__.dll"
|
OutputFile=".\..\..\..\win64\vc8\bin\__TKNAM__.dll"
|
||||||
LinkIncremental="1"
|
LinkIncremental="1"
|
||||||
SuppressStartupBanner="true"
|
SuppressStartupBanner="true"
|
||||||
@@ -376,7 +376,7 @@
|
|||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCLinkerTool"
|
Name="VCLinkerTool"
|
||||||
AdditionalDependencies="__TKDEP__ opengl32.lib glu32.lib ws2_32.lib vfw32.lib odbc32.lib odbccp32.lib"
|
AdditionalDependencies="__TKDEP__ opengl32.lib ws2_32.lib odbc32.lib odbccp32.lib"
|
||||||
OutputFile=".\..\..\..\win64\vc8\bind\__TKNAM__.dll"
|
OutputFile=".\..\..\..\win64\vc8\bind\__TKNAM__.dll"
|
||||||
LinkIncremental="1"
|
LinkIncremental="1"
|
||||||
SuppressStartupBanner="true"
|
SuppressStartupBanner="true"
|
||||||
|
@@ -79,7 +79,7 @@
|
|||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCLinkerTool"
|
Name="VCLinkerTool"
|
||||||
AdditionalDependencies="__TKDEP__ ws2_32.lib vfw32.lib"
|
AdditionalDependencies="__TKDEP__ ws2_32.lib"
|
||||||
OutputFile=".\..\..\..\win32\vc9\bin\__TKNAM__.dll"
|
OutputFile=".\..\..\..\win32\vc9\bin\__TKNAM__.dll"
|
||||||
LinkIncremental="1"
|
LinkIncremental="1"
|
||||||
SuppressStartupBanner="true"
|
SuppressStartupBanner="true"
|
||||||
@@ -178,7 +178,7 @@
|
|||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCLinkerTool"
|
Name="VCLinkerTool"
|
||||||
AdditionalDependencies="__TKDEP__ ws2_32.lib vfw32.lib"
|
AdditionalDependencies="__TKDEP__ ws2_32.lib"
|
||||||
OutputFile=".\..\..\..\win32\vc9\bind\__TKNAM__.dll"
|
OutputFile=".\..\..\..\win32\vc9\bind\__TKNAM__.dll"
|
||||||
LinkIncremental="1"
|
LinkIncremental="1"
|
||||||
SuppressStartupBanner="true"
|
SuppressStartupBanner="true"
|
||||||
@@ -272,7 +272,7 @@
|
|||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCLinkerTool"
|
Name="VCLinkerTool"
|
||||||
AdditionalDependencies="__TKDEP__ ws2_32.lib vfw32.lib"
|
AdditionalDependencies="__TKDEP__ ws2_32.lib"
|
||||||
OutputFile=".\..\..\..\win64\vc9\bin\__TKNAM__.dll"
|
OutputFile=".\..\..\..\win64\vc9\bin\__TKNAM__.dll"
|
||||||
LinkIncremental="1"
|
LinkIncremental="1"
|
||||||
SuppressStartupBanner="true"
|
SuppressStartupBanner="true"
|
||||||
@@ -368,7 +368,7 @@
|
|||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCLinkerTool"
|
Name="VCLinkerTool"
|
||||||
AdditionalDependencies="__TKDEP__ ws2_32.lib vfw32.lib"
|
AdditionalDependencies="__TKDEP__ ws2_32.lib"
|
||||||
OutputFile=".\..\..\..\win64\vc9\bind\__TKNAM__.dll"
|
OutputFile=".\..\..\..\win64\vc9\bind\__TKNAM__.dll"
|
||||||
LinkIncremental="1"
|
LinkIncremental="1"
|
||||||
SuppressStartupBanner="true"
|
SuppressStartupBanner="true"
|
||||||
|
5
adm/templates/uwp.toolchain.config.cmake
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
# A toolchain file to configure a Visual Studio generator for a Windows 10 Universal Application (UWP)
|
||||||
|
# Specify the CMAKE_SYSTEM_VERSION variable to be 10.0 to build with the latest available Windows 10 SDK.
|
||||||
|
|
||||||
|
set (CMAKE_SYSTEM_NAME WindowsStore)
|
||||||
|
set (CMAKE_SYSTEM_VERSION 10.0)
|
@@ -1,5 +1,8 @@
|
|||||||
[rename]
|
[rename]
|
||||||
BRepExtrema_OverlappedSubShapes BRepExtrema_MapOfIntegerPackedMapOfInteger
|
BRepExtrema_OverlappedSubShapes BRepExtrema_MapOfIntegerPackedMapOfInteger
|
||||||
|
ShapeConstruct_CompBezierCurves2dToBSplineCurve2d Convert_CompBezierCurves2dToBSplineCurve2d
|
||||||
|
ShapeConstruct_CompBezierCurves2dToBSplineCurve Convert_CompBezierCurves2dToBSplineCurve
|
||||||
|
Image_PixMap::Img Image_Format_
|
||||||
|
|
||||||
[tcollection]
|
[tcollection]
|
||||||
AdvApp2Var_SequenceOfNode
|
AdvApp2Var_SequenceOfNode
|
||||||
|
0
samples/mfc/standard/04_Viewer3d/Data/carrelage1.gif → data/images/carrelage1.gif
Executable file → Normal file
Before Width: | Height: | Size: 106 KiB After Width: | Height: | Size: 106 KiB |
0
samples/mfc/standard/04_Viewer3d/Data/chataignier.gif → data/images/chataignier.gif
Executable file → Normal file
Before Width: | Height: | Size: 6.0 KiB After Width: | Height: | Size: 6.0 KiB |
0
samples/mfc/standard/04_Viewer3d/Data/cookerplate.gif → data/images/cookerplate.gif
Executable file → Normal file
Before Width: | Height: | Size: 8.6 KiB After Width: | Height: | Size: 8.6 KiB |
BIN
data/images/marker_kr.png
Normal file
After Width: | Height: | Size: 1.0 KiB |
0
samples/mfc/standard/04_Viewer3d/Data/plancher.gif → data/images/plancher.gif
Executable file → Normal file
Before Width: | Height: | Size: 188 KiB After Width: | Height: | Size: 188 KiB |
0
samples/mfc/standard/04_Viewer3d/Data/terrain.gif → data/images/terrain.gif
Executable file → Normal file
Before Width: | Height: | Size: 222 KiB After Width: | Height: | Size: 222 KiB |
0
samples/mfc/standard/04_Viewer3d/Data/wallpaper.gif → data/images/wallpaper.gif
Executable file → Normal file
Before Width: | Height: | Size: 6.5 KiB After Width: | Height: | Size: 6.5 KiB |
1131
data/occ/Ball.brep
Normal file
0
samples/mfc/standard/09_Animation/data/Box.brep → data/occ/Box.brep
Executable file → Normal file
0
samples/mfc/standard/09_Animation/data/MAT.brep → data/occ/MAT.brep
Executable file → Normal file
0
samples/mfc/standard/09_Animation/data/MAT.pnt → data/occ/MAT.pnt
Executable file → Normal file
0
samples/mfc/standard/04_Viewer3d/Data/Kitchen/MODERN_Chair_1.brep → data/occ/MODERN_Chair_1.brep
Executable file → Normal file
0
samples/mfc/standard/04_Viewer3d/Data/Kitchen/MODERN_Cooker_1.brep → data/occ/MODERN_Cooker_1.brep
Executable file → Normal file
0
samples/mfc/standard/04_Viewer3d/Data/Kitchen/MODERN_Cooker_1_opened.brep → data/occ/MODERN_Cooker_1_opened.brep
Executable file → Normal file
0
samples/mfc/standard/04_Viewer3d/Data/Kitchen/MODERN_Exhaust_1.brep → data/occ/MODERN_Exhaust_1.brep
Executable file → Normal file
0
samples/mfc/standard/04_Viewer3d/Data/Kitchen/MODERN_MVCooker_1.brep → data/occ/MODERN_MVCooker_1.brep
Executable file → Normal file
0
samples/mfc/standard/04_Viewer3d/Data/Kitchen/MODERN_MVCooker_1_opened.brep → data/occ/MODERN_MVCooker_1_opened.brep
Executable file → Normal file
0
samples/mfc/standard/04_Viewer3d/Data/Kitchen/MODERN_Refrigerator_1.brep → data/occ/MODERN_Refrigerator_1.brep
Executable file → Normal file
0
samples/mfc/standard/04_Viewer3d/Data/Kitchen/MODERN_Refrigerator_1_opened.brep → data/occ/MODERN_Refrigerator_1_opened.brep
Executable file → Normal file
0
samples/mfc/standard/04_Viewer3d/Data/Kitchen/MODERN_Sink_1.brep → data/occ/MODERN_Sink_1.brep
Executable file → Normal file
0
samples/mfc/standard/04_Viewer3d/Data/Kitchen/MODERN_Sink_1_opened.brep → data/occ/MODERN_Sink_1_opened.brep
Executable file → Normal file
0
samples/mfc/standard/04_Viewer3d/Data/Kitchen/MODERN_Table_1.brep → data/occ/MODERN_Table_1.brep
Executable file → Normal file
0
samples/mfc/standard/Data/Pump_Nut.brep → data/occ/Pump_Nut.brep
Executable file → Normal file
0
samples/mfc/standard/Data/Pump_TopCover.brep → data/occ/Pump_TopCover.brep
Executable file → Normal file
0
samples/mfc/standard/04_Viewer3d/Data/Kitchen/Room.brep → data/occ/Room.brep
Executable file → Normal file
0
samples/mfc/standard/01_Geometry/Data/SurfaceFromPoints/sol1.dat → data/occ/SurfaceFromPoints/sol1.dat
Executable file → Normal file
0
samples/mfc/standard/01_Geometry/Data/SurfaceFromPoints/sol2.dat → data/occ/SurfaceFromPoints/sol2.dat
Executable file → Normal file
0
samples/mfc/standard/09_Animation/data/asahi.brep → data/occ/asahi.brep
Executable file → Normal file
0
samples/mfc/standard/04_Viewer3d/Data/bottle.brep → data/occ/bottle.brep
Executable file → Normal file
0
samples/mfc/standard/03_Viewer2d/data/Face.BRep → data/occ/face2.brep
Executable file → Normal file
0
samples/mfc/standard/01_Geometry/Data/shell1.brep → data/occ/shell1.brep
Executable file → Normal file
0
samples/mfc/standard/04_Viewer3d/Data/terrain.brep → data/occ/terrain.brep
Executable file → Normal file
0
samples/mfc/standard/Data/wedge_ok.brep → data/occ/wedge_ok.brep
Executable file → Normal file
@@ -35,7 +35,7 @@ endif()
|
|||||||
# configuration file for doxygen
|
# configuration file for doxygen
|
||||||
set (OCCT_CONFIG_FOR_DOXYGEN "${OCCT_GENERATED_DOC_DIR}/occt.cfg")
|
set (OCCT_CONFIG_FOR_DOXYGEN "${OCCT_GENERATED_DOC_DIR}/occt.cfg")
|
||||||
|
|
||||||
set (3RDPARTY_MATHJAX_RELATIVE_PATH "http://cdn.mathjax.org/mathjax/latest")
|
set (3RDPARTY_MATHJAX_RELATIVE_PATH "https://cdn.mathjax.org/mathjax/latest")
|
||||||
|
|
||||||
configure_file ("${OCCT_OVERVIEW_RESOURCE_DIR}/occt_ug_html.doxyfile" "${OCCT_CONFIG_FOR_DOXYGEN}" COPYONLY)
|
configure_file ("${OCCT_OVERVIEW_RESOURCE_DIR}/occt_ug_html.doxyfile" "${OCCT_CONFIG_FOR_DOXYGEN}" COPYONLY)
|
||||||
|
|
||||||
@@ -92,11 +92,22 @@ file (APPEND ${OCCT_CONFIG_FOR_DOXYGEN} "\nMATHJAX_RELPATH = ${3RDPARTY_M
|
|||||||
# Copy index file to provide fast access to HTML documentation
|
# Copy index file to provide fast access to HTML documentation
|
||||||
file(COPY "${OCCT_OVERVIEW_RESOURCE_DIR}/index.html" DESTINATION "${OCCT_GENERATED_OVERVIEW_DIR}")
|
file(COPY "${OCCT_OVERVIEW_RESOURCE_DIR}/index.html" DESTINATION "${OCCT_GENERATED_OVERVIEW_DIR}")
|
||||||
|
|
||||||
add_custom_target (${PROJECT_NAME}
|
# get relative paths to documentation source files
|
||||||
COMMAND ${3RDPARTY_DOXYGEN_EXECUTABLE} ${OCCT_CONFIG_FOR_DOXYGEN}
|
file (GLOB_RECURSE OCCT_OVERVIEW_FILES "${OCCT_OVERVIEW_DIR}/*")
|
||||||
WORKING_DIRECTORY ${OCCT_GENERATED_DOC_DIR}
|
|
||||||
COMMENT "Generating OCCT overview documentation with Doxygen"
|
|
||||||
SOURCES ${OCCT_ARTICLES_ABSPATH}
|
|
||||||
VERBATIM)
|
|
||||||
|
|
||||||
|
add_custom_command(OUTPUT "${OCCT_GENERATED_DOC_DIR}/overview/html/occt_logo.png"
|
||||||
|
COMMAND ${3RDPARTY_DOXYGEN_EXECUTABLE} ${OCCT_CONFIG_FOR_DOXYGEN}
|
||||||
|
DEPENDS ${OCCT_OVERVIEW_FILES}
|
||||||
|
WORKING_DIRECTORY ${OCCT_GENERATED_DOC_DIR}
|
||||||
|
COMMENT "Generating OCCT overview documentation with Doxygen"
|
||||||
|
VERBATIM
|
||||||
|
)
|
||||||
|
|
||||||
|
add_custom_target(${PROJECT_NAME} ALL
|
||||||
|
DEPENDS "${OCCT_GENERATED_DOC_DIR}/overview/html/occt_logo.png" ${OCCT_OVERVIEW_FILES}
|
||||||
|
SOURCES ${OCCT_ARTICLES_ABSPATH}
|
||||||
|
VERBATIM
|
||||||
|
)
|
||||||
|
|
||||||
|
# Create Documentation folder in solution view
|
||||||
set_property (TARGET ${PROJECT_NAME} PROPERTY FOLDER "Documentation")
|
set_property (TARGET ${PROJECT_NAME} PROPERTY FOLDER "Documentation")
|
||||||
|
521
dox/LICENSE.md
@@ -1,521 +0,0 @@
|
|||||||
License {#occt_public_license}
|
|
||||||
=======
|
|
||||||
|
|
||||||
Open CASCADE Technology is available under GNU Lesser General Public License
|
|
||||||
(LGPL) version 2.1 with additional exception.
|
|
||||||
|
|
||||||
@section license_lgpl_21 GNU LESSER GENERAL PUBLIC LICENSE
|
|
||||||
|
|
||||||
Version 2.1, February 1999
|
|
||||||
|
|
||||||
Copyright (C) 1991, 1999 Free Software Foundation, Inc.
|
|
||||||
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|
||||||
Everyone is permitted to copy and distribute verbatim copies
|
|
||||||
of this license document, but changing it is not allowed.
|
|
||||||
|
|
||||||
[This is the first released version of the Lesser GPL. It also counts
|
|
||||||
as the successor of the GNU Library Public License, version 2, hence
|
|
||||||
the version number 2.1.]
|
|
||||||
|
|
||||||
### Preamble
|
|
||||||
|
|
||||||
The licenses for most software are designed to take away your
|
|
||||||
freedom to share and change it. By contrast, the GNU General Public
|
|
||||||
Licenses are intended to guarantee your freedom to share and change
|
|
||||||
free software--to make sure the software is free for all its users.
|
|
||||||
|
|
||||||
This license, the Lesser General Public License, applies to some
|
|
||||||
specially designated software packages--typically libraries--of the
|
|
||||||
Free Software Foundation and other authors who decide to use it. You
|
|
||||||
can use it too, but we suggest you first think carefully about whether
|
|
||||||
this license or the ordinary General Public License is the better
|
|
||||||
strategy to use in any particular case, based on the explanations below.
|
|
||||||
|
|
||||||
When we speak of free software, we are referring to freedom of use,
|
|
||||||
not price. Our General Public Licenses are designed to make sure that
|
|
||||||
you have the freedom to distribute copies of free software (and charge
|
|
||||||
for this service if you wish); that you receive source code or can get
|
|
||||||
it if you want it; that you can change the software and use pieces of
|
|
||||||
it in new free programs; and that you are informed that you can do
|
|
||||||
these things.
|
|
||||||
|
|
||||||
To protect your rights, we need to make restrictions that forbid
|
|
||||||
distributors to deny you these rights or to ask you to surrender these
|
|
||||||
rights. These restrictions translate to certain responsibilities for
|
|
||||||
you if you distribute copies of the library or if you modify it.
|
|
||||||
|
|
||||||
For example, if you distribute copies of the library, whether gratis
|
|
||||||
or for a fee, you must give the recipients all the rights that we gave
|
|
||||||
you. You must make sure that they, too, receive or can get the source
|
|
||||||
code. If you link other code with the library, you must provide
|
|
||||||
complete object files to the recipients, so that they can relink them
|
|
||||||
with the library after making changes to the library and recompiling
|
|
||||||
it. And you must show them these terms so they know their rights.
|
|
||||||
|
|
||||||
We protect your rights with a two-step method: (1) we copyright the
|
|
||||||
library, and (2) we offer you this license, which gives you legal
|
|
||||||
permission to copy, distribute and/or modify the library.
|
|
||||||
|
|
||||||
To protect each distributor, we want to make it very clear that
|
|
||||||
there is no warranty for the free library. Also, if the library is
|
|
||||||
modified by someone else and passed on, the recipients should know
|
|
||||||
that what they have is not the original version, so that the original
|
|
||||||
author's reputation will not be affected by problems that might be
|
|
||||||
introduced by others.
|
|
||||||
|
|
||||||
Finally, software patents pose a constant threat to the existence of
|
|
||||||
any free program. We wish to make sure that a company cannot
|
|
||||||
effectively restrict the users of a free program by obtaining a
|
|
||||||
restrictive license from a patent holder. Therefore, we insist that
|
|
||||||
any patent license obtained for a version of the library must be
|
|
||||||
consistent with the full freedom of use specified in this license.
|
|
||||||
|
|
||||||
Most GNU software, including some libraries, is covered by the
|
|
||||||
ordinary GNU General Public License. This license, the GNU Lesser
|
|
||||||
General Public License, applies to certain designated libraries, and
|
|
||||||
is quite different from the ordinary General Public License. We use
|
|
||||||
this license for certain libraries in order to permit linking those
|
|
||||||
libraries into non-free programs.
|
|
||||||
|
|
||||||
When a program is linked with a library, whether statically or using
|
|
||||||
a shared library, the combination of the two is legally speaking a
|
|
||||||
combined work, a derivative of the original library. The ordinary
|
|
||||||
General Public License therefore permits such linking only if the
|
|
||||||
entire combination fits its criteria of freedom. The Lesser General
|
|
||||||
Public License permits more lax criteria for linking other code with
|
|
||||||
the library.
|
|
||||||
|
|
||||||
We call this license the "Lesser" General Public License because it
|
|
||||||
does Less to protect the user's freedom than the ordinary General
|
|
||||||
Public License. It also provides other free software developers Less
|
|
||||||
of an advantage over competing non-free programs. These disadvantages
|
|
||||||
are the reason we use the ordinary General Public License for many
|
|
||||||
libraries. However, the Lesser license provides advantages in certain
|
|
||||||
special circumstances.
|
|
||||||
|
|
||||||
For example, on rare occasions, there may be a special need to
|
|
||||||
encourage the widest possible use of a certain library, so that it becomes
|
|
||||||
a de-facto standard. To achieve this, non-free programs must be
|
|
||||||
allowed to use the library. A more frequent case is that a free
|
|
||||||
library does the same job as widely used non-free libraries. In this
|
|
||||||
case, there is little to gain by limiting the free library to free
|
|
||||||
software only, so we use the Lesser General Public License.
|
|
||||||
|
|
||||||
In other cases, permission to use a particular library in non-free
|
|
||||||
programs enables a greater number of people to use a large body of
|
|
||||||
free software. For example, permission to use the GNU C Library in
|
|
||||||
non-free programs enables many more people to use the whole GNU
|
|
||||||
operating system, as well as its variant, the GNU/Linux operating
|
|
||||||
system.
|
|
||||||
|
|
||||||
Although the Lesser General Public License is Less protective of the
|
|
||||||
users' freedom, it does ensure that the user of a program that is
|
|
||||||
linked with the Library has the freedom and the wherewithal to run
|
|
||||||
that program using a modified version of the Library.
|
|
||||||
|
|
||||||
The precise terms and conditions for copying, distribution and
|
|
||||||
modification follow. Pay close attention to the difference between a
|
|
||||||
"work based on the library" and a "work that uses the library". The
|
|
||||||
former contains code derived from the library, whereas the latter must
|
|
||||||
be combined with the library in order to run.
|
|
||||||
|
|
||||||
### TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
|
||||||
|
|
||||||
- 0. This License Agreement applies to any software library or other
|
|
||||||
program which contains a notice placed by the copyright holder or
|
|
||||||
other authorized party saying it may be distributed under the terms of
|
|
||||||
this Lesser General Public License (also called "this License").
|
|
||||||
Each licensee is addressed as "you".
|
|
||||||
|
|
||||||
A "library" means a collection of software functions and/or data
|
|
||||||
prepared so as to be conveniently linked with application programs
|
|
||||||
(which use some of those functions and data) to form executables.
|
|
||||||
|
|
||||||
The "Library", below, refers to any such software library or work
|
|
||||||
which has been distributed under these terms. A "work based on the
|
|
||||||
Library" means either the Library or any derivative work under
|
|
||||||
copyright law: that is to say, a work containing the Library or a
|
|
||||||
portion of it, either verbatim or with modifications and/or translated
|
|
||||||
straightforwardly into another language. (Hereinafter, translation is
|
|
||||||
included without limitation in the term "modification".)
|
|
||||||
|
|
||||||
"Source code" for a work means the preferred form of the work for
|
|
||||||
making modifications to it. For a library, complete source code means
|
|
||||||
all the source code for all modules it contains, plus any associated
|
|
||||||
interface definition files, plus the scripts used to control compilation
|
|
||||||
and installation of the library.
|
|
||||||
|
|
||||||
Activities other than copying, distribution and modification are not
|
|
||||||
covered by this License; they are outside its scope. The act of
|
|
||||||
running a program using the Library is not restricted, and output from
|
|
||||||
such a program is covered only if its contents constitute a work based
|
|
||||||
on the Library (independent of the use of the Library in a tool for
|
|
||||||
writing it). Whether that is true depends on what the Library does
|
|
||||||
and what the program that uses the Library does.
|
|
||||||
|
|
||||||
1. You may copy and distribute verbatim copies of the Library's
|
|
||||||
complete source code as you receive it, in any medium, provided that
|
|
||||||
you conspicuously and appropriately publish on each copy an
|
|
||||||
appropriate copyright notice and disclaimer of warranty; keep intact
|
|
||||||
all the notices that refer to this License and to the absence of any
|
|
||||||
warranty; and distribute a copy of this License along with the
|
|
||||||
Library.
|
|
||||||
|
|
||||||
You may charge a fee for the physical act of transferring a copy,
|
|
||||||
and you may at your option offer warranty protection in exchange for a
|
|
||||||
fee.
|
|
||||||
|
|
||||||
2. You may modify your copy or copies of the Library or any portion
|
|
||||||
of it, thus forming a work based on the Library, and copy and
|
|
||||||
distribute such modifications or work under the terms of Section 1
|
|
||||||
above, provided that you also meet all of these conditions:
|
|
||||||
|
|
||||||
1. The modified work must itself be a software library.
|
|
||||||
|
|
||||||
2. You must cause the files modified to carry prominent notices
|
|
||||||
stating that you changed the files and the date of any change.
|
|
||||||
|
|
||||||
3. You must cause the whole of the work to be licensed at no
|
|
||||||
charge to all third parties under the terms of this License.
|
|
||||||
|
|
||||||
4. If a facility in the modified Library refers to a function or a
|
|
||||||
table of data to be supplied by an application program that uses
|
|
||||||
the facility, other than as an argument passed when the facility
|
|
||||||
is invoked, then you must make a good faith effort to ensure that,
|
|
||||||
in the event an application does not supply such function or
|
|
||||||
table, the facility still operates, and performs whatever part of
|
|
||||||
its purpose remains meaningful.
|
|
||||||
|
|
||||||
(For example, a function in a library to compute square roots has
|
|
||||||
a purpose that is entirely well-defined independent of the
|
|
||||||
application. Therefore, Subsection 2d requires that any
|
|
||||||
application-supplied function or table used by this function must
|
|
||||||
be optional: if the application does not supply it, the square
|
|
||||||
root function must still compute square roots.)
|
|
||||||
|
|
||||||
These requirements apply to the modified work as a whole. If
|
|
||||||
identifiable sections of that work are not derived from the Library,
|
|
||||||
and can be reasonably considered independent and separate works in
|
|
||||||
themselves, then this License, and its terms, do not apply to those
|
|
||||||
sections when you distribute them as separate works. But when you
|
|
||||||
distribute the same sections as part of a whole which is a work based
|
|
||||||
on the Library, the distribution of the whole must be on the terms of
|
|
||||||
this License, whose permissions for other licensees extend to the
|
|
||||||
entire whole, and thus to each and every part regardless of who wrote
|
|
||||||
it.
|
|
||||||
|
|
||||||
Thus, it is not the intent of this section to claim rights or contest
|
|
||||||
your rights to work written entirely by you; rather, the intent is to
|
|
||||||
exercise the right to control the distribution of derivative or
|
|
||||||
collective works based on the Library.
|
|
||||||
|
|
||||||
In addition, mere aggregation of another work not based on the Library
|
|
||||||
with the Library (or with a work based on the Library) on a volume of
|
|
||||||
a storage or distribution medium does not bring the other work under
|
|
||||||
the scope of this License.
|
|
||||||
|
|
||||||
3. You may opt to apply the terms of the ordinary GNU General Public
|
|
||||||
License instead of this License to a given copy of the Library. To do
|
|
||||||
this, you must alter all the notices that refer to this License, so
|
|
||||||
that they refer to the ordinary GNU General Public License, version 2,
|
|
||||||
instead of to this License. (If a newer version than version 2 of the
|
|
||||||
ordinary GNU General Public License has appeared, then you can specify
|
|
||||||
that version instead if you wish.) Do not make any other change in
|
|
||||||
these notices.
|
|
||||||
|
|
||||||
Once this change is made in a given copy, it is irreversible for
|
|
||||||
that copy, so the ordinary GNU General Public License applies to all
|
|
||||||
subsequent copies and derivative works made from that copy.
|
|
||||||
|
|
||||||
This option is useful when you wish to copy part of the code of
|
|
||||||
the Library into a program that is not a library.
|
|
||||||
|
|
||||||
4. You may copy and distribute the Library (or a portion or
|
|
||||||
derivative of it, under Section 2) in object code or executable form
|
|
||||||
under the terms of Sections 1 and 2 above provided that you accompany
|
|
||||||
it with the complete corresponding machine-readable source code, which
|
|
||||||
must be distributed under the terms of Sections 1 and 2 above on a
|
|
||||||
medium customarily used for software interchange.
|
|
||||||
|
|
||||||
If distribution of object code is made by offering access to copy
|
|
||||||
from a designated place, then offering equivalent access to copy the
|
|
||||||
source code from the same place satisfies the requirement to
|
|
||||||
distribute the source code, even though third parties are not
|
|
||||||
compelled to copy the source along with the object code.
|
|
||||||
|
|
||||||
5. A program that contains no derivative of any portion of the
|
|
||||||
Library, but is designed to work with the Library by being compiled or
|
|
||||||
linked with it, is called a "work that uses the Library". Such a
|
|
||||||
work, in isolation, is not a derivative work of the Library, and
|
|
||||||
therefore falls outside the scope of this License.
|
|
||||||
|
|
||||||
However, linking a "work that uses the Library" with the Library
|
|
||||||
creates an executable that is a derivative of the Library (because it
|
|
||||||
contains portions of the Library), rather than a "work that uses the
|
|
||||||
library". The executable is therefore covered by this License.
|
|
||||||
Section 6 states terms for distribution of such executables.
|
|
||||||
|
|
||||||
When a "work that uses the Library" uses material from a header file
|
|
||||||
that is part of the Library, the object code for the work may be a
|
|
||||||
derivative work of the Library even though the source code is not.
|
|
||||||
Whether this is true is especially significant if the work can be
|
|
||||||
linked without the Library, or if the work is itself a library. The
|
|
||||||
threshold for this to be true is not precisely defined by law.
|
|
||||||
|
|
||||||
If such an object file uses only numerical parameters, data
|
|
||||||
structure layouts and accessors, and small macros and small inline
|
|
||||||
functions (ten lines or less in length), then the use of the object
|
|
||||||
file is unrestricted, regardless of whether it is legally a derivative
|
|
||||||
work. (Executables containing this object code plus portions of the
|
|
||||||
Library will still fall under Section 6.)
|
|
||||||
|
|
||||||
Otherwise, if the work is a derivative of the Library, you may
|
|
||||||
distribute the object code for the work under the terms of Section 6.
|
|
||||||
Any executables containing that work also fall under Section 6,
|
|
||||||
whether or not they are linked directly with the Library itself.
|
|
||||||
|
|
||||||
6. As an exception to the Sections above, you may also combine or
|
|
||||||
link a "work that uses the Library" with the Library to produce a
|
|
||||||
work containing portions of the Library, and distribute that work
|
|
||||||
under terms of your choice, provided that the terms permit
|
|
||||||
modification of the work for the customer's own use and reverse
|
|
||||||
engineering for debugging such modifications.
|
|
||||||
|
|
||||||
You must give prominent notice with each copy of the work that the
|
|
||||||
Library is used in it and that the Library and its use are covered by
|
|
||||||
this License. You must supply a copy of this License. If the work
|
|
||||||
during execution displays copyright notices, you must include the
|
|
||||||
copyright notice for the Library among them, as well as a reference
|
|
||||||
directing the user to the copy of this License. Also, you must do one
|
|
||||||
of these things:
|
|
||||||
|
|
||||||
1. Accompany the work with the complete corresponding
|
|
||||||
machine-readable source code for the Library including whatever
|
|
||||||
changes were used in the work (which must be distributed under
|
|
||||||
Sections 1 and 2 above); and, if the work is an executable linked
|
|
||||||
with the Library, with the complete machine-readable "work that
|
|
||||||
uses the Library", as object code and/or source code, so that the
|
|
||||||
user can modify the Library and then relink to produce a modified
|
|
||||||
executable containing the modified Library. (It is understood
|
|
||||||
that the user who changes the contents of definitions files in the
|
|
||||||
Library will not necessarily be able to recompile the application
|
|
||||||
to use the modified definitions.)
|
|
||||||
|
|
||||||
2. Use a suitable shared library mechanism for linking with the
|
|
||||||
Library. A suitable mechanism is one that (1) uses at run time a
|
|
||||||
copy of the library already present on the user's computer system,
|
|
||||||
rather than copying library functions into the executable, and (2)
|
|
||||||
will operate properly with a modified version of the library, if
|
|
||||||
the user installs one, as long as the modified version is
|
|
||||||
interface-compatible with the version that the work was made with.
|
|
||||||
|
|
||||||
3. Accompany the work with a written offer, valid for at
|
|
||||||
least three years, to give the same user the materials
|
|
||||||
specified in Subsection 6a, above, for a charge no more
|
|
||||||
than the cost of performing this distribution.
|
|
||||||
|
|
||||||
4. If distribution of the work is made by offering access to copy
|
|
||||||
from a designated place, offer equivalent access to copy the above
|
|
||||||
specified materials from the same place.
|
|
||||||
|
|
||||||
5. Verify that the user has already received a copy of these
|
|
||||||
materials or that you have already sent this user a copy.
|
|
||||||
|
|
||||||
For an executable, the required form of the "work that uses the
|
|
||||||
Library" must include any data and utility programs needed for
|
|
||||||
reproducing the executable from it. However, as a special exception,
|
|
||||||
the materials to be distributed need not include anything that is
|
|
||||||
normally distributed (in either source or binary form) with the major
|
|
||||||
components (compiler, kernel, and so on) of the operating system on
|
|
||||||
which the executable runs, unless that component itself accompanies
|
|
||||||
the executable.
|
|
||||||
|
|
||||||
It may happen that this requirement contradicts the license
|
|
||||||
restrictions of other proprietary libraries that do not normally
|
|
||||||
accompany the operating system. Such a contradiction means you cannot
|
|
||||||
use both them and the Library together in an executable that you
|
|
||||||
distribute.
|
|
||||||
|
|
||||||
7. You may place library facilities that are a work based on the
|
|
||||||
Library side-by-side in a single library together with other library
|
|
||||||
facilities not covered by this License, and distribute such a combined
|
|
||||||
library, provided that the separate distribution of the work based on
|
|
||||||
the Library and of the other library facilities is otherwise
|
|
||||||
permitted, and provided that you do these two things:
|
|
||||||
|
|
||||||
1. Accompany the combined library with a copy of the same work
|
|
||||||
based on the Library, uncombined with any other library
|
|
||||||
facilities. This must be distributed under the terms of the
|
|
||||||
Sections above.
|
|
||||||
|
|
||||||
2. Give prominent notice with the combined library of the fact
|
|
||||||
that part of it is a work based on the Library, and explaining
|
|
||||||
where to find the accompanying uncombined form of the same work.
|
|
||||||
|
|
||||||
8. You may not copy, modify, sublicense, link with, or distribute
|
|
||||||
the Library except as expressly provided under this License. Any
|
|
||||||
attempt otherwise to copy, modify, sublicense, link with, or
|
|
||||||
distribute the Library is void, and will automatically terminate your
|
|
||||||
rights under this License. However, parties who have received copies,
|
|
||||||
or rights, from you under this License will not have their licenses
|
|
||||||
terminated so long as such parties remain in full compliance.
|
|
||||||
|
|
||||||
9. You are not required to accept this License, since you have not
|
|
||||||
signed it. However, nothing else grants you permission to modify or
|
|
||||||
distribute the Library or its derivative works. These actions are
|
|
||||||
prohibited by law if you do not accept this License. Therefore, by
|
|
||||||
modifying or distributing the Library (or any work based on the
|
|
||||||
Library), you indicate your acceptance of this License to do so, and
|
|
||||||
all its terms and conditions for copying, distributing or modifying
|
|
||||||
the Library or works based on it.
|
|
||||||
|
|
||||||
10. Each time you redistribute the Library (or any work based on the
|
|
||||||
Library), the recipient automatically receives a license from the
|
|
||||||
original licensor to copy, distribute, link with or modify the Library
|
|
||||||
subject to these terms and conditions. You may not impose any further
|
|
||||||
restrictions on the recipients' exercise of the rights granted herein.
|
|
||||||
You are not responsible for enforcing compliance by third parties with
|
|
||||||
this License.
|
|
||||||
|
|
||||||
11. If, as a consequence of a court judgment or allegation of patent
|
|
||||||
infringement or for any other reason (not limited to patent issues),
|
|
||||||
conditions are imposed on you (whether by court order, agreement or
|
|
||||||
otherwise) that contradict the conditions of this License, they do not
|
|
||||||
excuse you from the conditions of this License. If you cannot
|
|
||||||
distribute so as to satisfy simultaneously your obligations under this
|
|
||||||
License and any other pertinent obligations, then as a consequence you
|
|
||||||
may not distribute the Library at all. For example, if a patent
|
|
||||||
license would not permit royalty-free redistribution of the Library by
|
|
||||||
all those who receive copies directly or indirectly through you, then
|
|
||||||
the only way you could satisfy both it and this License would be to
|
|
||||||
refrain entirely from distribution of the Library.
|
|
||||||
|
|
||||||
If any portion of this section is held invalid or unenforceable under any
|
|
||||||
particular circumstance, the balance of the section is intended to apply,
|
|
||||||
and the section as a whole is intended to apply in other circumstances.
|
|
||||||
|
|
||||||
It is not the purpose of this section to induce you to infringe any
|
|
||||||
patents or other property right claims or to contest validity of any
|
|
||||||
such claims; this section has the sole purpose of protecting the
|
|
||||||
integrity of the free software distribution system which is
|
|
||||||
implemented by public license practices. Many people have made
|
|
||||||
generous contributions to the wide range of software distributed
|
|
||||||
through that system in reliance on consistent application of that
|
|
||||||
system; it is up to the author/donor to decide if he or she is willing
|
|
||||||
to distribute software through any other system and a licensee cannot
|
|
||||||
impose that choice.
|
|
||||||
|
|
||||||
This section is intended to make thoroughly clear what is believed to
|
|
||||||
be a consequence of the rest of this License.
|
|
||||||
|
|
||||||
12. If the distribution and/or use of the Library is restricted in
|
|
||||||
certain countries either by patents or by copyrighted interfaces, the
|
|
||||||
original copyright holder who places the Library under this License may add
|
|
||||||
an explicit geographical distribution limitation excluding those countries,
|
|
||||||
so that distribution is permitted only in or among countries not thus
|
|
||||||
excluded. In such case, this License incorporates the limitation as if
|
|
||||||
written in the body of this License.
|
|
||||||
|
|
||||||
13. The Free Software Foundation may publish revised and/or new
|
|
||||||
versions of the Lesser General Public License from time to time.
|
|
||||||
Such new versions will be similar in spirit to the present version,
|
|
||||||
but may differ in detail to address new problems or concerns.
|
|
||||||
|
|
||||||
Each version is given a distinguishing version number. If the Library
|
|
||||||
specifies a version number of this License which applies to it and
|
|
||||||
"any later version", you have the option of following the terms and
|
|
||||||
conditions either of that version or of any later version published by
|
|
||||||
the Free Software Foundation. If the Library does not specify a
|
|
||||||
license version number, you may choose any version ever published by
|
|
||||||
the Free Software Foundation.
|
|
||||||
|
|
||||||
14. If you wish to incorporate parts of the Library into other free
|
|
||||||
programs whose distribution conditions are incompatible with these,
|
|
||||||
write to the author to ask for permission. For software which is
|
|
||||||
copyrighted by the Free Software Foundation, write to the Free
|
|
||||||
Software Foundation; we sometimes make exceptions for this. Our
|
|
||||||
decision will be guided by the two goals of preserving the free status
|
|
||||||
of all derivatives of our free software and of promoting the sharing
|
|
||||||
and reuse of software generally.
|
|
||||||
|
|
||||||
**NO** **WARRANTY**
|
|
||||||
|
|
||||||
15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
|
|
||||||
WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
|
|
||||||
EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
|
|
||||||
OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
|
|
||||||
KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
|
|
||||||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
|
||||||
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
|
|
||||||
LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
|
|
||||||
THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
|
||||||
|
|
||||||
16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
|
|
||||||
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
|
|
||||||
AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
|
|
||||||
FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
|
|
||||||
CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
|
|
||||||
LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
|
|
||||||
RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
|
|
||||||
FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
|
|
||||||
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
|
|
||||||
DAMAGES.
|
|
||||||
|
|
||||||
### END OF TERMS AND CONDITIONS
|
|
||||||
|
|
||||||
### How to Apply These Terms to Your New Libraries
|
|
||||||
|
|
||||||
If you develop a new library, and you want it to be of the greatest
|
|
||||||
possible use to the public, we recommend making it free software that
|
|
||||||
everyone can redistribute and change. You can do so by permitting
|
|
||||||
redistribution under these terms (or, alternatively, under the terms of the
|
|
||||||
ordinary General Public License).
|
|
||||||
|
|
||||||
To apply these terms, attach the following notices to the library. It is
|
|
||||||
safest to attach them to the start of each source file to most effectively
|
|
||||||
convey the exclusion of warranty; and each file should have at least the
|
|
||||||
"copyright" line and a pointer to where the full notice is found.
|
|
||||||
|
|
||||||
<one line to give the library's name and a brief idea of what it does.>
|
|
||||||
Copyright (C) <year> <name of author>
|
|
||||||
|
|
||||||
This library is free software; you can redistribute it and/or
|
|
||||||
modify it under the terms of the GNU Lesser General Public
|
|
||||||
License as published by the Free Software Foundation; either
|
|
||||||
version 2.1 of the License, or (at your option) any later version.
|
|
||||||
|
|
||||||
This library is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
||||||
Lesser General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU Lesser General Public
|
|
||||||
License along with this library; if not, write to the Free Software
|
|
||||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|
||||||
|
|
||||||
Also add information on how to contact you by electronic and paper mail.
|
|
||||||
|
|
||||||
You should also get your employer (if you work as a programmer) or your
|
|
||||||
school, if any, to sign a "copyright disclaimer" for the library, if
|
|
||||||
necessary. Here is a sample; alter the names:
|
|
||||||
|
|
||||||
Yoyodyne, Inc., hereby disclaims all copyright interest in the
|
|
||||||
library `Frob' (a library for tweaking knobs) written by James Random Hacker.
|
|
||||||
|
|
||||||
<signature of Ty Coon>, 1 April 1990
|
|
||||||
Ty Coon, President of Vice
|
|
||||||
|
|
||||||
That's all there is to it!
|
|
||||||
|
|
||||||
@section occt_lgpl_exception OPEN CASCADE EXCEPTION
|
|
||||||
|
|
||||||
### Open CASCADE Exception (version 1.0) to GNU LGPL version 2.1.
|
|
||||||
|
|
||||||
The object code (i.e. not a source) form of a "work that uses the Library"
|
|
||||||
can incorporate material from a header file that is part of the Library.
|
|
||||||
As a special exception to the GNU Lesser General Public License version 2.1,
|
|
||||||
you may distribute such object code incorporating material from header files
|
|
||||||
provided with the Open CASCADE Technology libraries (including code of CDL
|
|
||||||
generic classes) under terms of your choice, provided that you give
|
|
||||||
prominent notice in supporting documentation to this code that it makes use
|
|
||||||
of or is based on facilities provided by the Open CASCADE Technology software.
|
|
Before Width: | Height: | Size: 157 KiB After Width: | Height: | Size: 42 KiB |
Before Width: | Height: | Size: 48 KiB After Width: | Height: | Size: 60 KiB |
@@ -10,32 +10,40 @@ The steps on Windows and Ubuntu are similar. There is the only one difference: m
|
|||||||
on Windows and native GNU make on Ubuntu.
|
on Windows and native GNU make on Ubuntu.
|
||||||
|
|
||||||
Required tools (download and install if it is required):
|
Required tools (download and install if it is required):
|
||||||
- CMake v3.0+ http://www.cmake.org/cmake/resources/software.html
|
- CMake v3.7+ http://www.cmake.org/cmake/resources/software.html
|
||||||
- Cross-compilation toolchain for CMake https://github.com/taka-no-me/android-cmake
|
|
||||||
- Android NDK rev.10+ https://developer.android.com/tools/sdk/ndk/index.html
|
- Android NDK rev.10+ https://developer.android.com/tools/sdk/ndk/index.html
|
||||||
- GNU Make: MinGW v4.82+ for Windows (http://sourceforge.net/projects/mingw/files/), GNU Make 4.0 for Ubuntu.
|
- GNU Make: MinGW v4.82+ for Windows (http://sourceforge.net/projects/mingw/files/), GNU Make 4.0 for Ubuntu.
|
||||||
|
|
||||||
## Generation of makefiles
|
## Prerequisites
|
||||||
|
|
||||||
|
In toolchain file <i>$CASROOT/adm/templates/android.toolchain.config.cmake</i>:
|
||||||
|
|
||||||
|
- Set CMAKE_ANDROID_NDK variable equal to your Android NDK path.
|
||||||
|
- Set CMAKE_ANDROID_STL_TYPE variable to specify which C++ standard library to use.
|
||||||
|
|
||||||
|
The default value of CMAKE_ANDROID_STL_TYPE is <i>gnustl_shared</i> (GNU libstdc++ Shared)
|
||||||
|
|
||||||
|
@figure{/dev_guides/building/android/images/android_image001.png}
|
||||||
|
|
||||||
|
## Generation of makefiles using CMake GUI tool
|
||||||
Run GUI tool provided by CMake: cmake-gui
|
Run GUI tool provided by CMake: cmake-gui
|
||||||
|
|
||||||
### Tools configuration
|
### Tools configuration
|
||||||
- Specify the root folder of OCCT (<i>$CASROOT</i>, which contains *CMakelists.txt* file) by clicking **Browse Source**.
|
- Specify the root folder of OCCT (<i>$CASROOT</i>, which contains *CMakelists.txt* file) by clicking **Browse Source**.
|
||||||
- Specify the location (build folder) for Cmake generated project files by clicking **Browse Build**.
|
- Specify the location (build folder) for Cmake generated project files by clicking **Browse Build**.
|
||||||
|
|
||||||
@figure{/dev_guides/building/android/images/android_image001.png}
|
@figure{/dev_guides/building/android/images/android_image002.png}
|
||||||
|
|
||||||
Click **Configure** button. It opens the window with a drop-down list of generators supported by CMake project.
|
Click **Configure** button. It opens the window with a drop-down list of generators supported by CMake project.
|
||||||
|
|
||||||
Select "MinGW MakeFiles" item from the list
|
Select "MinGW Makefiles" item from the list
|
||||||
- Choose "Specify toolchain file for cross-compiling"
|
- Choose "Specify toolchain file for cross-compiling"
|
||||||
- Click "Next"
|
- Click "Next"
|
||||||
@figure{/dev_guides/building/android/images/android_image002.png}
|
|
||||||
|
|
||||||
- Specify a toolchain file at the next dialog by android.toolchain.cmake . It is contained by cross-compilation toolchain for CMake
|
|
||||||
- Click "Finish"
|
|
||||||
@figure{/dev_guides/building/android/images/android_image003.png}
|
@figure{/dev_guides/building/android/images/android_image003.png}
|
||||||
|
|
||||||
If ANDROID_NDK environment variable is not defined in current OS, add cache entry ANDROID_NDK (entry type is PATH) -- path to the NDK folder ("Add Entry" button)
|
- Specify a toolchain file at the next dialog by <i>android.toolchain.config.cmake</i> . It is contained by cross-compilation toolchain for CMake
|
||||||
|
- Click "Finish"
|
||||||
@figure{/dev_guides/building/android/images/android_image004.png}
|
@figure{/dev_guides/building/android/images/android_image004.png}
|
||||||
|
|
||||||
If on Windows the message is appeared: "CMake Error: CMake was unable to find a build program corresponding to "MinGW Makefiles"
|
If on Windows the message is appeared: "CMake Error: CMake was unable to find a build program corresponding to "MinGW Makefiles"
|
||||||
@@ -46,18 +54,19 @@ specify **CMAKE_MAKE_PROGRAM** to mingw32-make executable.
|
|||||||
### OCCT Configuration
|
### OCCT Configuration
|
||||||
|
|
||||||
How to configure OCCT, see "OCCT Configuration" section of @ref occt_dev_guides__building_cmake "Building with CMake"
|
How to configure OCCT, see "OCCT Configuration" section of @ref occt_dev_guides__building_cmake "Building with CMake"
|
||||||
taking into account the specific configuration variables for android:
|
|
||||||
- ANDROID_ABI = armeabi-v7a
|
|
||||||
- ANDROID_NATIVE_API_LEVEL = 15
|
|
||||||
- ANDROID_NDK_LAYOUT is equal to CMAKE_BUILD_TYPE variable
|
|
||||||
- **BUILD_MODULE_Draw = OFF**
|
|
||||||
|
|
||||||
@figure{/dev_guides/building/android/images/android_image006.png}
|
|
||||||
|
|
||||||
### Generation of makefiles
|
### Generation of makefiles
|
||||||
|
|
||||||
Click **Generate** button and wait until the generation process is finished.
|
Click **Generate** button and wait until the generation process is finished.
|
||||||
Then makefiles will appear in the build folder (e.g. <i> D:/tmp/occt-android </i>).
|
Then makefiles will appear in the build folder (e.g. <i> D:/occt/build-android </i>).
|
||||||
|
|
||||||
|
## Generation of makefiles using CMake from the command line
|
||||||
|
|
||||||
|
Alternatively one may specify the values without a toolchain file:
|
||||||
|
|
||||||
|
> cmake -G "MinGW Makefiles" -DCMAKE_SYSTEM_NAME=Android -DCMAKE_ANDROID_NDK=D:/DevTools/android-ndk-r13b -DCMAKE_ANDROID_STL_TYPE=gnustl_shared -DCMAKE_SYSTEM_VERSION=15 -DCMAKE_ANDROID_ARCH_ABI=armeabi-v7a -DCMAKE_MAKE_PROGRAM=D:/DevTools/MinGW/bin/mingw32-make.exe -D3RDPARTY_DIR=D:/occt-3rdparty D:/occt
|
||||||
|
|
||||||
|
@figure{/dev_guides/building/android/images/android_image006.png}
|
||||||
|
|
||||||
## Building makefiles of OCCT
|
## Building makefiles of OCCT
|
||||||
|
|
||||||
|
Before Width: | Height: | Size: 57 KiB After Width: | Height: | Size: 17 KiB |
Before Width: | Height: | Size: 32 KiB After Width: | Height: | Size: 14 KiB |
Before Width: | Height: | Size: 46 KiB After Width: | Height: | Size: 7.0 KiB |
Before Width: | Height: | Size: 25 KiB After Width: | Height: | Size: 4.1 KiB |
Before Width: | Height: | Size: 66 KiB After Width: | Height: | Size: 31 KiB |
Before Width: | Height: | Size: 80 KiB After Width: | Height: | Size: 98 KiB |
@@ -5,27 +5,27 @@ Building with CMake {#occt_dev_guides__building_cmake}
|
|||||||
|
|
||||||
@section build_cmake_intro General
|
@section build_cmake_intro General
|
||||||
|
|
||||||
This article describes **CMake**-based build process which is now suggested as a standard way to produce the binaries of Open CASCADE Technology from sources. *OCCT requires CMake version 2.8.12 or later*.
|
This article describes the **CMake**-based build process, which is now suggested as a standard way to produce the binaries of Open CASCADE Technology from sources. *OCCT requires CMake version 2.8.12 or later*.
|
||||||
|
|
||||||
@note Comparing to the previous (6.x) releases of Open CASCADE Technology, OCCT 7.0 comes with a complete set of CMake scripts and projects, so that there is no need to use WOK anymore. Moreover, CMake gives you a powerful configuration tool which allows to control many aspects of OCCT deployment. At the same time this tool is quite intuitive which is a significant advantage over the legacy WOK utilities.
|
@note Compared to the previous (6.x) releases of Open CASCADE Technology, OCCT 7.x has a complete set of CMake scripts and projects, so that there is no need to use WOK anymore. Moreover, CMake gives you a powerful configuration tool, which allows to control many aspects of OCCT deployment. At the same time this tool is quite intuitive, which is a significant advantage over the legacy WOK utilities.
|
||||||
|
|
||||||
Here we describe the build procedure on example of Windows platform with Visual Studio 2010.
|
Here we describe the build procedure on the example of Windows platform with Visual Studio 2010.
|
||||||
However, CMake is cross-platform and can be used to build OCCT on Linux and OS X in essentially the same way.
|
However, CMake is cross-platform and can be used to build OCCT on Linux and OS X in essentially the same way.
|
||||||
|
|
||||||
@note Before you start, make sure to have installed all the 3-rd party products that you are going to use with OCCT; see @ref occt_dev_guides__building.
|
@note Before you start, make sure to have installed all 3-rd party products that you are going to use with OCCT; see @ref occt_dev_guides__building.
|
||||||
|
|
||||||
@section build_cmake_start Start CMake
|
@section build_cmake_start Start CMake
|
||||||
|
|
||||||
CMake is a tool that generates the actual project files for the selected target build system (e.g. Unix makefiles) or IDE (e.g. Visual Studio 2010).
|
CMake is a tool that generates the actual project files for the selected target build system (e.g. Unix makefiles) or IDE (e.g. Visual Studio 2010).
|
||||||
|
|
||||||
For unexpericnced users we recommend to start with *cmake-gui* -- cross-platform GUI tool provided by CMake on Windows, Mac and Linux.
|
For unexperienced users we recommend to start with *cmake-gui* -- a cross-platform GUI tool provided by CMake on Windows, Mac and Linux.
|
||||||
A command-line alternative, *ccmake* also can be used.
|
A command-line alternative, *ccmake* can also be used.
|
||||||
|
|
||||||
CMake deals with three directories: source, build or binary and install.
|
CMake deals with three directories: source, build or binary and installation.
|
||||||
|
|
||||||
* The source directory is where the sources of OCCT are located in your filesystem
|
* The source directory is where the sources of OCCT are located in your file system;
|
||||||
* The build or binary directory is where all the files created during CMake configuration and generation process will be located. The mentioned process will be described below.
|
* The build or binary directory is where all files created during CMake configuration and generation process will be located. The mentioned process will be described below.
|
||||||
* The installation directory is where binaries will be installed after build the *INSTALL* project that is created by CMake generation process, along with header files and resources required for OCCT use in applications.
|
* The installation directory is where binaries will be installed after building the *INSTALL* project that is created by CMake generation process, along with header files and resources required for OCCT use in applications.
|
||||||
|
|
||||||
The good practice is not to use the source directory as a build one.
|
The good practice is not to use the source directory as a build one.
|
||||||
Different configurations should be built in different build directories to avoid conflicts.
|
Different configurations should be built in different build directories to avoid conflicts.
|
||||||
@@ -35,7 +35,7 @@ It is however possible to choose one installation directory for several configur
|
|||||||
d:/tmp/occt-build-vc10-x64 -- the build directory with the generated
|
d:/tmp/occt-build-vc10-x64 -- the build directory with the generated
|
||||||
solution and other intermediate files created during a CMake tool working
|
solution and other intermediate files created during a CMake tool working
|
||||||
d:/occt-install -- the installation directory that is
|
d:/occt-install -- the installation directory that is
|
||||||
able to contain several OCCT configuratoion
|
able to contain several OCCT configurations
|
||||||
|
|
||||||
@section build_cmake_conf Configuration process
|
@section build_cmake_conf Configuration process
|
||||||
|
|
||||||
@@ -48,9 +48,9 @@ If the command-line tool is used, run the tool from the build directory with a s
|
|||||||
|
|
||||||
Press *c* to configure.
|
Press *c* to configure.
|
||||||
|
|
||||||
All required actions in the configuration process will be described with using the GUI tool below.
|
All actions required in the configuration process with the GUI tool will be described below.
|
||||||
|
|
||||||
If the gui-tool is used, run the tool without additional arguments and after that specify the source directory by clicking **Browse Source** and the build (binary) one by clicking **Browse Build**.
|
If the GUI tool is used, run this tool without additional arguments and after that specify the source directory by clicking **Browse Source** and the build (binary) one by clicking **Browse Build**.
|
||||||
|
|
||||||
@figure{/dev_guides/building/cmake/images/cmake_image001.png}
|
@figure{/dev_guides/building/cmake/images/cmake_image001.png}
|
||||||
|
|
||||||
@@ -60,25 +60,31 @@ Once the source and build directories are selected, "Configure" button should be
|
|||||||
|
|
||||||
@figure{/dev_guides/building/cmake/images/cmake_image002.png}
|
@figure{/dev_guides/building/cmake/images/cmake_image002.png}
|
||||||
|
|
||||||
Once "Finish" button is pressed, the first pass the configuration process is executed. At the end of the process, CMake outputs the list of environment variables which have to be properly specified for successful configuration.
|
To build OCCT for **Universal Windows Platform (UWP)** specify the path to toolchain file for cross-compiling <i>d:/occt/adm/templates/uwp.toolchain.config.cmake</i>.
|
||||||
|
|
||||||
|
Alternatively, if you are using CMake from the command line add options -DCMAKE_SYSTEM_NAME=WindowsStore -DCMAKE_SYSTEM_VERSION=10.0 .
|
||||||
|
|
||||||
|
**Note**: Universal Windows Platform (UWP) is supported only on "Visual Studio 14 2015". File <i>d:/occt/samples/xaml/ReadMe.md</i> describes the building procedure of XAML (UWP) sample.
|
||||||
|
|
||||||
|
Once "Finish" button is pressed, the first pass of the configuration process is executed. At the end of the process, CMake outputs the list of environment variables, which have to be properly specified for successful configuration.
|
||||||
|
|
||||||
@figure{/dev_guides/building/cmake/images/cmake_image003.png}
|
@figure{/dev_guides/building/cmake/images/cmake_image003.png}
|
||||||
|
|
||||||
The error message provides an information about these variables. This message will appear after each pass of the process until all required variables are specified correctly.
|
The error message provides some information about these variables. This message will appear after each pass of the process until all required variables are specified correctly.
|
||||||
|
|
||||||
The change of the state of some variables can lead to a new variable appearance. The new variables appeared after the pass of the configuration process is notified with red color by CMake GUI tool.
|
The change of the state of some variables can lead to the appearance of new variables. The new variables appeared after the pass of the configuration process are highlighted with red color by CMake GUI tool.
|
||||||
|
|
||||||
Note: There is "grouped" option which groups variables with a common prefix.
|
Note: There is "grouped" option, which groups variables with a common prefix.
|
||||||
|
|
||||||
The following table enumerates the full list of environment variables used at configuration stage:
|
The following table gives the full list of environment variables used at the configuration stage:
|
||||||
|
|
||||||
| Variable | Type | Purpose |
|
| Variable | Type | Purpose |
|
||||||
|----------|------|---------|
|
|----------|------|---------|
|
||||||
| CMAKE_BUILD_TYPE | String | Specifies the build type on single-configuration generators (sush as make). Possible values are Debug, Release and RelWithDebInfo |
|
| CMAKE_BUILD_TYPE | String | Specifies the build type on single-configuration generators (such as make). Possible values are Debug, Release and RelWithDebInfo |
|
||||||
| USE_FREEIMAGE | Boolean flag | Indicates whether Freeimage product should be used in OCCT visualization module for support of popular graphics image formats (PNG, BMP etc) |
|
| USE_FREEIMAGE | Boolean flag | Indicates whether FreeImage product should be used in OCCT visualization module for support of popular graphics image formats (PNG, BMP, etc.) |
|
||||||
| USE_GL2PS | Boolean flag | Indicates whether GL2PS product should be used in OCCT visualization module for support of vector image formats (PS, EPS etc) |
|
| USE_GL2PS | Boolean flag | Indicates whether GL2PS product should be used in OCCT visualization module for support of vector image formats (PS, EPS, etc.) |
|
||||||
| USE_TBB | Boolean flag | Indicates whether TBB 3rd party is used or not. TBB stands for Threading Building Blocks, the technology of Intel Corp, which comes with different mechanisms and patterns for injecting parallelism into your application. OCCT remains parallel even without TBB product |
|
| USE_TBB | Boolean flag | Indicates whether TBB 3rd party is used or not. TBB stands for Threading Building Blocks, the technology of Intel Corp, which comes with different mechanisms and patterns for injecting parallelism into your application. OCCT remains parallel even without TBB product |
|
||||||
| USE_VTK | Boolean flag | Indicates whether VTK 3rd party is used or not. VTK stands for Visualization ToolKit, the technology of Kitware Inc intended for general-purpose scientific visualization. OCCT comes with a bridge between CAD data representation and VTK by means of its dedicated VIS component (VTK Integration Services). You may skip this 3rd party unless you are planning to use VTK visualization for OCCT geometry. The official documentation @ref occt_user_guides__vis for the details on VIS |
|
| USE_VTK | Boolean flag | Indicates whether VTK 3rd party is used or not. VTK stands for Visualization ToolKit, the technology of Kitware Inc intended for general-purpose scientific visualization. OCCT comes with a bridge between CAD data representation and VTK by means of its dedicated VIS component (VTK Integration Services). You may skip this 3rd party unless you are planning to use VTK visualization for OCCT geometry. See the official documentation @ref occt_user_guides__vis for the details on VIS |
|
||||||
| 3RDPARTY_DIR | Path | Defines the root directory where all required 3rd party products will be searched. Once you define this path it is very convenient to click "Configure" button in order to let CMake automatically detect all necessary products|
|
| 3RDPARTY_DIR | Path | Defines the root directory where all required 3rd party products will be searched. Once you define this path it is very convenient to click "Configure" button in order to let CMake automatically detect all necessary products|
|
||||||
| 3RDPARTY_FREETYPE_* | Path | Path to Freetype binaries |
|
| 3RDPARTY_FREETYPE_* | Path | Path to Freetype binaries |
|
||||||
| 3RDPARTY_TCL_* 3RDPARTY_TK_* | Path | Path to Tcl/Tk binaries |
|
| 3RDPARTY_TCL_* 3RDPARTY_TK_* | Path | Path to Tcl/Tk binaries |
|
||||||
@@ -87,20 +93,22 @@ The following table enumerates the full list of environment variables used at co
|
|||||||
| 3RDPARTY_TBB* | Path | Path to TBB binaries |
|
| 3RDPARTY_TBB* | Path | Path to TBB binaries |
|
||||||
| 3RDPARTY_VTK_* | Path | Path to VTK binaries |
|
| 3RDPARTY_VTK_* | Path | Path to VTK binaries |
|
||||||
| BUILD_MODULE_<MODULE>| Boolean flag | Indicates whether the corresponding OCCT module should be built or not. It should be noted that some toolkits of a module can be built even if this module is not checked (this happens if some other modules depend on these toolkits). The main modules and their descriptions can be found in @ref user_guides |
|
| BUILD_MODULE_<MODULE>| Boolean flag | Indicates whether the corresponding OCCT module should be built or not. It should be noted that some toolkits of a module can be built even if this module is not checked (this happens if some other modules depend on these toolkits). The main modules and their descriptions can be found in @ref user_guides |
|
||||||
| BUILD_LIBRARY_TYPE | String | Specifies the type of library to be created. "Shared" libraries are linked dynamically and loaded at runtime. "Static" libraries are archives of object files for use when linking other targets |
|
| BUILD_LIBRARY_TYPE | String | Specifies the type of library to be created. "Shared" libraries are linked dynamically and loaded at runtime. "Static" libraries are archives of object files used when linking other targets |
|
||||||
| BUILD_ADDITIONAL_TOOLKITS | String | Semicolon-separated individual toolkits to include into build process. If you want to build some particular libraries (toolkits) only, then you may uncheck all modules in the corresponding *BUILD_MODUE_\<MODULE\>* options and provide the list of necessary libraries here. Of course, all dependencies will be resolved automatically |
|
| BUILD_ADDITIONAL_TOOLKITS | String | Semicolon-separated individual toolkits to include into build process. If you want to build some particular libraries (toolkits) only, then you may uncheck all modules in the corresponding *BUILD_MODUE_\<MODULE\>* options and provide the list of necessary libraries here. Of course, all dependencies will be resolved automatically |
|
||||||
| BUILD_YACCLEX | Boolean flag | Enables Flex/Bison lexical analyzers. OCCT source files relating to STEP reader and ExprIntrp functionality are generated automatically with Flex/Bison. Checking this options leads to automatic search of Flex/Bison binaries and regeneration of the mentioned files |
|
| BUILD_YACCLEX | Boolean flag | Enables Flex/Bison lexical analyzers. OCCT source files relating to STEP reader and ExprIntrp functionality are generated automatically with Flex/Bison. Checking this option leads to automatic search of Flex/Bison binaries and regeneration of the mentioned files |
|
||||||
| BUILD_MODULE_MfcSamples | Boolean flag | Indicates whether MFC samples should be built together with OCCT. This option is only relevant to Windows platforms |
|
| BUILD_MODULE_MfcSamples | Boolean flag | Indicates whether MFC samples should be built together with OCCT. This option is only relevant to Windows platforms |
|
||||||
| BUILD_DOC_Overview | Boolean flag | Indicates whether OCCT overview documentation project should be created together with OCCT. It is not built together with OCCT. Checking this options leads to automatic search of Doxygen binaries. Building of it will be call Doxygen command to generate the documentation in HTML format |
|
| BUILD_DOC_Overview | Boolean flag | Indicates whether OCCT overview documentation project should be created together with OCCT. It is not built together with OCCT. Checking this option leads to automatic search of Doxygen binaries. Its building calls Doxygen command to generate the documentation in HTML format |
|
||||||
| BUILD_PATCH | Path | Points to the directory recognized as a "patch" for OCCT. If specified, the files from this directory take precedence over the corresponding native OCCT sources. This way you are able to introduce patches to Open CASCADE Technology not affecting the original source distribution |
|
| BUILD_PATCH | Path | Points to the directory recognized as a "patch" for OCCT. If specified, the files from this directory take precedence over the corresponding native OCCT sources. This way you are able to introduce patches to Open CASCADE Technology not affecting the original source distribution |
|
||||||
| BUILD_WITH_DEBUG | Boolean flag | Enables extended messages of many OCCT algorithms, usually printed to cout. These include messages on internal errors and special cases encountered, timing etc |
|
| BUILD_WITH_DEBUG | Boolean flag | Enables extended messages of many OCCT algorithms, usually printed to cout. These include messages on internal errors and special cases encountered, timing, etc. |
|
||||||
|
| BUILD_ENABLE_FPE_SIGNAL_HANDLER | Boolean flag | Enable/Disable the floating point exceptions (FPE) during DRAW execution only. Corresponding environment variable (CSF_FPE) can be changed manually in custom.bat/sh scripts without regeneration by CMake. |
|
||||||
| CMAKE_CONFIGURATION_TYPES | String | Semicolon-separated CMake configurations |
|
| CMAKE_CONFIGURATION_TYPES | String | Semicolon-separated CMake configurations |
|
||||||
| INSTALL_DIR | Path | Points to the installation directory. INSTALL_DIR is synonym of CMAKE_INSTALL_PREFIX . User can specify both INSTALL_DIR or CMAKE_INSTALL_PREFIX |
|
| INSTALL_DIR | Path | Points to the installation directory. *INSTALL_DIR* is a synonym of *CMAKE_INSTALL_PREFIX*. The user can specify both *INSTALL_DIR* or *CMAKE_INSTALL_PREFIX* |
|
||||||
| INSTALL_DIR_BIN | Path | Relative path to the binaries installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_BIN}) |
|
| INSTALL_DIR_BIN | Path | Relative path to the binaries installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_BIN}) |
|
||||||
| INSTALL_DIR_SCRIPT | Path | Relative path to the scripts installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_SCRIPT}) |
|
| INSTALL_DIR_SCRIPT | Path | Relative path to the scripts installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_SCRIPT}) |
|
||||||
| INSTALL_DIR_LIB | Path | Relative path to the libraries installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_LIB}) |
|
| INSTALL_DIR_LIB | Path | Relative path to the libraries installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_LIB}) |
|
||||||
| INSTALL_DIR_INCLUDE | Path | Relative path to the includes installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_INCLUDE}) |
|
| INSTALL_DIR_INCLUDE | Path | Relative path to the includes installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_INCLUDE}) |
|
||||||
| INSTALL_DIR_RESOURCE | Path | Relative path to the resources installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_RESOURCE}) |
|
| INSTALL_DIR_RESOURCE | Path | Relative path to the resources installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_RESOURCE}) |
|
||||||
|
| INSTALL_DIR_LAYOUT | String | Defines the structure of OCCT files (binaries, resources, headers, etc.) for the install directory. Two variants are predefined: for Windows (standard OCCT layout) and for Unix operating systems (standard Linux layout). If needed, the layout can be customized with INSTALL_DIR_* variables |
|
||||||
| INSTALL_DIR_DATA | Path | Relative path to the data files installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_DATA}) |
|
| INSTALL_DIR_DATA | Path | Relative path to the data files installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_DATA}) |
|
||||||
| INSTALL_DIR_SAMPLES | Path | Relative path to the samples installation directory. Note that only "samples/tcl" folder will be installed. (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_SAMPLES}) |
|
| INSTALL_DIR_SAMPLES | Path | Relative path to the samples installation directory. Note that only "samples/tcl" folder will be installed. (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_SAMPLES}) |
|
||||||
| INSTALL_DIR_TESTS | Path | Relative path to the tests installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_TESTS}) |
|
| INSTALL_DIR_TESTS | Path | Relative path to the tests installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_TESTS}) |
|
||||||
@@ -114,7 +122,7 @@ The following table enumerates the full list of environment variables used at co
|
|||||||
| INSTALL_TEST_CASES | Boolean flag | Indicates whether non-regression OCCT test scripts should be installed into the installation directory |
|
| INSTALL_TEST_CASES | Boolean flag | Indicates whether non-regression OCCT test scripts should be installed into the installation directory |
|
||||||
| INSTALL_DOC_Overview | Boolean flag | Indicates whether OCCT overview documentation should be installed into the installation directory |
|
| INSTALL_DOC_Overview | Boolean flag | Indicates whether OCCT overview documentation should be installed into the installation directory |
|
||||||
|
|
||||||
**Note:** In those CMake options defining paths only the forward slashes ("/") are acceptable.
|
**Note:** Only the forward slashes ("/") are acceptable in the CMake options defining paths.
|
||||||
|
|
||||||
@section build_cmake_3rdparty 3rd party search mechanism
|
@section build_cmake_3rdparty 3rd party search mechanism
|
||||||
|
|
||||||
@@ -122,14 +130,14 @@ If *3RDPARTY_DIR* directory is defined, then required 3rd party binaries are sou
|
|||||||
|
|
||||||
The procedure expects to find binary and header files of each 3rd party product in its own sub-directory: *bin*, *lib* and *include*.
|
The procedure expects to find binary and header files of each 3rd party product in its own sub-directory: *bin*, *lib* and *include*.
|
||||||
|
|
||||||
The result of the search (achived on the next pass of the configuration process) are recorded in the corresponding variables:
|
The results of the search (achieved on the next pass of the configuration process) are recorded in the corresponding variables:
|
||||||
|
|
||||||
* *3RDPARTY_\<PRODUCT\>_DIR* -- path to the 3rdparty directory (with directory name) (e.g. <i>D:/3rdparty/tcltk-86-32</i>)
|
* *3RDPARTY_\<PRODUCT\>_DIR* -- path to the 3rdparty directory (with directory name) (e.g. <i>D:/3rdparty/tcltk-86-32</i>)
|
||||||
* *3RDPARTY_\<PRODUCT\>_LIBRARY_DIR* -- path to the directory containing a library (e.g. <i>D:/3rdparty/tcltk-86-32/lib</i>).
|
* *3RDPARTY_\<PRODUCT\>_LIBRARY_DIR* -- path to the directory containing a library (e.g. <i>D:/3rdparty/tcltk-86-32/lib</i>).
|
||||||
* *3RDPARTY_\<PRODUCT\>_INCLUDE_DIR* -- path to the directory containing a header file (e.g., <i>D:/3rdparty/tcltk-86-32/include</i>)
|
* *3RDPARTY_\<PRODUCT\>_INCLUDE_DIR* -- path to the directory containing a header file (e.g., <i>D:/3rdparty/tcltk-86-32/include</i>)
|
||||||
* *3RDPARTY_\<PRODUCT\>_DLL_DIR* -- path to the directory containing a shared library (e.g., <i>D:/3rdparty/tcltk-86-32/bin</i>) This variable is only relevant to Windows platforms.
|
* *3RDPARTY_\<PRODUCT\>_DLL_DIR* -- path to the directory containing a shared library (e.g., <i>D:/3rdparty/tcltk-86-32/bin</i>) This variable is only relevant to Windows platforms.
|
||||||
|
|
||||||
Note: each library and include directory should be the children of product directory if the last one is defined.
|
Note: each library and include directory should be children of the product directory if the last one is defined.
|
||||||
|
|
||||||
The search process is as follows:
|
The search process is as follows:
|
||||||
|
|
||||||
@@ -140,7 +148,7 @@ The search process is as follows:
|
|||||||
2. *3RDPARTY_\<PRODUCT\>_LIBRARY_DIR*
|
2. *3RDPARTY_\<PRODUCT\>_LIBRARY_DIR*
|
||||||
3. *3RDPARTY_\<PRODUCT\>_DLL_DIR*
|
3. *3RDPARTY_\<PRODUCT\>_DLL_DIR*
|
||||||
|
|
||||||
If a variable of any level is not defined (empty or <i> \<variable name\>-NOTFOUND </i>) and the upper level variable is defined, the content of the non-defined variable will be sought at the next configuration step. If search process at level 3 does not find the required files, it seeks in default places.
|
If a variable of any level is not defined (empty or <i> \<variable name\>-NOTFOUND </i>) and the upper level variable is defined, the content of the non-defined variable will be sought at the next configuration step. If the search process at level 3 does not find the required files, it seeks in default places.
|
||||||
|
|
||||||
If a search result (include path, or library path, or dll path) does not meet your expectations, you can change *3RDPARTY_\<PRODUCT\>_*_DIR variable*, clear (if they are not empty) *3RDPARTY_\<PRODUCT\>_DLL_DIR, 3RDPARTY_\<PRODUCT\>_INCLUDE_DIR* and 3RDPARTY_\<PRODUCT\>_LIBRARY_DIR variables (or clear one of them) and run the configuration process again.
|
If a search result (include path, or library path, or dll path) does not meet your expectations, you can change *3RDPARTY_\<PRODUCT\>_*_DIR variable*, clear (if they are not empty) *3RDPARTY_\<PRODUCT\>_DLL_DIR, 3RDPARTY_\<PRODUCT\>_INCLUDE_DIR* and 3RDPARTY_\<PRODUCT\>_LIBRARY_DIR variables (or clear one of them) and run the configuration process again.
|
||||||
|
|
||||||
@@ -155,13 +163,13 @@ can be changed to
|
|||||||
|
|
||||||
d:/3rdparty/freetype-2.5.3
|
d:/3rdparty/freetype-2.5.3
|
||||||
|
|
||||||
During the configuration process the related variables (*3RDPARTY_FREETYPE_DLL_DIR*, *3RDPARTY_FREETYPE_INCLUDE_DIR* and *3RDPARTY_FREETYPE_LIBRARY_DIR*) will be filled with new found values
|
During the configuration process the related variables (*3RDPARTY_FREETYPE_DLL_DIR*, *3RDPARTY_FREETYPE_INCLUDE_DIR* and *3RDPARTY_FREETYPE_LIBRARY_DIR*) will be filled with new found values.
|
||||||
|
|
||||||
**Note**: The names of searched libraries and header files are hard-coded. If there is the need to change their names, change appropriate cmake variables (edit CMakeCache.txt file or edit in cmake-gui in advance mode) without reconfiguration: *3RDPARTY_\<PRODUCT\>_INCLUDE* for include, *3RDPARTY_\<PRODUCT\>_LIB* for library and *3RDPARTY_\<PRODUCT\>_DLL* for shared library.
|
**Note**: The names of searched libraries and header files are hard-coded. If there is the need to change their names, change appropriate cmake variables (edit CMakeCache.txt file or edit in cmake-gui in advance mode) without reconfiguration: *3RDPARTY_\<PRODUCT\>_INCLUDE* for include, *3RDPARTY_\<PRODUCT\>_LIB* for library and *3RDPARTY_\<PRODUCT\>_DLL* for shared library.
|
||||||
|
|
||||||
@section build_cmake_gen Projects generation
|
@section build_cmake_gen Projects generation
|
||||||
|
|
||||||
Once the configuration process is done, "Generate" button is used to prepare project files for the target IDE. In our exercise the Visual Studio solution will be automatically created in the buid directory.
|
Once the configuration process is done, the "Generate" button is used to prepare project files for the target IDE. In our exercise the Visual Studio solution will be automatically created in the buid directory.
|
||||||
|
|
||||||
@section build_cmake_build Building
|
@section build_cmake_build Building
|
||||||
|
|
||||||
@@ -179,11 +187,11 @@ For this, right-click on the *Overview/INSTALL* project and select **Project Onl
|
|||||||
|
|
||||||
@section build_cmake_install Installation
|
@section build_cmake_install Installation
|
||||||
|
|
||||||
Installation is a process of extracting redistributable resources (binaries,include files etc) from the build directory into the installation one. The installation directory will be free of project files, intermediate object files and any other information related to the build routines.
|
Installation is a process of extracting redistributable resources (binaries, include files etc) from the build directory into the installation one. The installation directory will be free of project files, intermediate object files and any other information related to the build routines.
|
||||||
|
|
||||||
Normally you use the installation directory of OCCT to link against your specific application.
|
Normally you use the installation directory of OCCT to link against your specific application.
|
||||||
|
|
||||||
the directory structure is follow:
|
The directory structure is as follows:
|
||||||
|
|
||||||
data -- data files for OCCT (brep, iges, stp)
|
data -- data files for OCCT (brep, iges, stp)
|
||||||
doc -- OCCT overview documentation in HTML format
|
doc -- OCCT overview documentation in HTML format
|
||||||
@@ -202,6 +210,6 @@ follows:
|
|||||||
\bin
|
\bin
|
||||||
\lib
|
\lib
|
||||||
|
|
||||||
If CMake installation flags are enabled for the 3rd party products (e.g. INSTALL_FREETYPE), then the corresponding binaries will be copied to the same bin(d) and lib(d) directories together with the native binaries of OCCT. Such organization of libraries can be especially helpful if your OCCT-based software does not use itself the 3rd parties of Open CASCADE Technology (thus, there is no sense to pack them into dedicated directories)
|
If CMake installation flags are enabled for the 3rd party products (e.g. INSTALL_FREETYPE), then the corresponding binaries will be copied to the same bin(d) and lib(d) directories together with the native binaries of OCCT. Such organization of libraries can be especially helpful if your OCCT-based software does not use itself the 3rd parties of Open CASCADE Technology (thus, there is no sense to pack them into dedicated directories).
|
||||||
|
|
||||||
The installation folder contains the scripts to run *DRAWEXE* (*draw.bat* or *draw.sh*), samples (if its were installed) and overview.html (short-cut for installed OCCT overview documentation).
|
The installation folder contains the scripts to run *DRAWEXE* (*draw.bat* or *draw.sh*), samples (if they were installed) and overview.html (short-cut for installed OCCT overview documentation).
|
||||||
|
@@ -20,7 +20,10 @@ The environment is defined in the file *custom.sh* (on Linux and OS X) or *custo
|
|||||||
|
|
||||||
* Add paths to includes of used third-party libraries in variable *CSF_OPT_INC*.
|
* Add paths to includes of used third-party libraries in variable *CSF_OPT_INC*.
|
||||||
* Add paths to their binary libraries in variable *CSF_OPT_LIB64*.
|
* Add paths to their binary libraries in variable *CSF_OPT_LIB64*.
|
||||||
* Set variable *SHORTCUT_HEADERS* to "true" to have folder *inc* populated by short-cut files pointing to actual headers located in *src*; otherwise, header files will be copied to *inc*.
|
* Set variable *SHORTCUT_HEADERS* to specify a method for population of folder *inc* by header files. Supported methods are:
|
||||||
|
* *Copy* - headers will be copied from *src*;
|
||||||
|
* *ShortCut* - short-cut header files will be created, redirecting to same-named header located in *src*;
|
||||||
|
* "HardLink* - hard links to headers located in *src* will be created.
|
||||||
* For optional third-party libraries, set corresponding environment variable <i>HAVE_<LIBRARY_NAME></i> to either *false*, e.g.:
|
* For optional third-party libraries, set corresponding environment variable <i>HAVE_<LIBRARY_NAME></i> to either *false*, e.g.:
|
||||||
~~~~~
|
~~~~~
|
||||||
export HAVE_GL2PS=false
|
export HAVE_GL2PS=false
|
||||||
|
@@ -30,13 +30,16 @@ If you have Visual Studio projects already available (pre-installed or generated
|
|||||||
* *ARCH* -- architecture (32 or 64), affects only *PATH* variable for execution
|
* *ARCH* -- architecture (32 or 64), affects only *PATH* variable for execution
|
||||||
* <i>HAVE_*</i> -- flags to enable or disable use of optional third-party products
|
* <i>HAVE_*</i> -- flags to enable or disable use of optional third-party products
|
||||||
* <i>CSF_OPT_*</i> -- paths to search for includes and binaries of all used third-party products
|
* <i>CSF_OPT_*</i> -- paths to search for includes and binaries of all used third-party products
|
||||||
* *SHORTCUT_HEADERS* -- if set to "true", folder *inc* will be populated by short-cut files pointing to actual headers located in *src*; otherwise, header files will be copied to *inc*.
|
* *SHORTCUT_HEADERS* -- defines method for population of folder *inc* by header files. Supported methods are:
|
||||||
|
* *Copy* - headers will be copied from *src*;
|
||||||
|
* *ShortCut* - short-cut header files will be created, redirecting to same-named header located in *src*;
|
||||||
|
* "HardLink* - hard links to headers located in *src* will be created.
|
||||||
|
|
||||||
Alternatively, you can launch **genconf**, a GUI tool allowing to configure build options interactively.
|
Alternatively, you can launch **genconf**, a GUI tool allowing to configure build options interactively.
|
||||||
That tool will analyze your environment and propose you to choose available options:
|
That tool will analyze your environment and propose you to choose available options:
|
||||||
|
|
||||||
* Version of Visual Studio to be used (from the list of installed ones, detected by presence of environment variables like *VS100COMNTOOLS*)
|
* Version of Visual Studio to be used (from the list of installed ones, detected by presence of environment variables like *VS100COMNTOOLS*)
|
||||||
* Option to use short-cuts to header files in folder *inc* (enabled by default).
|
* Method to populate folder *inc* (short-cuts by default).
|
||||||
* Location of third-party libraries (usually downloaded from OCCT web site, see above).
|
* Location of third-party libraries (usually downloaded from OCCT web site, see above).
|
||||||
* Path to common directory where third-party libraries are located (optional)
|
* Path to common directory where third-party libraries are located (optional)
|
||||||
* Paths to headers and binaries of the third-party libraries (found automatically basing on previous options; click button "Reset" to update).
|
* Paths to headers and binaries of the third-party libraries (found automatically basing on previous options; click button "Reset" to update).
|
||||||
|
@@ -21,7 +21,10 @@ The environment is defined in the file *custom.sh* which can be edited directly:
|
|||||||
|
|
||||||
* Add paths to includes of used third-party libraries in variable *CSF_OPT_INC* (use colon ":" as path separator).
|
* Add paths to includes of used third-party libraries in variable *CSF_OPT_INC* (use colon ":" as path separator).
|
||||||
* Add paths to their binary libraries in variable *CSF_OPT_LIB64*.
|
* Add paths to their binary libraries in variable *CSF_OPT_LIB64*.
|
||||||
* Set variable *SHORTCUT_HEADERS* to "true" to have folder *inc* populated by short-cut files pointing to actual headers located in *src*; otherwise, header files will be copied to *inc*.
|
* Set variable *SHORTCUT_HEADERS* to specify a method for population of folder *inc* by header files. Supported methods are:
|
||||||
|
* *Copy* - headers will be copied from *src*;
|
||||||
|
* *ShortCut* - short-cut header files will be created, redirecting to same-named header located in *src*;
|
||||||
|
* "HardLink* - hard links to headers located in *src* will be created.
|
||||||
* For optional third-party libraries, set corresponding environment variable <i>HAVE_<LIBRARY_NAME></i> to either *false*, e.g.:
|
* For optional third-party libraries, set corresponding environment variable <i>HAVE_<LIBRARY_NAME></i> to either *false*, e.g.:
|
||||||
~~~~~
|
~~~~~
|
||||||
export HAVE_GL2PS=false
|
export HAVE_GL2PS=false
|
||||||
|
@@ -248,7 +248,8 @@ Use of tabulation characters for indentation is disallowed.
|
|||||||
Punctuation rules follow the rules of the English language.
|
Punctuation rules follow the rules of the English language.
|
||||||
* C/C++ reserved words, commas, colons and semicolons should be followed by a space character if they are not at the end of a line.
|
* C/C++ reserved words, commas, colons and semicolons should be followed by a space character if they are not at the end of a line.
|
||||||
* There should be no space characters after '(' and before ')'. Closing and opening brackets should be separated by a space character.
|
* There should be no space characters after '(' and before ')'. Closing and opening brackets should be separated by a space character.
|
||||||
* For better readability it is also recommended to surround conventional operators by a space character. See the following examples:
|
* For better readability it is also recommended to surround conventional operators by a space character.
|
||||||
|
Examples:
|
||||||
|
|
||||||
~~~~~{.cpp}
|
~~~~~{.cpp}
|
||||||
while (true) // NOT: while( true ) ...
|
while (true) // NOT: while( true ) ...
|
||||||
@@ -261,6 +262,30 @@ for (anIter = 0; anIter < 10; ++anIter) // NOT: for (anIter=0;anIter<10;++anIter
|
|||||||
}
|
}
|
||||||
~~~~~
|
~~~~~
|
||||||
|
|
||||||
|
### Declaration of pointers and references
|
||||||
|
|
||||||
|
In declarations of simple pointers and references put asterisk (*) or ampersand (&) right after the type without extra space.
|
||||||
|
|
||||||
|
Since declaration of several variables with mixed pointer types contrudicts this rule, it should be avoided. Instead, declare each variable independently with fully qualified type.
|
||||||
|
|
||||||
|
Examples:
|
||||||
|
|
||||||
|
~~~~~{.cpp}
|
||||||
|
Standard_Integer *theVariable; // not recommended
|
||||||
|
Standard_Integer * theVariable; // not recommended
|
||||||
|
Standard_Integer* theVariable; // this is OK
|
||||||
|
|
||||||
|
Standard_Integer *&theVariable; // not recommended
|
||||||
|
Standard_Integer *& theVariable; // not recommended
|
||||||
|
Standard_Integer*& theVariable; // this is OK
|
||||||
|
|
||||||
|
Standard_Integer **theVariable; // not recommended
|
||||||
|
Standard_Integer ** theVariable; // not recommended
|
||||||
|
Standard_Integer** theVariable; // this is OK
|
||||||
|
|
||||||
|
Standard_Integer *theA, theB, **theC; // not recommended (declare each variable independently)
|
||||||
|
~~~~~
|
||||||
|
|
||||||
### Separate logical blocks
|
### Separate logical blocks
|
||||||
|
|
||||||
Separate logical blocks of code with one blank line and comments.
|
Separate logical blocks of code with one blank line and comments.
|
||||||
@@ -345,6 +370,25 @@ if (!theAlgo.IsNull()) // preferred
|
|||||||
|
|
||||||
Having all code in the same line is less convenient for debugging.
|
Having all code in the same line is less convenient for debugging.
|
||||||
|
|
||||||
|
### Comparison expressions with constants
|
||||||
|
|
||||||
|
In comparisons, put the variable (in the current context) on the left side and constant on the right side of expression.
|
||||||
|
That is, the so called "Yoda style" is to be avoided.
|
||||||
|
|
||||||
|
~~~~~{.cpp}
|
||||||
|
if (NULL != thePointer) // Yoda style, not recommended
|
||||||
|
if (thePointer != NULL) // OK
|
||||||
|
|
||||||
|
if (34 < anIter) // Yoda style, not recommended
|
||||||
|
if (anIter > 34) // OK
|
||||||
|
|
||||||
|
if (theNbValues >= anIter) // bad style (constant function argument vs. local variable)
|
||||||
|
if (anIter <= theNbValues) // OK
|
||||||
|
|
||||||
|
if (THE_LIMIT == theValue) // bad style (global constant vs. variable)
|
||||||
|
if (theValue == THE_LIMIT) // OK
|
||||||
|
~~~~~
|
||||||
|
|
||||||
### Alignment
|
### Alignment
|
||||||
|
|
||||||
Use alignment wherever it enhances the readability. See the following example:
|
Use alignment wherever it enhances the readability. See the following example:
|
||||||
|