Compare commits
378 Commits
temp-test-
...
multiview
Author | SHA1 | Date | |
---|---|---|---|
![]() |
3519a9f517 | ||
![]() |
bdf398daa8 | ||
![]() |
25d55cb560 | ||
![]() |
259c649a0f | ||
![]() |
a400c95c94 | ||
![]() |
cc6c55c4af | ||
![]() |
6ffd218444 | ||
![]() |
3fbab3bbba | ||
![]() |
af38ace3ae | ||
![]() |
ed94a8def2 | ||
![]() |
717d10154b | ||
![]() |
7f02b9e869 | ||
![]() |
bbf2305155 | ||
![]() |
7fc167f10f | ||
![]() |
ed5515dec3 | ||
![]() |
4f0f84fb05 | ||
![]() |
4728dbd309 | ||
![]() |
2179f01ef4 | ||
![]() |
18dab1fa80 | ||
![]() |
781efee98d | ||
![]() |
2bfabfd4b1 | ||
![]() |
2a69362b2b | ||
![]() |
a2ff63ca09 | ||
![]() |
35f1662d25 | ||
![]() |
8c064a83cf | ||
![]() |
3e1790feb1 | ||
![]() |
c6d2db21d3 | ||
![]() |
52ca9a1921 | ||
![]() |
83a729e471 | ||
![]() |
d3b915c273 | ||
![]() |
ced7d8fb79 | ||
![]() |
926a56a5a6 | ||
![]() |
156b1ccba0 | ||
![]() |
e426e18f77 | ||
![]() |
1fb36fe650 | ||
![]() |
2055cced49 | ||
![]() |
20c043d422 | ||
![]() |
bcc3cb7a75 | ||
![]() |
0a1942fbb4 | ||
![]() |
7ad48ff467 | ||
![]() |
fb658d87ff | ||
![]() |
82b26c553d | ||
![]() |
458a78d7f9 | ||
![]() |
8f3f8e66be | ||
![]() |
106d00eec0 | ||
![]() |
34cfd02806 | ||
![]() |
39423a894c | ||
![]() |
83cef40fa6 | ||
![]() |
347339d653 | ||
![]() |
48ab2d5984 | ||
![]() |
6df28be1f7 | ||
![]() |
92780acaeb | ||
![]() |
3cb5a07783 | ||
![]() |
43e10a6853 | ||
![]() |
38b854a544 | ||
![]() |
1566cb3291 | ||
![]() |
3302e5cc49 | ||
5370c00e6b | |||
21f6e13835 | |||
270b487360 | |||
![]() |
82139c399f | ||
![]() |
45d76c110f | ||
![]() |
cc4129b7bb | ||
![]() |
93ca780e4d | ||
![]() |
6da622c95f | ||
![]() |
1a574e51fe | ||
![]() |
56ec0bd871 | ||
![]() |
27a69cf4b0 | ||
![]() |
e6a45d88d8 | ||
f21db785d9 | |||
fa5c238950 | |||
04a9635686 | |||
fd5573c700 | |||
fcbf89b4d6 | |||
606e290500 | |||
9c30eaa675 | |||
ea3aeb974f | |||
f66f765c79 | |||
715db49f42 | |||
7b17b02669 | |||
f53ee18e0e | |||
![]() |
bf3a031e9b | ||
![]() |
a6a8cb846a | ||
![]() |
14c9d575ce | ||
![]() |
f426d4b173 | ||
![]() |
99779ccb6f | ||
![]() |
a1a5bff7d9 | ||
![]() |
7092a7a737 | ||
![]() |
f862307b5a | ||
![]() |
281b49cfa8 | ||
![]() |
84ac66445f | ||
![]() |
9697d1375f | ||
![]() |
c71d3a6232 | ||
![]() |
20e023541c | ||
![]() |
f6bd5b34e0 | ||
![]() |
5891dba59f | ||
![]() |
d6dcae331e | ||
![]() |
ec6b87e89f | ||
![]() |
9b5bb695dd | ||
![]() |
4156618620 | ||
![]() |
d845727661 | ||
![]() |
a07a020e5e | ||
![]() |
6bed3b60d6 | ||
![]() |
8ca0401d67 | ||
![]() |
3694692aec | ||
![]() |
3f795ec6f3 | ||
![]() |
9a6d9c16f3 | ||
![]() |
dce6d7b1ec | ||
![]() |
2cfe4f6858 | ||
![]() |
f7f6a44022 | ||
![]() |
1f3114ef63 | ||
![]() |
6478240648 | ||
![]() |
56cf38b00a | ||
![]() |
1a8769917c | ||
![]() |
39037fe06c | ||
![]() |
089c6d6694 | ||
![]() |
ebdedf8a96 | ||
![]() |
34069b71c4 | ||
4338e1298f | |||
fb7efc0541 | |||
21d3acb79f | |||
6ccc61c346 | |||
![]() |
fc9622a167 | ||
![]() |
4c050676e8 | ||
![]() |
2e207f9154 | ||
![]() |
11cb2ab919 | ||
![]() |
2da034db2f | ||
![]() |
7095b9555e | ||
![]() |
55d75953ce | ||
![]() |
a2ee2d866f | ||
![]() |
6b0b2783d6 | ||
![]() |
e692b3d1e3 | ||
![]() |
56be796099 | ||
![]() |
b6f853a4fc | ||
![]() |
ec4670d857 | ||
![]() |
a5a614e78e | ||
![]() |
2ae2e54a92 | ||
![]() |
7d24f22b79 | ||
![]() |
fb01c00286 | ||
![]() |
a96b382206 | ||
![]() |
0d5c4fceef | ||
![]() |
b9db39ab5e | ||
![]() |
dd3a2979a3 | ||
![]() |
67a2def60a | ||
![]() |
a74c5742cc | ||
![]() |
289c8d6c6c | ||
![]() |
fb2577ab31 | ||
![]() |
e150f4f268 | ||
![]() |
fb37fd9961 | ||
![]() |
7e62853719 | ||
![]() |
a6e05ad1dc | ||
![]() |
a87fd88c6b | ||
![]() |
4c5c103258 | ||
![]() |
803bf25dc8 | ||
![]() |
76ad40fbf7 | ||
![]() |
cc7b45ae1f | ||
![]() |
589209412d | ||
![]() |
0b4c9043e2 | ||
![]() |
046a5babb0 | ||
![]() |
d9d94d0cfc | ||
![]() |
774d02930d | ||
![]() |
f17f665e0c | ||
![]() |
293b795e9b | ||
![]() |
967d65960d | ||
![]() |
610c4273ec | ||
![]() |
7fefdaadc8 | ||
1b1090081b | |||
![]() |
a5176676b8 | ||
6f81acd7f9 | |||
281db468f1 | |||
![]() |
54596a84f5 | ||
d73d9629fb | |||
3480409ae8 | |||
c0c2881a92 | |||
cf1054bb75 | |||
8f4f6f3405 | |||
bce859c805 | |||
22995bf9dc | |||
0fb6b7a71f | |||
![]() |
7f1ebeb6ca | ||
![]() |
9674b10798 | ||
![]() |
058ec78f87 | ||
![]() |
ba81c53ba4 | ||
![]() |
70bb90e1e0 | ||
![]() |
e438d861ed | ||
![]() |
ef109f9032 | ||
![]() |
b132cbda03 | ||
![]() |
0b03ccbbcd | ||
![]() |
8eb050c058 | ||
![]() |
52bc4bff69 | ||
![]() |
5352fef28f | ||
![]() |
af29905d48 | ||
![]() |
6725532363 | ||
![]() |
a094c395c0 | ||
![]() |
d13789ccdc | ||
![]() |
7edc16245a | ||
![]() |
6dcbd52c44 | ||
![]() |
0a6402535d | ||
![]() |
7d36655e51 | ||
![]() |
6d6e0a7736 | ||
![]() |
53f3860622 | ||
![]() |
df888ef0cf | ||
![]() |
4ef8927781 | ||
![]() |
0e163beaf1 | ||
![]() |
aad21b5e17 | ||
![]() |
f8812fab51 | ||
![]() |
df0b4840ed | ||
![]() |
59bf863273 | ||
![]() |
5ed6e4a029 | ||
![]() |
08f2122d7a | ||
![]() |
20a7889df1 | ||
![]() |
306732ec56 | ||
![]() |
1a8cf4f8a4 | ||
![]() |
04a361f090 | ||
![]() |
482eac61a2 | ||
![]() |
3ce1849f25 | ||
![]() |
407d60330d | ||
![]() |
5b16c78913 | ||
![]() |
f9cb232851 | ||
![]() |
b62b55b03b | ||
![]() |
7b0c812a5b | ||
![]() |
53b48b9568 | ||
![]() |
11270fc3f1 | ||
![]() |
a1a66a8887 | ||
![]() |
a913047549 | ||
![]() |
6593212027 | ||
89dd233d5f | |||
97a7d3d7b1 | |||
5bf989d609 | |||
![]() |
c5211463f9 | ||
![]() |
8d4c498cb8 | ||
![]() |
560ee80286 | ||
04516721a0 | |||
6f662de83a | |||
e11fd354d4 | |||
3c70ec25c8 | |||
![]() |
268ab9e1b7 | ||
![]() |
876bc2b947 | ||
![]() |
c95e71a5fe | ||
![]() |
176bbdc3cf | ||
![]() |
3232751301 | ||
![]() |
cb12fac477 | ||
![]() |
fd5ee4dd18 | ||
![]() |
c588080245 | ||
![]() |
bf72d65607 | ||
![]() |
fc35c8ae26 | ||
![]() |
87d67a0c46 | ||
![]() |
4bb1566944 | ||
![]() |
7739ac8691 | ||
![]() |
153696489d | ||
![]() |
f4759ed978 | ||
![]() |
304f81b086 | ||
![]() |
85eadbf776 | ||
![]() |
c36dfb5950 | ||
![]() |
2910b0c77f | ||
![]() |
d75a10e986 | ||
![]() |
f964ccd582 | ||
![]() |
fd377e2612 | ||
![]() |
b0373525ca | ||
![]() |
1111b2101e | ||
![]() |
dbf135f53e | ||
![]() |
2a7f2287e6 | ||
![]() |
9ba7bb0e61 | ||
![]() |
2d1218a76e | ||
![]() |
c1a25c10c3 | ||
![]() |
008474521e | ||
![]() |
d73683af12 | ||
![]() |
6a324c1967 | ||
![]() |
0095ac2186 | ||
![]() |
04cd487448 | ||
![]() |
af178735ad | ||
![]() |
626a2865f5 | ||
![]() |
b3685a8ea3 | ||
![]() |
d2363db238 | ||
![]() |
53edcd5f97 | ||
![]() |
69bac908da | ||
![]() |
192039c355 | ||
![]() |
a4e537d0f4 | ||
![]() |
655804f23e | ||
![]() |
14da4996cc | ||
![]() |
04c20fd7b3 | ||
![]() |
483b9532a5 | ||
![]() |
2d677941f5 | ||
![]() |
58880ec965 | ||
![]() |
4dd894d1f5 | ||
![]() |
26f38f3fc0 | ||
![]() |
8216fb119c | ||
![]() |
7ae4b8ef1a | ||
![]() |
9e1d326892 | ||
![]() |
afe8054596 | ||
![]() |
a16fef8e61 | ||
![]() |
529484ed77 | ||
![]() |
2b606dc130 | ||
![]() |
b239314f29 | ||
![]() |
26ca7deae9 | ||
![]() |
1c33e9bb4d | ||
![]() |
2c35b52d16 | ||
![]() |
ea85ef9a17 | ||
![]() |
055c4feeb5 | ||
![]() |
8884eb8882 | ||
![]() |
c00d8fdb09 | ||
![]() |
cc4236efda | ||
![]() |
c556dc44da | ||
![]() |
327007e933 | ||
![]() |
610a66bf8c | ||
![]() |
920d6403f4 | ||
![]() |
8b96cf5d0b | ||
![]() |
ca14760dad | ||
![]() |
4f1e311d1b | ||
![]() |
45159fa2e3 | ||
![]() |
477daa9337 | ||
![]() |
273345ed84 | ||
![]() |
16d58a115b | ||
![]() |
f424d433f6 | ||
![]() |
92d846c7bb | ||
![]() |
1e2ddc45c1 | ||
![]() |
a79d4e0c1e | ||
2f839c26ac | |||
![]() |
79a3861413 | ||
![]() |
9475d5e8c2 | ||
![]() |
3fbc866077 | ||
![]() |
1e3a4891be | ||
![]() |
7f706ce3ab | ||
![]() |
fd14bbeee1 | ||
![]() |
4d4841f810 | ||
![]() |
d428079782 | ||
![]() |
f955759ba8 | ||
![]() |
eb19c93cb2 | ||
![]() |
77598ecd38 | ||
![]() |
f220d46679 | ||
![]() |
c65d6abd3b | ||
![]() |
6bd7e44a40 | ||
![]() |
a4ac20287c | ||
![]() |
97c8c290e8 | ||
![]() |
3051deeddd | ||
![]() |
f56325f0c1 | ||
![]() |
737e70e4f3 | ||
![]() |
7f3c4200aa | ||
![]() |
04b6f38a64 | ||
![]() |
43ffe6ef0c | ||
![]() |
e85098266d | ||
![]() |
01e15e5037 | ||
![]() |
c47cd40944 | ||
![]() |
09c6b31395 | ||
![]() |
a76a84225c | ||
![]() |
f230d15ce1 | ||
![]() |
4e85d8daea | ||
![]() |
5ec6e7091e | ||
![]() |
bf86d65273 | ||
![]() |
5c1da8a78a | ||
![]() |
05c8590896 | ||
![]() |
6311911466 | ||
![]() |
361ed81048 | ||
![]() |
136823c3d1 | ||
![]() |
633f55ac6b | ||
![]() |
029938fb96 | ||
![]() |
e611409068 | ||
![]() |
4bd686cc95 | ||
![]() |
e480f93e21 | ||
![]() |
65510c0bcd | ||
![]() |
0147d96aea | ||
![]() |
dd7469df12 | ||
![]() |
edeeb7866f | ||
![]() |
0f56e3d6ed | ||
![]() |
9c2dd855ea | ||
![]() |
0bfc90a317 | ||
![]() |
205afa0a06 | ||
![]() |
c7bcd6310b | ||
![]() |
99c988ce84 | ||
![]() |
baaf31864a | ||
![]() |
a0b49f357a | ||
![]() |
5bd7ed4298 | ||
![]() |
042cf19838 | ||
![]() |
aef5800b8c | ||
![]() |
f4eae173c2 | ||
![]() |
63d30c704d | ||
![]() |
04b98f6118 | ||
![]() |
92a1b76e29 |
@@ -1,8 +1,6 @@
|
||||
{
|
||||
"project_id" : "Blender",
|
||||
"conduit_uri" : "https://developer.blender.org/",
|
||||
"phabricator.uri" : "https://developer.blender.org/",
|
||||
"git.default-relative-commit" : "origin/master",
|
||||
"arc.land.update.default" : "rebase",
|
||||
"arc.land.onto.default" : "master"
|
||||
"arc.land.update.default" : "rebase"
|
||||
}
|
||||
|
264
.clang-format
264
.clang-format
@@ -1,264 +0,0 @@
|
||||
|
||||
# Configuration of clang-format
|
||||
# =============================
|
||||
#
|
||||
# Tested to work with versions: 6 to 8.
|
||||
|
||||
# This causes parameters on continuations to align to the opening brace.
|
||||
#
|
||||
# like_this_long_name(parameter_one,
|
||||
# parameter_two,
|
||||
# parameter_three);
|
||||
#
|
||||
AlignAfterOpenBracket: 'Align'
|
||||
|
||||
# Disallow short functions on one line; break them up.
|
||||
AllowShortBlocksOnASingleLine: false
|
||||
|
||||
# These two settings trigger stacking of parameters in most cases; this is
|
||||
# easier to read and also makes diffs easier to read (since an added or removed
|
||||
# parameter is obvious). For example, function calls will look like this:
|
||||
#
|
||||
# like_this_long_name(parameter_one,
|
||||
# parameter_two,
|
||||
# parameter_three,
|
||||
# parameter_four,
|
||||
# parameter_five,
|
||||
# parameter_six);
|
||||
#
|
||||
# Instead of:
|
||||
#
|
||||
# like_this_long_name(parameter_one, parameter_two, parameter_three, parameter_four,
|
||||
# parameter_five, parameter_six);
|
||||
#
|
||||
BinPackArguments: false
|
||||
BinPackParameters: false
|
||||
|
||||
# Line width (don't exceed 100).
|
||||
ColumnLimit: 99
|
||||
|
||||
# Cause initializer lists to have one member initialized per line, in the case
|
||||
# that all initializers can't fit on a single line.
|
||||
ConstructorInitializerAllOnOneLineOrOnePerLine: true
|
||||
|
||||
# Indent the : after a constructor. For example:
|
||||
#
|
||||
# explicit foo_class ()
|
||||
# : member1_(5)
|
||||
# {
|
||||
# }
|
||||
#
|
||||
ConstructorInitializerIndentWidth: 4
|
||||
|
||||
# Make access modifier slightly more visible.
|
||||
AccessModifierOffset: -1
|
||||
|
||||
# This will unfortunately use spaces in some cases where it's not desired (like
|
||||
# function calls) but the overall result is better since it will allow
|
||||
# alignment to work properly with different tab width settings.
|
||||
ContinuationIndentWidth: 4
|
||||
|
||||
# This tries to match Blender's style as much as possible. One
|
||||
BreakBeforeBraces: Custom
|
||||
BraceWrapping: {
|
||||
AfterClass: 'false'
|
||||
AfterControlStatement: 'false'
|
||||
AfterEnum : 'false'
|
||||
AfterFunction : 'true'
|
||||
AfterNamespace : 'false'
|
||||
AfterStruct : 'false'
|
||||
AfterUnion : 'false'
|
||||
BeforeCatch : 'true'
|
||||
BeforeElse : 'true'
|
||||
IndentBraces : 'false'
|
||||
AfterObjCDeclaration: 'true'
|
||||
}
|
||||
|
||||
# For switch statements, indent the cases.
|
||||
IndentCaseLabels: true
|
||||
|
||||
# Indent after the hash inside preprocessor directives
|
||||
IndentPPDirectives: AfterHash
|
||||
|
||||
BreakBeforeTernaryOperators: false
|
||||
|
||||
SpaceAfterTemplateKeyword: false
|
||||
|
||||
# Handy comment at the end of each C++ name space.
|
||||
FixNamespaceComments: true
|
||||
|
||||
# Use "if (...)" instead of "if(...)", but have function calls like foo().
|
||||
SpaceBeforeParens: ControlStatements
|
||||
SpaceInEmptyParentheses: false
|
||||
|
||||
# Use two spaces before trailing comments, for example
|
||||
#
|
||||
# foo = bar; // comment
|
||||
#
|
||||
# Note that this doesn't work for C-style comments.
|
||||
SpacesBeforeTrailingComments: 2
|
||||
|
||||
# Reflow comments, developers must disable formatting as with code to override this.
|
||||
ReflowComments: true
|
||||
|
||||
# Never use tabs for indentation.
|
||||
# Note: TabWidth and IndentWidth must be the same, or strange things happen.
|
||||
UseTab: Never
|
||||
TabWidth: 2
|
||||
IndentWidth: 2
|
||||
|
||||
# Add a big penalty on breaking after the return type of functions. For example,
|
||||
#
|
||||
# static void foo(...)
|
||||
#
|
||||
# Instead of:
|
||||
#
|
||||
# static void
|
||||
# foo(very long content here that maybe could be stacked)
|
||||
#
|
||||
PenaltyReturnTypeOnItsOwnLine: 10000
|
||||
|
||||
# Avoid having function calls broken onto a new line:
|
||||
#
|
||||
# int a = foo(
|
||||
# long, list, of, many, params);
|
||||
#
|
||||
# Instead of:
|
||||
#
|
||||
# int a =
|
||||
# foo(long, list, of, many, params);
|
||||
#
|
||||
PenaltyBreakAssignment: 100
|
||||
|
||||
AllowShortFunctionsOnASingleLine: None
|
||||
|
||||
SortIncludes: true
|
||||
|
||||
# Don't right align escaped newlines to the right because we have a wide default
|
||||
AlignEscapedNewlines: DontAlign
|
||||
|
||||
# Always break:
|
||||
#
|
||||
# const char *foo =
|
||||
# "multi"
|
||||
# "line";
|
||||
#
|
||||
# Instead of:
|
||||
#
|
||||
# const char *foo = "multi"
|
||||
# "line";
|
||||
#
|
||||
AlwaysBreakBeforeMultilineStrings: true
|
||||
|
||||
# We don't want literal strings to break,
|
||||
# however clang-format seems to ignore this (sigh).
|
||||
PenaltyBreakString: 1000000
|
||||
|
||||
# There are macros in Blender for custom for loops; tell Clang to treat them
|
||||
# like loops rather than an expression, and so put the { on the same line.
|
||||
#
|
||||
# To find these use multi-line regex search:
|
||||
# "^\s+[A-Z][A-Z0-9_]+\s*\([^\n]*\)\n\s*\{"
|
||||
ForEachMacros:
|
||||
- BEGIN_ANIMFILTER_SUBCHANNELS
|
||||
- BLI_FOREACH_SPARSE_RANGE
|
||||
- BLI_SMALLSTACK_ITER_BEGIN
|
||||
- BMO_ITER
|
||||
- BMO_ITER_INDEX
|
||||
- BMW_ITER
|
||||
- BM_FACES_OF_VERT_ITER_BEGIN
|
||||
- BM_ITER_BPY_BM_SEQ
|
||||
- BM_ITER_ELEM
|
||||
- BM_ITER_ELEM_INDEX
|
||||
- BM_ITER_MESH
|
||||
- BM_ITER_MESH_INDEX
|
||||
- BM_ITER_MESH_MUTABLE
|
||||
- BM_LOOPS_OF_VERT_ITER_BEGIN
|
||||
- BOOST_FOREACH
|
||||
- CTX_DATA_BEGIN
|
||||
- CTX_DATA_BEGIN_WITH_ID
|
||||
- DEG_OBJECT_ITER_BEGIN
|
||||
- DEG_OBJECT_ITER_FOR_RENDER_ENGINE_BEGIN
|
||||
- DRIVER_TARGETS_LOOPER_BEGIN
|
||||
- DRIVER_TARGETS_USED_LOOPER_BEGIN
|
||||
- FOREACH_BASE_IN_EDIT_MODE_BEGIN
|
||||
- FOREACH_BASE_IN_MODE_BEGIN
|
||||
- FOREACH_BEGIN
|
||||
- FOREACH_COLLECTION_BEGIN
|
||||
- FOREACH_COLLECTION_OBJECT_RECURSIVE_BEGIN
|
||||
- FOREACH_COLLECTION_VISIBLE_OBJECT_RECURSIVE_BEGIN
|
||||
- FOREACH_EDIT_OBJECT_BEGIN
|
||||
- FOREACH_MAIN_ID_BEGIN
|
||||
- FOREACH_MAIN_LISTBASE_BEGIN
|
||||
- FOREACH_MAIN_LISTBASE_ID_BEGIN
|
||||
- FOREACH_MESH_BUFFER_CACHE
|
||||
- FOREACH_NODETREE_BEGIN
|
||||
- FOREACH_OBJECT_BEGIN
|
||||
- FOREACH_OBJECT_FLAG_BEGIN
|
||||
- FOREACH_OBJECT_IN_EDIT_MODE_BEGIN
|
||||
- FOREACH_OBJECT_IN_MODE_BEGIN
|
||||
- FOREACH_OBJECT_RENDERABLE_BEGIN
|
||||
- FOREACH_PCHAN_SELECTED_IN_OBJECT_BEGIN
|
||||
- FOREACH_PCHAN_VISIBLE_IN_OBJECT_BEGIN
|
||||
- FOREACH_SCENE_COLLECTION_BEGIN
|
||||
- FOREACH_SCENE_OBJECT_BEGIN
|
||||
- FOREACH_SELECTED_BASE_BEGIN
|
||||
- FOREACH_SELECTED_EDITABLE_OBJECT_BEGIN
|
||||
- FOREACH_SELECTED_OBJECT_BEGIN
|
||||
- FOREACH_TRANS_DATA_CONTAINER
|
||||
- FOREACH_VIEW_LAYER_TO_RENDER_BEGIN
|
||||
- FOREACH_VISIBLE_BASE_BEGIN
|
||||
- FOREACH_VISIBLE_OBJECT_BEGIN
|
||||
- GHASH_FOREACH_BEGIN
|
||||
- GHASH_ITER
|
||||
- GHASH_ITER_INDEX
|
||||
- GPU_SELECT_LOAD_IF_PICKSEL_LIST
|
||||
- GP_EDITABLE_STROKES_BEGIN
|
||||
- GP_EVALUATED_STROKES_BEGIN
|
||||
- GSET_FOREACH_BEGIN
|
||||
- GSET_ITER
|
||||
- GSET_ITER_INDEX
|
||||
- ITER_BEGIN
|
||||
- ITER_PIXELS
|
||||
- ITER_SLOTS
|
||||
- ITER_SLOTS_BEGIN
|
||||
- LOOP_EDITED_POINTS
|
||||
- LOOP_KEYS
|
||||
- LOOP_POINTS
|
||||
- LOOP_SELECTED_KEYS
|
||||
- LOOP_SELECTED_POINTS
|
||||
- LOOP_TAGGED_KEYS
|
||||
- LOOP_TAGGED_POINTS
|
||||
- LOOP_UNSELECTED_POINTS
|
||||
- LOOP_VISIBLE_KEYS
|
||||
- LOOP_VISIBLE_POINTS
|
||||
- LISTBASE_CIRCULAR_BACKWARD_BEGIN
|
||||
- LISTBASE_CIRCULAR_FORWARD_BEGIN
|
||||
- LISTBASE_FOREACH
|
||||
- LISTBASE_FOREACH_BACKWARD
|
||||
- LISTBASE_FOREACH_MUTABLE
|
||||
- LISTBASE_FOREACH_BACKWARD_MUTABLE
|
||||
- MAN_ITER_AXES_BEGIN
|
||||
- NODE_INSTANCE_HASH_ITER
|
||||
- NODE_SOCKET_TYPES_BEGIN
|
||||
- NODE_TREE_TYPES_BEGIN
|
||||
- NODE_TYPES_BEGIN
|
||||
- PIXEL_LOOPER_BEGIN
|
||||
- PIXEL_LOOPER_BEGIN_CHANNELS
|
||||
- RENDER_PASS_ITER_BEGIN
|
||||
- RNA_BEGIN
|
||||
- RNA_PROP_BEGIN
|
||||
- RNA_STRUCT_BEGIN
|
||||
- RNA_STRUCT_BEGIN_SKIP_RNA_TYPE
|
||||
- SCULPT_VERTEX_DUPLICATES_AND_NEIGHBORS_ITER_BEGIN
|
||||
- SCULPT_VERTEX_NEIGHBORS_ITER_BEGIN
|
||||
- SEQP_BEGIN
|
||||
- SEQ_BEGIN
|
||||
- SURFACE_QUAD_ITER_BEGIN
|
||||
- foreach
|
||||
|
||||
# Use once we bump the minimum version to version 8.
|
||||
# # Without this string literals that in-line 'STRINGIFY' behave strangely (a bug?).
|
||||
# StatementMacros:
|
||||
# - PyObject_VAR_HEAD
|
||||
# - STRINGIFY
|
@@ -1,44 +0,0 @@
|
||||
# C/C++
|
||||
[*.{c,cc,h,hh,inl,glsl}]
|
||||
charset = utf-8
|
||||
trim_trailing_whitespace = true
|
||||
insert_final_newline = true
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
max_line_length = 99
|
||||
|
||||
# CMake & Text
|
||||
[*.{cmake,txt}]
|
||||
charset = utf-8
|
||||
trim_trailing_whitespace = true
|
||||
insert_final_newline = true
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
max_line_length = 99
|
||||
|
||||
# Python
|
||||
[*.py]
|
||||
charset = utf-8
|
||||
trim_trailing_whitespace = true
|
||||
insert_final_newline = true
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
max_line_length = 120
|
||||
|
||||
# Shell
|
||||
[*.sh]
|
||||
charset = utf-8
|
||||
trim_trailing_whitespace = true
|
||||
insert_final_newline = true
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
max_line_length = 99
|
||||
|
||||
# reStructuredText
|
||||
[*.rst]
|
||||
charset = utf-8
|
||||
trim_trailing_whitespace = true
|
||||
insert_final_newline = true
|
||||
indent_style = space
|
||||
indent_size = 3
|
||||
max_line_length = 120
|
22
.github/stale.yml
vendored
22
.github/stale.yml
vendored
@@ -1,22 +0,0 @@
|
||||
# Configuration for probot-stale - https://github.com/probot/stale
|
||||
# This file is used on Blender's GitHub mirror to automatically close any pull request
|
||||
# and invite contributors to join the official development platform on blender.org
|
||||
|
||||
# Number of days of inactivity before an Issue or Pull Request becomes stale
|
||||
daysUntilStale: 1
|
||||
|
||||
# Number of days of inactivity before an Issue or Pull Request with the stale label is closed.
|
||||
# Set to false to disable. If disabled, issues still need to be closed manually, but will remain marked as stale.
|
||||
daysUntilClose: 1
|
||||
|
||||
# Label to use when marking as stale
|
||||
staleLabel: stale
|
||||
|
||||
# Comment to post when closing a stale Issue or Pull Request.
|
||||
closeComment: >
|
||||
This issue has been automatically closed, because this repository is only
|
||||
used as a mirror of git.blender.org. Blender development happens on
|
||||
developer.blender.org.
|
||||
|
||||
To get started contributing code, please read:
|
||||
https://wiki.blender.org/wiki/Process/Contributing_Code
|
16
.gitignore
vendored
16
.gitignore
vendored
@@ -11,10 +11,6 @@ __pycache__/
|
||||
*.swo
|
||||
*#
|
||||
|
||||
# Indexes for emacs, vi & others
|
||||
TAGS
|
||||
tags
|
||||
|
||||
# QtCreator
|
||||
CMakeLists.txt.user
|
||||
|
||||
@@ -25,7 +21,7 @@ Desktop.ini
|
||||
|
||||
# commonly used paths in blender
|
||||
/blender.bin
|
||||
/BUILD_NOTES.txt
|
||||
/user-config.py
|
||||
|
||||
# local patches
|
||||
/*.patch
|
||||
@@ -36,13 +32,3 @@ Desktop.ini
|
||||
/doc/python_api/sphinx-in-tmp/
|
||||
/doc/python_api/sphinx-in/
|
||||
/doc/python_api/sphinx-out/
|
||||
/doc/python_api/rst/bmesh.ops.rst
|
||||
|
||||
# in-source lib downloads
|
||||
/build_files/build_environment/downloads
|
||||
|
||||
# in-source buildbot signing configuration
|
||||
/build_files/buildbot/codesign/config_server.py
|
||||
|
||||
# smoke simulation noise tile (generated)
|
||||
waveletNoiseTile.bin
|
||||
|
10
.gitmodules
vendored
10
.gitmodules
vendored
@@ -1,20 +1,16 @@
|
||||
[submodule "release/scripts/addons"]
|
||||
path = release/scripts/addons
|
||||
url = ../blender-addons.git
|
||||
branch = master
|
||||
ignore = all
|
||||
[submodule "release/scripts/addons_contrib"]
|
||||
path = release/scripts/addons_contrib
|
||||
url = ../blender-addons-contrib.git
|
||||
branch = master
|
||||
ignore = all
|
||||
[submodule "release/datafiles/locale"]
|
||||
path = release/datafiles/locale
|
||||
url = ../blender-translations.git
|
||||
branch = master
|
||||
ignore = all
|
||||
[submodule "source/tools"]
|
||||
path = source/tools
|
||||
url = ../blender-dev-tools.git
|
||||
branch = master
|
||||
[submodule "scons"]
|
||||
path = scons
|
||||
url = ../scons.git
|
||||
ignore = all
|
||||
|
3520
CMakeLists.txt
3520
CMakeLists.txt
File diff suppressed because it is too large
Load Diff
507
GNUmakefile
507
GNUmakefile
@@ -1,4 +1,4 @@
|
||||
# -*- mode: gnumakefile; tab-width: 4; indent-tabs-mode: t; -*-
|
||||
# -*- mode: gnumakefile; tab-width: 8; indent-tabs-mode: t; -*-
|
||||
# vim: tabstop=4
|
||||
#
|
||||
# ##### BEGIN GPL LICENSE BLOCK #####
|
||||
@@ -24,183 +24,25 @@
|
||||
# ../build_linux_i386
|
||||
# This is for users who like to configure & build blender with a single command.
|
||||
|
||||
define HELP_TEXT
|
||||
|
||||
Convenience Targets
|
||||
Provided for building Blender, (multiple at once can be used).
|
||||
|
||||
* debug: Build a debug binary.
|
||||
* full: Enable all supported dependencies & options.
|
||||
* lite: Disable non essential features for a smaller binary and faster build.
|
||||
* headless: Build without an interface (renderfarm or server automation).
|
||||
* cycles: Build Cycles standalone only, without Blender.
|
||||
* bpy: Build as a python module which can be loaded from python directly.
|
||||
* deps: Build library dependencies (intended only for platform maintainers).
|
||||
|
||||
* developer: Enable faster builds, error checking and tests, recommended for developers.
|
||||
* config: Run cmake configuration tool to set build options.
|
||||
* ninja: Use ninja build tool for faster builds.
|
||||
|
||||
Note: passing the argument 'BUILD_DIR=path' when calling make will override the default build dir.
|
||||
Note: passing the argument 'BUILD_CMAKE_ARGS=args' lets you add cmake arguments.
|
||||
|
||||
|
||||
Project Files
|
||||
Generate project files for development environments.
|
||||
|
||||
* project_qtcreator: QtCreator Project Files.
|
||||
* project_netbeans: NetBeans Project Files.
|
||||
* project_eclipse: Eclipse CDT4 Project Files.
|
||||
|
||||
Package Targets
|
||||
|
||||
* package_debian: Build a debian package.
|
||||
* package_pacman: Build an arch linux pacman package.
|
||||
* package_archive: Build an archive package.
|
||||
|
||||
Testing Targets
|
||||
Not associated with building Blender.
|
||||
|
||||
* test:
|
||||
Run automated tests with ctest.
|
||||
* test_cmake:
|
||||
Runs our own cmake file checker
|
||||
which detects errors in the cmake file list definitions
|
||||
* test_pep8:
|
||||
Checks all python script are pep8
|
||||
which are tagged to use the stricter formatting
|
||||
* test_deprecated:
|
||||
Checks for deprecation tags in our code which may need to be removed
|
||||
* test_style_c:
|
||||
Checks C/C++ conforms with blenders style guide:
|
||||
https://wiki.blender.org/wiki/Source/Code_Style
|
||||
* test_style_c_qtc:
|
||||
Same as test_style but outputs QtCreator tasks format
|
||||
* test_style_osl:
|
||||
Checks OpenShadingLanguage conforms with blenders style guide:
|
||||
https://wiki.blender.org/wiki/Source/Code_Style
|
||||
* test_style_osl_qtc:
|
||||
Checks OpenShadingLanguage conforms with blenders style guide:
|
||||
https://wiki.blender.org/wiki/Source/Code_Style
|
||||
|
||||
Static Source Code Checking
|
||||
Not associated with building Blender.
|
||||
|
||||
* check_cppcheck: Run blender source through cppcheck (C & C++).
|
||||
* check_clang_array: Run blender source through clang array checking script (C & C++).
|
||||
* check_splint: Run blenders source through splint (C only).
|
||||
* check_sparse: Run blenders source through sparse (C only).
|
||||
* check_smatch: Run blenders source through smatch (C only).
|
||||
* check_spelling_c: Check for spelling errors (C/C++ only).
|
||||
* check_spelling_c_qtc: Same as check_spelling_c but outputs QtCreator tasks format.
|
||||
* check_spelling_osl: Check for spelling errors (OSL only).
|
||||
* check_spelling_py: Check for spelling errors (Python only).
|
||||
* check_descriptions: Check for duplicate/invalid descriptions.
|
||||
|
||||
Utilities
|
||||
Not associated with building Blender.
|
||||
|
||||
* icons:
|
||||
Updates PNG icons from SVG files.
|
||||
|
||||
Optionally pass in variables: 'BLENDER_BIN', 'INKSCAPE_BIN'
|
||||
otherwise default paths are used.
|
||||
|
||||
Example
|
||||
make icons INKSCAPE_BIN=/path/to/inkscape
|
||||
|
||||
* icons_geom:
|
||||
Updates Geometry icons from BLEND file.
|
||||
|
||||
Optionally pass in variable: 'BLENDER_BIN'
|
||||
otherwise default paths are used.
|
||||
|
||||
Example
|
||||
make icons_geom BLENDER_BIN=/path/to/blender
|
||||
|
||||
* source_archive:
|
||||
Create a compressed archive of the source code.
|
||||
|
||||
* update:
|
||||
updates git and all submodules
|
||||
|
||||
* format
|
||||
Format source code using clang (uses PATHS if passed in). For example::
|
||||
|
||||
make format PATHS="source/blender/blenlib source/blender/blenkernel"
|
||||
|
||||
Environment Variables
|
||||
|
||||
* BUILD_CMAKE_ARGS: Arguments passed to CMake.
|
||||
* BUILD_DIR: Override default build path.
|
||||
* PYTHON: Use this for the Python command (used for checking tools).
|
||||
* NPROCS: Number of processes to use building (auto-detect when omitted).
|
||||
|
||||
Documentation Targets
|
||||
Not associated with building Blender.
|
||||
|
||||
* doc_py: Generate sphinx python api docs.
|
||||
* doc_doxy: Generate doxygen C/C++ docs.
|
||||
* doc_dna: Generate blender file format reference.
|
||||
* doc_man: Generate manpage.
|
||||
|
||||
Information
|
||||
|
||||
* help: This help message.
|
||||
* help_features: Show a list of optional features when building.
|
||||
|
||||
endef
|
||||
# HELP_TEXT (end)
|
||||
|
||||
|
||||
# System Vars
|
||||
OS:=$(shell uname -s)
|
||||
OS_NCASE:=$(shell uname -s | tr '[A-Z]' '[a-z]')
|
||||
CPU:=$(shell uname -m)
|
||||
# CPU:=$(shell uname -m) # UNUSED
|
||||
|
||||
|
||||
# Source and Build DIR's
|
||||
BLENDER_DIR:=$(shell pwd -P)
|
||||
BUILD_TYPE:=Release
|
||||
|
||||
# CMake arguments, assigned to local variable to make it mutable.
|
||||
CMAKE_CONFIG_ARGS := $(BUILD_CMAKE_ARGS)
|
||||
ifndef BUILD_CMAKE_ARGS
|
||||
BUILD_CMAKE_ARGS:=
|
||||
endif
|
||||
|
||||
ifndef BUILD_DIR
|
||||
BUILD_DIR:=$(shell dirname "$(BLENDER_DIR)")/build_$(OS_NCASE)
|
||||
endif
|
||||
|
||||
# Dependencies DIR's
|
||||
DEPS_SOURCE_DIR:=$(BLENDER_DIR)/build_files/build_environment
|
||||
|
||||
ifndef DEPS_BUILD_DIR
|
||||
DEPS_BUILD_DIR:=$(BUILD_DIR)/deps
|
||||
endif
|
||||
|
||||
ifndef DEPS_INSTALL_DIR
|
||||
DEPS_INSTALL_DIR:=$(shell dirname "$(BLENDER_DIR)")/lib/$(OS_NCASE)
|
||||
|
||||
ifneq ($(OS_NCASE),darwin)
|
||||
# Add processor type to directory name
|
||||
DEPS_INSTALL_DIR:=$(DEPS_INSTALL_DIR)_$(CPU)
|
||||
endif
|
||||
endif
|
||||
|
||||
# Allow to use alternative binary (pypy3, etc)
|
||||
ifndef PYTHON
|
||||
PYTHON:=python3
|
||||
endif
|
||||
|
||||
# For macOS python3 is not installed by default, so fallback to python binary
|
||||
# in libraries, or python 2 for running make update to get it.
|
||||
ifeq ($(OS_NCASE),darwin)
|
||||
ifeq (, $(shell command -v $(PYTHON)))
|
||||
PYTHON:=../lib/darwin/python/bin/python3.7m
|
||||
ifeq (, $(shell command -v $(PYTHON)))
|
||||
PYTHON:=python
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# additional targets for the build configuration
|
||||
@@ -212,85 +54,50 @@ ifneq "$(findstring debug, $(MAKECMDGOALS))" ""
|
||||
endif
|
||||
ifneq "$(findstring full, $(MAKECMDGOALS))" ""
|
||||
BUILD_DIR:=$(BUILD_DIR)_full
|
||||
CMAKE_CONFIG_ARGS:=-C"$(BLENDER_DIR)/build_files/cmake/config/blender_full.cmake" $(CMAKE_CONFIG_ARGS)
|
||||
BUILD_CMAKE_ARGS:=$(BUILD_CMAKE_ARGS) -C"$(BLENDER_DIR)/build_files/cmake/config/blender_full.cmake"
|
||||
endif
|
||||
ifneq "$(findstring lite, $(MAKECMDGOALS))" ""
|
||||
BUILD_DIR:=$(BUILD_DIR)_lite
|
||||
CMAKE_CONFIG_ARGS:=-C"$(BLENDER_DIR)/build_files/cmake/config/blender_lite.cmake" $(CMAKE_CONFIG_ARGS)
|
||||
BUILD_CMAKE_ARGS:=$(BUILD_CMAKE_ARGS) -C"$(BLENDER_DIR)/build_files/cmake/config/blender_lite.cmake"
|
||||
endif
|
||||
ifneq "$(findstring cycles, $(MAKECMDGOALS))" ""
|
||||
BUILD_DIR:=$(BUILD_DIR)_cycles
|
||||
CMAKE_CONFIG_ARGS:=-C"$(BLENDER_DIR)/build_files/cmake/config/cycles_standalone.cmake" $(CMAKE_CONFIG_ARGS)
|
||||
BUILD_CMAKE_ARGS:=$(BUILD_CMAKE_ARGS) -C"$(BLENDER_DIR)/build_files/cmake/config/cycles_standalone.cmake"
|
||||
endif
|
||||
ifneq "$(findstring headless, $(MAKECMDGOALS))" ""
|
||||
BUILD_DIR:=$(BUILD_DIR)_headless
|
||||
CMAKE_CONFIG_ARGS:=-C"$(BLENDER_DIR)/build_files/cmake/config/blender_headless.cmake" $(CMAKE_CONFIG_ARGS)
|
||||
BUILD_CMAKE_ARGS:=$(BUILD_CMAKE_ARGS) -C"$(BLENDER_DIR)/build_files/cmake/config/blender_headless.cmake"
|
||||
endif
|
||||
ifneq "$(findstring bpy, $(MAKECMDGOALS))" ""
|
||||
BUILD_DIR:=$(BUILD_DIR)_bpy
|
||||
CMAKE_CONFIG_ARGS:=-C"$(BLENDER_DIR)/build_files/cmake/config/bpy_module.cmake" $(CMAKE_CONFIG_ARGS)
|
||||
endif
|
||||
|
||||
ifneq "$(findstring developer, $(MAKECMDGOALS))" ""
|
||||
CMAKE_CONFIG_ARGS:=-C"$(BLENDER_DIR)/build_files/cmake/config/blender_developer.cmake" $(CMAKE_CONFIG_ARGS)
|
||||
endif
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# build tool
|
||||
|
||||
ifneq "$(findstring ninja, $(MAKECMDGOALS))" ""
|
||||
CMAKE_CONFIG_ARGS:=$(CMAKE_CONFIG_ARGS) -G Ninja
|
||||
BUILD_COMMAND:=ninja
|
||||
DEPS_BUILD_COMMAND:=ninja
|
||||
else
|
||||
ifneq ("$(wildcard $(BUILD_DIR)/build.ninja)","")
|
||||
BUILD_COMMAND:=ninja
|
||||
else
|
||||
BUILD_COMMAND:=make -s
|
||||
endif
|
||||
|
||||
ifneq ("$(wildcard $(DEPS_BUILD_DIR)/build.ninja)","")
|
||||
DEPS_BUILD_COMMAND:=ninja
|
||||
else
|
||||
DEPS_BUILD_COMMAND:=make -s
|
||||
endif
|
||||
endif
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Blender binary path
|
||||
|
||||
# Allow passing in own BLENDER_BIN so developers who don't
|
||||
# use the default build path can still use utility helpers.
|
||||
ifeq ($(OS), Darwin)
|
||||
BLENDER_BIN?="$(BUILD_DIR)/bin/Blender.app/Contents/MacOS/Blender"
|
||||
else
|
||||
BLENDER_BIN?="$(BUILD_DIR)/bin/blender"
|
||||
BUILD_CMAKE_ARGS:=$(BUILD_CMAKE_ARGS) -C"$(BLENDER_DIR)/build_files/cmake/config/bpy_module.cmake"
|
||||
endif
|
||||
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Get the number of cores for threaded build
|
||||
ifndef NPROCS
|
||||
NPROCS:=1
|
||||
ifeq ($(OS), Linux)
|
||||
NPROCS:=$(shell nproc)
|
||||
endif
|
||||
ifeq ($(OS), NetBSD)
|
||||
NPROCS:=$(shell getconf NPROCESSORS_ONLN)
|
||||
endif
|
||||
ifneq (,$(filter $(OS),Darwin FreeBSD))
|
||||
NPROCS:=$(shell sysctl -n hw.ncpu)
|
||||
endif
|
||||
NPROCS:=1
|
||||
ifeq ($(OS), Linux)
|
||||
NPROCS:=$(shell nproc)
|
||||
endif
|
||||
ifeq ($(OS), Darwin)
|
||||
NPROCS:=$(shell sysctl -a | grep "hw.ncpu" | cut -d" " -f3)
|
||||
endif
|
||||
ifeq ($(OS), FreeBSD)
|
||||
NPROCS:=$(shell sysctl -a | grep "hw.ncpu" | cut -d" " -f2 )
|
||||
endif
|
||||
ifeq ($(OS), NetBSD)
|
||||
NPROCS:=$(shell sysctl -a | grep "hw.ncpu" | cut -d" " -f2 )
|
||||
endif
|
||||
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Macro for configuring cmake
|
||||
|
||||
CMAKE_CONFIG = cmake $(CMAKE_CONFIG_ARGS) \
|
||||
CMAKE_CONFIG = cmake $(BUILD_CMAKE_ARGS) \
|
||||
-H"$(BLENDER_DIR)" \
|
||||
-B"$(BUILD_DIR)" \
|
||||
-DCMAKE_BUILD_TYPE_INIT:STRING=$(BUILD_TYPE)
|
||||
-DCMAKE_BUILD_TYPE:STRING=$(BUILD_TYPE)
|
||||
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
@@ -299,30 +106,30 @@ CMAKE_CONFIG = cmake $(CMAKE_CONFIG_ARGS) \
|
||||
# X11 spesific
|
||||
ifdef DISPLAY
|
||||
CMAKE_CONFIG_TOOL = cmake-gui
|
||||
else
|
||||
else
|
||||
CMAKE_CONFIG_TOOL = ccmake
|
||||
endif
|
||||
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Build Blender
|
||||
all: .FORCE
|
||||
all: FORCE
|
||||
@echo
|
||||
@echo Configuring Blender in \"$(BUILD_DIR)\" ...
|
||||
@echo Configuring Blender ...
|
||||
|
||||
# # if test ! -f $(BUILD_DIR)/CMakeCache.txt ; then \
|
||||
# # $(CMAKE_CONFIG); \
|
||||
# # fi
|
||||
|
||||
# # do this always incase of failed initial build, could be smarter here...
|
||||
@$(CMAKE_CONFIG)
|
||||
# if test ! -f $(BUILD_DIR)/CMakeCache.txt ; then \
|
||||
# $(CMAKE_CONFIG); \
|
||||
# fi
|
||||
|
||||
# do this always incase of failed initial build, could be smarter here...
|
||||
$(CMAKE_CONFIG)
|
||||
|
||||
@echo
|
||||
@echo Building Blender ...
|
||||
$(BUILD_COMMAND) -C "$(BUILD_DIR)" -j $(NPROCS) install
|
||||
$(MAKE) -C "$(BUILD_DIR)" -s -j $(NPROCS) install
|
||||
@echo
|
||||
@echo edit build configuration with: "$(BUILD_DIR)/CMakeCache.txt" run make again to rebuild.
|
||||
@echo Blender successfully built, run from: $(BLENDER_BIN)
|
||||
@echo blender installed, run from: "$(BUILD_DIR)/bin/blender"
|
||||
@echo
|
||||
|
||||
debug: all
|
||||
@@ -331,53 +138,89 @@ lite: all
|
||||
cycles: all
|
||||
headless: all
|
||||
bpy: all
|
||||
developer: all
|
||||
ninja: all
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Build dependencies
|
||||
DEPS_TARGET = install
|
||||
ifneq "$(findstring clean, $(MAKECMDGOALS))" ""
|
||||
DEPS_TARGET = clean
|
||||
endif
|
||||
|
||||
deps: .FORCE
|
||||
@echo
|
||||
@echo Configuring dependencies in \"$(DEPS_BUILD_DIR)\"
|
||||
|
||||
@cmake -H"$(DEPS_SOURCE_DIR)" \
|
||||
-B"$(DEPS_BUILD_DIR)" \
|
||||
-DHARVEST_TARGET=$(DEPS_INSTALL_DIR)
|
||||
|
||||
@echo
|
||||
@echo Building dependencies ...
|
||||
$(DEPS_BUILD_COMMAND) -C "$(DEPS_BUILD_DIR)" -j $(NPROCS) $(DEPS_TARGET)
|
||||
@echo
|
||||
@echo Dependencies successfully built and installed to $(DEPS_INSTALL_DIR).
|
||||
@echo
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Configuration (save some cd'ing around)
|
||||
config: .FORCE
|
||||
config: FORCE
|
||||
$(CMAKE_CONFIG_TOOL) "$(BUILD_DIR)"
|
||||
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Help for build targets
|
||||
export HELP_TEXT
|
||||
help: .FORCE
|
||||
@echo "$$HELP_TEXT"
|
||||
help: FORCE
|
||||
@echo ""
|
||||
@echo "Convenience targets provided for building blender, (multiple at once can be used)"
|
||||
@echo " * debug - build a debug binary"
|
||||
@echo " * full - enable all supported dependencies & options"
|
||||
@echo " * lite - disable non essential features for a smaller binary and faster build"
|
||||
@echo " * headless - build without an interface (renderfarm or server automation)"
|
||||
@echo " * cycles - build Cycles standalone only, without Blender"
|
||||
@echo " * bpy - build as a python module which can be loaded from python directly"
|
||||
@echo ""
|
||||
@echo " * config - run cmake configuration tool to set build options"
|
||||
@echo ""
|
||||
@echo " Note, passing the argument 'BUILD_DIR=path' when calling make will override the default build dir."
|
||||
@echo " Note, passing the argument 'BUILD_CMAKE_ARGS=args' lets you add cmake arguments."
|
||||
@echo ""
|
||||
@echo ""
|
||||
@echo "Project Files for IDE's"
|
||||
@echo " * project_qtcreator - QtCreator Project Files"
|
||||
@echo " * project_netbeans - NetBeans Project Files"
|
||||
@echo " * project_eclipse - Eclipse CDT4 Project Files"
|
||||
@echo ""
|
||||
@echo "Package Targets"
|
||||
@echo " * package_debian - build a debian package"
|
||||
@echo " * package_pacman - build an arch linux pacman package"
|
||||
@echo " * package_archive - build an archive package"
|
||||
@echo ""
|
||||
@echo "Testing Targets (not associated with building blender)"
|
||||
@echo " * test - run ctest, currently tests import/export, operator execution and that python modules load"
|
||||
@echo " * test_cmake - runs our own cmake file checker which detects errors in the cmake file list definitions"
|
||||
@echo " * test_pep8 - checks all python script are pep8 which are tagged to use the stricter formatting"
|
||||
@echo " * test_deprecated - checks for deprecation tags in our code which may need to be removed"
|
||||
@echo " * test_style_c - checks C/C++ conforms with blenders style guide: http://wiki.blender.org/index.php/Dev:Doc/CodeStyle"
|
||||
@echo " * test_style_c_qtc - same as test_style but outputs QtCreator tasks format"
|
||||
@echo " * test_style_osl - checks OpenShadingLanguage conforms with blenders style guide: http://wiki.blender.org/index.php/Dev:Doc/CodeStyle"
|
||||
@echo " * test_style_osl_qtc - checks OpenShadingLanguage conforms with blenders style guide: http://wiki.blender.org/index.php/Dev:Doc/CodeStyle"
|
||||
@echo ""
|
||||
@echo "Static Source Code Checking (not associated with building blender)"
|
||||
@echo " * check_cppcheck - run blender source through cppcheck (C & C++)"
|
||||
@echo " * check_clang_array - run blender source through clang array checking script (C & C++)"
|
||||
@echo " * check_splint - run blenders source through splint (C only)"
|
||||
@echo " * check_sparse - run blenders source through sparse (C only)"
|
||||
@echo " * check_smatch - run blenders source through smatch (C only)"
|
||||
@echo " * check_spelling_c - check for spelling errors (C/C++ only)"
|
||||
@echo " * check_spelling_c_qtc - same as check_spelling_c but outputs QtCreator tasks format"
|
||||
@echo " * check_spelling_osl - check for spelling errors (OSL only)"
|
||||
@echo " * check_spelling_py - check for spelling errors (Python only)"
|
||||
@echo " * check_descriptions - check for duplicate/invalid descriptions"
|
||||
@echo ""
|
||||
@echo "Utilities (not associated with building blender)"
|
||||
@echo " * icons - updates PNG icons from SVG files."
|
||||
@echo " * tgz - create a compressed archive of the source code."
|
||||
@echo " * update - updates git and all submodules"
|
||||
@echo ""
|
||||
@echo "Documentation Targets (not associated with building blender)"
|
||||
@echo " * doc_py - generate sphinx python api docs"
|
||||
@echo " * doc_doxy - generate doxygen C/C++ docs"
|
||||
@echo " * doc_dna - generate blender file format reference"
|
||||
@echo " * doc_man - generate manpage"
|
||||
@echo ""
|
||||
@echo "Information"
|
||||
@echo " * help - this help message"
|
||||
@echo " * help_features - show a list of optional features when building"
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Packages
|
||||
#
|
||||
package_debian: .FORCE
|
||||
package_debian: FORCE
|
||||
cd build_files/package_spec ; DEB_BUILD_OPTIONS="parallel=$(NPROCS)" sh ./build_debian.sh
|
||||
|
||||
package_pacman: .FORCE
|
||||
package_pacman: FORCE
|
||||
cd build_files/package_spec/pacman ; MAKEFLAGS="-j$(NPROCS)" makepkg
|
||||
|
||||
package_archive: .FORCE
|
||||
package_archive: FORCE
|
||||
make -C "$(BUILD_DIR)" -s package_archive
|
||||
@echo archive in "$(BUILD_DIR)/release"
|
||||
|
||||
@@ -385,35 +228,35 @@ package_archive: .FORCE
|
||||
# -----------------------------------------------------------------------------
|
||||
# Tests
|
||||
#
|
||||
test: .FORCE
|
||||
$(PYTHON) ./build_files/utils/make_test.py "$(BUILD_DIR)"
|
||||
test: FORCE
|
||||
cd $(BUILD_DIR) ; ctest . --output-on-failure
|
||||
|
||||
# run pep8 check check on scripts we distribute.
|
||||
test_pep8: .FORCE
|
||||
$(PYTHON) tests/python/pep8.py > test_pep8.log 2>&1
|
||||
test_pep8: FORCE
|
||||
python3 tests/python/pep8.py > test_pep8.log 2>&1
|
||||
@echo "written: test_pep8.log"
|
||||
|
||||
# run some checks on our cmakefiles.
|
||||
test_cmake: .FORCE
|
||||
$(PYTHON) build_files/cmake/cmake_consistency_check.py > test_cmake_consistency.log 2>&1
|
||||
test_cmake: FORCE
|
||||
python3 build_files/cmake/cmake_consistency_check.py > test_cmake_consistency.log 2>&1
|
||||
@echo "written: test_cmake_consistency.log"
|
||||
|
||||
# run deprecation tests, see if we have anything to remove.
|
||||
test_deprecated: .FORCE
|
||||
$(PYTHON) tests/check_deprecated.py
|
||||
test_deprecated: FORCE
|
||||
python3 tests/check_deprecated.py
|
||||
|
||||
test_style_c: .FORCE
|
||||
test_style_c: FORCE
|
||||
# run our own checks on C/C++ style
|
||||
PYTHONIOENCODING=utf_8 $(PYTHON) \
|
||||
PYTHONIOENCODING=utf_8 python3 \
|
||||
"$(BLENDER_DIR)/source/tools/check_source/check_style_c.py" \
|
||||
"$(BLENDER_DIR)/source/blender" \
|
||||
"$(BLENDER_DIR)/source/creator" \
|
||||
--no-length-check
|
||||
|
||||
test_style_c_qtc: .FORCE
|
||||
test_style_c_qtc: FORCE
|
||||
# run our own checks on C/C++ style
|
||||
USE_QTC_TASK=1 \
|
||||
PYTHONIOENCODING=utf_8 $(PYTHON) \
|
||||
PYTHONIOENCODING=utf_8 python3 \
|
||||
"$(BLENDER_DIR)/source/tools/check_source/check_style_c.py" \
|
||||
"$(BLENDER_DIR)/source/blender" \
|
||||
"$(BLENDER_DIR)/source/creator" \
|
||||
@@ -423,18 +266,18 @@ test_style_c_qtc: .FORCE
|
||||
@echo "written: test_style.tasks"
|
||||
|
||||
|
||||
test_style_osl: .FORCE
|
||||
test_style_osl: FORCE
|
||||
# run our own checks on C/C++ style
|
||||
PYTHONIOENCODING=utf_8 $(PYTHON) \
|
||||
PYTHONIOENCODING=utf_8 python3 \
|
||||
"$(BLENDER_DIR)/source/tools/check_source/check_style_c.py" \
|
||||
"$(BLENDER_DIR)/intern/cycles/kernel/shaders" \
|
||||
"$(BLENDER_DIR)/release/scripts/templates_osl"
|
||||
|
||||
|
||||
test_style_osl_qtc: .FORCE
|
||||
test_style_osl_qtc: FORCE
|
||||
# run our own checks on C/C++ style
|
||||
USE_QTC_TASK=1 \
|
||||
PYTHONIOENCODING=utf_8 $(PYTHON) \
|
||||
PYTHONIOENCODING=utf_8 python3 \
|
||||
"$(BLENDER_DIR)/source/tools/check_source/check_style_c.py" \
|
||||
"$(BLENDER_DIR)/intern/cycles/kernel/shaders" \
|
||||
"$(BLENDER_DIR)/release/scripts/templates_osl" \
|
||||
@@ -446,13 +289,13 @@ test_style_osl_qtc: .FORCE
|
||||
# Project Files
|
||||
#
|
||||
|
||||
project_qtcreator: .FORCE
|
||||
$(PYTHON) build_files/cmake/cmake_qtcreator_project.py --build-dir "$(BUILD_DIR)"
|
||||
project_qtcreator: FORCE
|
||||
python3 build_files/cmake/cmake_qtcreator_project.py "$(BUILD_DIR)"
|
||||
|
||||
project_netbeans: .FORCE
|
||||
$(PYTHON) build_files/cmake/cmake_netbeans_project.py "$(BUILD_DIR)"
|
||||
project_netbeans: FORCE
|
||||
python3 build_files/cmake/cmake_netbeans_project.py "$(BUILD_DIR)"
|
||||
|
||||
project_eclipse: .FORCE
|
||||
project_eclipse: FORCE
|
||||
cmake -G"Eclipse CDT4 - Unix Makefiles" -H"$(BLENDER_DIR)" -B"$(BUILD_DIR)"
|
||||
|
||||
|
||||
@@ -460,51 +303,51 @@ project_eclipse: .FORCE
|
||||
# Static Checking
|
||||
#
|
||||
|
||||
check_cppcheck: .FORCE
|
||||
check_cppcheck: FORCE
|
||||
$(CMAKE_CONFIG)
|
||||
cd "$(BUILD_DIR)" ; \
|
||||
$(PYTHON) "$(BLENDER_DIR)/build_files/cmake/cmake_static_check_cppcheck.py" 2> \
|
||||
python3 "$(BLENDER_DIR)/build_files/cmake/cmake_static_check_cppcheck.py" 2> \
|
||||
"$(BLENDER_DIR)/check_cppcheck.txt"
|
||||
@echo "written: check_cppcheck.txt"
|
||||
|
||||
check_clang_array: .FORCE
|
||||
check_clang_array: FORCE
|
||||
$(CMAKE_CONFIG)
|
||||
cd "$(BUILD_DIR)" ; \
|
||||
$(PYTHON) "$(BLENDER_DIR)/build_files/cmake/cmake_static_check_clang_array.py"
|
||||
python3 "$(BLENDER_DIR)/build_files/cmake/cmake_static_check_clang_array.py"
|
||||
|
||||
check_splint: .FORCE
|
||||
check_splint: FORCE
|
||||
$(CMAKE_CONFIG)
|
||||
cd "$(BUILD_DIR)" ; \
|
||||
$(PYTHON) "$(BLENDER_DIR)/build_files/cmake/cmake_static_check_splint.py"
|
||||
python3 "$(BLENDER_DIR)/build_files/cmake/cmake_static_check_splint.py"
|
||||
|
||||
check_sparse: .FORCE
|
||||
check_sparse: FORCE
|
||||
$(CMAKE_CONFIG)
|
||||
cd "$(BUILD_DIR)" ; \
|
||||
$(PYTHON) "$(BLENDER_DIR)/build_files/cmake/cmake_static_check_sparse.py"
|
||||
python3 "$(BLENDER_DIR)/build_files/cmake/cmake_static_check_sparse.py"
|
||||
|
||||
check_smatch: .FORCE
|
||||
check_smatch: FORCE
|
||||
$(CMAKE_CONFIG)
|
||||
cd "$(BUILD_DIR)" ; \
|
||||
$(PYTHON) "$(BLENDER_DIR)/build_files/cmake/cmake_static_check_smatch.py"
|
||||
python3 "$(BLENDER_DIR)/build_files/cmake/cmake_static_check_smatch.py"
|
||||
|
||||
check_spelling_py: .FORCE
|
||||
check_spelling_py: FORCE
|
||||
cd "$(BUILD_DIR)" ; \
|
||||
PYTHONIOENCODING=utf_8 $(PYTHON) \
|
||||
PYTHONIOENCODING=utf_8 python3 \
|
||||
"$(BLENDER_DIR)/source/tools/check_source/check_spelling.py" \
|
||||
"$(BLENDER_DIR)/release/scripts"
|
||||
|
||||
check_spelling_c: .FORCE
|
||||
check_spelling_c: FORCE
|
||||
cd "$(BUILD_DIR)" ; \
|
||||
PYTHONIOENCODING=utf_8 $(PYTHON) \
|
||||
PYTHONIOENCODING=utf_8 python3 \
|
||||
"$(BLENDER_DIR)/source/tools/check_source/check_spelling.py" \
|
||||
"$(BLENDER_DIR)/source" \
|
||||
"$(BLENDER_DIR)/intern/cycles" \
|
||||
"$(BLENDER_DIR)/intern/guardedalloc" \
|
||||
"$(BLENDER_DIR)/intern/ghost" \
|
||||
|
||||
check_spelling_c_qtc: .FORCE
|
||||
check_spelling_c_qtc: FORCE
|
||||
cd "$(BUILD_DIR)" ; USE_QTC_TASK=1 \
|
||||
PYTHONIOENCODING=utf_8 $(PYTHON) \
|
||||
PYTHONIOENCODING=utf_8 python3 \
|
||||
"$(BLENDER_DIR)/source/tools/check_source/check_spelling.py" \
|
||||
"$(BLENDER_DIR)/source" \
|
||||
"$(BLENDER_DIR)/intern/cycles" \
|
||||
@@ -513,40 +356,33 @@ check_spelling_c_qtc: .FORCE
|
||||
> \
|
||||
"$(BLENDER_DIR)/check_spelling_c.tasks"
|
||||
|
||||
check_spelling_osl: .FORCE
|
||||
check_spelling_osl: FORCE
|
||||
cd "$(BUILD_DIR)" ;\
|
||||
PYTHONIOENCODING=utf_8 $(PYTHON) \
|
||||
PYTHONIOENCODING=utf_8 python3 \
|
||||
"$(BLENDER_DIR)/source/tools/check_source/check_spelling.py" \
|
||||
"$(BLENDER_DIR)/intern/cycles/kernel/shaders"
|
||||
|
||||
check_descriptions: .FORCE
|
||||
$(BLENDER_BIN) --background -noaudio --factory-startup --python \
|
||||
check_descriptions: FORCE
|
||||
"$(BUILD_DIR)/bin/blender" --background -noaudio --factory-startup --python \
|
||||
"$(BLENDER_DIR)/source/tools/check_source/check_descriptions.py"
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Utilities
|
||||
#
|
||||
|
||||
source_archive: .FORCE
|
||||
./build_files/utils/make_source_archive.sh
|
||||
tgz: FORCE
|
||||
./build_files/utils/build_tgz.sh
|
||||
|
||||
INKSCAPE_BIN?="inkscape"
|
||||
icons: .FORCE
|
||||
BLENDER_BIN=$(BLENDER_BIN) INKSCAPE_BIN=$(INKSCAPE_BIN) \
|
||||
"$(BLENDER_DIR)/release/datafiles/blender_icons_update.py"
|
||||
BLENDER_BIN=$(BLENDER_BIN) INKSCAPE_BIN=$(INKSCAPE_BIN) \
|
||||
"$(BLENDER_DIR)/release/datafiles/prvicons_update.py"
|
||||
icons: FORCE
|
||||
"$(BLENDER_DIR)/release/datafiles/blender_icons_update.py"
|
||||
"$(BLENDER_DIR)/release/datafiles/prvicons_update.py"
|
||||
|
||||
icons_geom: .FORCE
|
||||
BLENDER_BIN=$(BLENDER_BIN) \
|
||||
"$(BLENDER_DIR)/release/datafiles/blender_icons_geom_update.py"
|
||||
|
||||
update: .FORCE
|
||||
$(PYTHON) ./build_files/utils/make_update.py
|
||||
|
||||
format: .FORCE
|
||||
PATH="../lib/${OS_NCASE}_${CPU}/llvm/bin/:../lib/${OS_NCASE}_centos7_${CPU}/llvm/bin/:../lib/${OS_NCASE}/llvm/bin/:$(PATH)" \
|
||||
$(PYTHON) source/tools/utils_maintenance/clang_format_paths.py $(PATHS)
|
||||
update: FORCE
|
||||
if [ -d "../lib" ]; then \
|
||||
svn update ../lib/* ; \
|
||||
fi
|
||||
git pull --rebase
|
||||
git submodule foreach git pull --rebase origin master
|
||||
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
@@ -554,31 +390,36 @@ format: .FORCE
|
||||
#
|
||||
|
||||
# Simple version of ./doc/python_api/sphinx_doc_gen.sh with no PDF generation.
|
||||
doc_py: .FORCE
|
||||
ASAN_OPTIONS=halt_on_error=0 \
|
||||
$(BLENDER_BIN) --background -noaudio --factory-startup \
|
||||
--python doc/python_api/sphinx_doc_gen.py
|
||||
doc_py: FORCE
|
||||
"$(BUILD_DIR)/bin/blender" --background -noaudio --factory-startup --python doc/python_api/sphinx_doc_gen.py
|
||||
cd doc/python_api ; sphinx-build -b html sphinx-in sphinx-out
|
||||
@echo "docs written into: '$(BLENDER_DIR)/doc/python_api/sphinx-out/index.html'"
|
||||
@echo "docs written into: '$(BLENDER_DIR)/doc/python_api/sphinx-out/contents.html'"
|
||||
|
||||
doc_doxy: .FORCE
|
||||
doc_doxy: FORCE
|
||||
cd doc/doxygen; doxygen Doxyfile
|
||||
@echo "docs written into: '$(BLENDER_DIR)/doc/doxygen/html/index.html'"
|
||||
|
||||
doc_dna: .FORCE
|
||||
$(BLENDER_BIN) --background -noaudio --factory-startup \
|
||||
--python doc/blender_file_format/BlendFileDnaExporter_25.py
|
||||
doc_dna: FORCE
|
||||
"$(BUILD_DIR)/bin/blender" --background -noaudio --factory-startup --python doc/blender_file_format/BlendFileDnaExporter_25.py
|
||||
@echo "docs written into: '$(BLENDER_DIR)/doc/blender_file_format/dna.html'"
|
||||
|
||||
doc_man: .FORCE
|
||||
$(PYTHON) doc/manpage/blender.1.py $(BLENDER_BIN) blender.1
|
||||
doc_man: FORCE
|
||||
python3 doc/manpage/blender.1.py "$(BUILD_DIR)/bin/blender"
|
||||
|
||||
help_features: .FORCE
|
||||
@$(PYTHON) "$(BLENDER_DIR)/build_files/cmake/cmake_print_build_options.py" $(BLENDER_DIR)"/CMakeLists.txt"
|
||||
help_features: FORCE
|
||||
@python3 -c \
|
||||
"import re; \
|
||||
print('\n'.join([ \
|
||||
w for l in open('"$(BLENDER_DIR)"/CMakeLists.txt', 'r').readlines() \
|
||||
if not l.lstrip().startswith('#') \
|
||||
for w in (re.sub(\
|
||||
r'.*\boption\s*\(\s*(WITH_[a-zA-Z0-9_]+)\s+(\".*\")\s*.*', r'\g<1> - \g<2>', l).strip('() \n'),) \
|
||||
if w.startswith('WITH_')]))" | uniq
|
||||
|
||||
clean: .FORCE
|
||||
$(BUILD_COMMAND) -C "$(BUILD_DIR)" clean
|
||||
|
||||
clean: FORCE
|
||||
$(MAKE) -C "$(BUILD_DIR)" clean
|
||||
|
||||
.PHONY: all
|
||||
|
||||
.FORCE:
|
||||
FORCE:
|
||||
|
1370
SConstruct
Normal file
1370
SConstruct
Normal file
File diff suppressed because it is too large
Load Diff
@@ -1,164 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
####################################################################################################
|
||||
#
|
||||
# This is a build system used by platform maintainers to build library dependencies on
|
||||
# Windows, macOS and Linux.
|
||||
#
|
||||
# For users building Blender, we recommend using the precompiled libraries from lib/ on
|
||||
# Windows and macOS, and install_deps.sh on Linux.
|
||||
#
|
||||
# WINDOWS USAGE:
|
||||
# Don't call this cmake file yourself, use build_deps.cmd
|
||||
# build_deps 2013 x64 / build_deps 2013 x86
|
||||
# build_deps 2015 x64 / build_deps 2015 x86
|
||||
#
|
||||
# MAC OS X USAGE:
|
||||
# Install with homebrew: brew install cmake autoconf automake libtool yasm nasm
|
||||
# Run "make deps" from main Blender directory
|
||||
#
|
||||
# LINUX USAGE:
|
||||
# Install compiler cmake autoconf automake libtool yasm nasm tcl
|
||||
# Run "make deps" from main Blender directory
|
||||
#
|
||||
####################################################################################################
|
||||
|
||||
project("BlenderDependencies")
|
||||
cmake_minimum_required(VERSION 3.5)
|
||||
|
||||
include(ExternalProject)
|
||||
include(cmake/check_software.cmake)
|
||||
include(cmake/options.cmake)
|
||||
include(cmake/versions.cmake)
|
||||
|
||||
if(ENABLE_MINGW64)
|
||||
if("${CMAKE_SIZEOF_VOID_P}" EQUAL "8")
|
||||
include(cmake/setup_mingw64.cmake)
|
||||
else()
|
||||
include(cmake/setup_mingw32.cmake)
|
||||
endif()
|
||||
else()
|
||||
set(mingw_LIBDIR ${LIBDIR})
|
||||
endif()
|
||||
|
||||
include(cmake/zlib.cmake)
|
||||
include(cmake/openal.cmake)
|
||||
include(cmake/png.cmake)
|
||||
include(cmake/jpeg.cmake)
|
||||
include(cmake/boost.cmake)
|
||||
include(cmake/blosc.cmake)
|
||||
include(cmake/pthreads.cmake)
|
||||
include(cmake/openexr.cmake)
|
||||
include(cmake/freetype.cmake)
|
||||
include(cmake/freeglut.cmake)
|
||||
include(cmake/glew.cmake)
|
||||
include(cmake/alembic.cmake)
|
||||
include(cmake/glfw.cmake)
|
||||
include(cmake/clew.cmake)
|
||||
include(cmake/cuew.cmake)
|
||||
include(cmake/opensubdiv.cmake)
|
||||
include(cmake/sdl.cmake)
|
||||
include(cmake/opencollada.cmake)
|
||||
include(cmake/opencolorio.cmake)
|
||||
include(cmake/llvm.cmake)
|
||||
include(cmake/clang.cmake)
|
||||
if(APPLE)
|
||||
include(cmake/openmp.cmake)
|
||||
endif()
|
||||
include(cmake/openimageio.cmake)
|
||||
include(cmake/tiff.cmake)
|
||||
include(cmake/flexbison.cmake)
|
||||
include(cmake/osl.cmake)
|
||||
include(cmake/tbb.cmake)
|
||||
include(cmake/openvdb.cmake)
|
||||
include(cmake/python.cmake)
|
||||
include(cmake/python_site_packages.cmake)
|
||||
include(cmake/package_python.cmake)
|
||||
include(cmake/numpy.cmake)
|
||||
include(cmake/usd.cmake)
|
||||
if(UNIX)
|
||||
# Rely on PugiXML compiled with OpenImageIO
|
||||
else()
|
||||
include(cmake/pugixml.cmake)
|
||||
endif()
|
||||
include(cmake/openimagedenoise.cmake)
|
||||
include(cmake/embree.cmake)
|
||||
include(cmake/xr_openxr.cmake)
|
||||
|
||||
if(WITH_WEBP)
|
||||
include(cmake/webp.cmake)
|
||||
endif()
|
||||
|
||||
if(WIN32)
|
||||
# HMD branch deps
|
||||
include(cmake/hidapi.cmake)
|
||||
# OCIO deps
|
||||
include(cmake/tinyxml.cmake)
|
||||
include(cmake/yamlcpp.cmake)
|
||||
# LCMS is an OCIO dep, but only if you build the apps, leaving it here for convenience
|
||||
# include(cmake/lcms.cmake)
|
||||
|
||||
endif()
|
||||
|
||||
if(NOT WIN32 OR ENABLE_MINGW64)
|
||||
include(cmake/openjpeg.cmake)
|
||||
if(NOT WIN32 OR BUILD_MODE STREQUAL Release)
|
||||
if(WIN32)
|
||||
include(cmake/zlib_mingw.cmake)
|
||||
endif()
|
||||
include(cmake/lame.cmake)
|
||||
include(cmake/ogg.cmake)
|
||||
include(cmake/vorbis.cmake)
|
||||
include(cmake/theora.cmake)
|
||||
include(cmake/opus.cmake)
|
||||
include(cmake/vpx.cmake)
|
||||
include(cmake/x264.cmake)
|
||||
include(cmake/xvidcore.cmake)
|
||||
include(cmake/faad.cmake)
|
||||
include(cmake/ffmpeg.cmake)
|
||||
include(cmake/fftw.cmake)
|
||||
include(cmake/sndfile.cmake)
|
||||
if(WIN32)
|
||||
include(cmake/iconv.cmake)
|
||||
endif()
|
||||
if(UNIX)
|
||||
include(cmake/flac.cmake)
|
||||
include(cmake/xml2.cmake)
|
||||
if(NOT APPLE)
|
||||
include(cmake/spnav.cmake)
|
||||
include(cmake/jemalloc.cmake)
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(UNIX)
|
||||
include(cmake/bzip2.cmake)
|
||||
include(cmake/ffi.cmake)
|
||||
include(cmake/lzma.cmake)
|
||||
include(cmake/ssl.cmake)
|
||||
include(cmake/sqlite.cmake)
|
||||
endif()
|
||||
|
||||
if(UNIX AND NOT APPLE)
|
||||
include(cmake/libglu.cmake)
|
||||
include(cmake/mesa.cmake)
|
||||
endif()
|
||||
|
||||
include(cmake/harvest.cmake)
|
@@ -1,98 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(ALEMBIC_HDF5)
|
||||
set(ALEMBIC_HDF5_HL)
|
||||
# in debug mode we do not build HDF5_hdf5_hl_LIBRARY which makes cmake really
|
||||
# unhappy, stub it with the debug mode lib. it's not linking it in at this
|
||||
# point in time anyhow
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
set(ALEMBIC_HDF5_HL -DHDF5_hdf5_hl_LIBRARY=${LIBDIR}/hdf5/lib/libhdf5_hl_D.${LIBEXT})
|
||||
endif()
|
||||
endif()
|
||||
|
||||
set(ALEMBIC_EXTRA_ARGS
|
||||
-DBUILDSTATIC=ON
|
||||
-DLINKSTATIC=ON
|
||||
-DALEMBIC_LIB_USES_BOOST=ON
|
||||
-DBoost_COMPILER:STRING=${BOOST_COMPILER_STRING}
|
||||
-DBoost_USE_MULTITHREADED=ON
|
||||
-DUSE_STATIC_BOOST=On
|
||||
-DBoost_USE_STATIC_LIBS=ON
|
||||
-DBoost_USE_STATIC_RUNTIME=OFF
|
||||
-DBoost_DEBUG=ON
|
||||
-DBOOST_ROOT=${LIBDIR}/boost
|
||||
-DBoost_NO_SYSTEM_PATHS=ON
|
||||
-DILMBASE_ROOT=${LIBDIR}/openexr
|
||||
-DALEMBIC_ILMBASE_INCLUDE_DIRECTORY=${LIBDIR}/openexr/include/OpenEXR
|
||||
-DALEMBIC_ILMBASE_HALF_LIB=${LIBDIR}/openexr/lib/${LIBPREFIX}Half${OPENEXR_VERSION_POSTFIX}${LIBEXT}
|
||||
-DALEMBIC_ILMBASE_IMATH_LIB=${LIBDIR}/openexr/lib/${LIBPREFIX}Imath${OPENEXR_VERSION_POSTFIX}${LIBEXT}
|
||||
-DALEMBIC_ILMBASE_ILMTHREAD_LIB=${LIBDIR}/openexr/lib/${LIBPREFIX}IlmThread${OPENEXR_VERSION_POSTFIX}${LIBEXT}
|
||||
-DALEMBIC_ILMBASE_IEX_LIB=${LIBDIR}/openexr/lib/${LIBPREFIX}Iex${OPENEXR_VERSION_POSTFIX}${LIBEXT}
|
||||
-DALEMBIC_ILMBASE_IEXMATH_LIB=${LIBDIR}/openexr/lib/${LIBPREFIX}IexMath${OPENEXR_VERSION_POSTFIX}${LIBEXT}
|
||||
-DUSE_PYILMBASE=0
|
||||
-DUSE_PYALEMBIC=0
|
||||
-DUSE_ARNOLD=0
|
||||
-DUSE_MAYA=0
|
||||
-DUSE_PRMAN=0
|
||||
-DUSE_HDF5=Off
|
||||
-DUSE_STATIC_HDF5=Off
|
||||
-DHDF5_ROOT=${LIBDIR}/hdf5
|
||||
-DUSE_TESTS=Off
|
||||
-DALEMBIC_NO_OPENGL=1
|
||||
-DUSE_BINARIES=ON
|
||||
-DALEMBIC_ILMBASE_LINK_STATIC=On
|
||||
-DALEMBIC_SHARED_LIBS=OFF
|
||||
-DGLUT_INCLUDE_DIR=""
|
||||
-DZLIB_LIBRARY=${LIBDIR}/zlib/lib/${ZLIB_LIBRARY}
|
||||
-DZLIB_INCLUDE_DIR=${LIBDIR}/zlib/include/
|
||||
${ALEMBIC_HDF5_HL}
|
||||
)
|
||||
|
||||
ExternalProject_Add(external_alembic
|
||||
URL ${ALEMBIC_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${ALEMBIC_MD5}
|
||||
PREFIX ${BUILD_DIR}/alembic
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/alembic -Wno-dev ${DEFAULT_CMAKE_FLAGS} ${ALEMBIC_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/alembic
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_alembic after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/alembic ${HARVEST_TARGET}/alembic
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
ExternalProject_Add_Step(external_alembic after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/alembic/lib/alembic.lib ${HARVEST_TARGET}/alembic/lib/alembic_d.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
||||
|
||||
add_dependencies(
|
||||
external_alembic
|
||||
external_boost
|
||||
external_zlib
|
||||
external_openexr
|
||||
)
|
@@ -1,73 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(BLOSC_EXTRA_ARGS
|
||||
-DZLIB_INCLUDE_DIR=${LIBDIR}/zlib/include/
|
||||
-DZLIB_LIBRARY=${LIBDIR}/zlib/lib/${ZLIB_LIBRARY}
|
||||
-DBUILD_TESTS=OFF
|
||||
-DBUILD_BENCHMARKS=OFF
|
||||
-DCMAKE_DEBUG_POSTFIX=_d
|
||||
-DThreads_FOUND=1
|
||||
-DPTHREAD_LIBS=${LIBDIR}/pthreads/lib/pthreadVC3.lib
|
||||
-DPTHREAD_INCLUDE_DIR=${LIBDIR}/pthreads/inc
|
||||
-DDEACTIVATE_SNAPPY=ON
|
||||
-DCMAKE_POSITION_INDEPENDENT_CODE=ON
|
||||
)
|
||||
|
||||
# Prevent blosc from including it's own local copy of zlib in the object file
|
||||
# and cause linker errors with everybody else.
|
||||
set(BLOSC_EXTRA_ARGS ${BLOSC_EXTRA_ARGS}
|
||||
-DPREFER_EXTERNAL_ZLIB=ON
|
||||
)
|
||||
|
||||
ExternalProject_Add(external_blosc
|
||||
URL ${BLOSC_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${BLOSC_HASH}
|
||||
PREFIX ${BUILD_DIR}/blosc
|
||||
PATCH_COMMAND ${PATCH_CMD} --verbose -p 1 -N -d ${BUILD_DIR}/blosc/src/external_blosc < ${PATCH_DIR}/blosc.diff
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/blosc ${DEFAULT_CMAKE_FLAGS} ${BLOSC_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/blosc
|
||||
)
|
||||
|
||||
add_dependencies(
|
||||
external_blosc
|
||||
external_zlib
|
||||
)
|
||||
if(WIN32)
|
||||
add_dependencies(
|
||||
external_blosc
|
||||
external_pthreads
|
||||
)
|
||||
endif()
|
||||
|
||||
if(WIN32)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_blosc after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/blosc/lib/libblosc.lib ${HARVEST_TARGET}/blosc/lib/libblosc.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/blosc/include/ ${HARVEST_TARGET}/blosc/include/
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
ExternalProject_Add_Step(external_blosc after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/blosc/lib/libblosc_d.lib ${HARVEST_TARGET}/blosc/lib/libblosc_d.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
endif()
|
@@ -1,94 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(BOOST_ADDRESS_MODEL 64)
|
||||
|
||||
if(WIN32)
|
||||
if("${CMAKE_SIZEOF_VOID_P}" EQUAL "8")
|
||||
set(PYTHON_ARCH x64)
|
||||
set(PYTHON_ARCH2 win-AMD64)
|
||||
set(PYTHON_OUTPUTDIR ${BUILD_DIR}/python/src/external_python/pcbuild/amd64/)
|
||||
else()
|
||||
set(PYTHON_ARCH x86)
|
||||
set(PYTHON_ARCH2 win32)
|
||||
set(PYTHON_OUTPUTDIR ${BUILD_DIR}/python/src/external_python/pcbuild/win32/)
|
||||
set(BOOST_ADDRESS_MODEL 32)
|
||||
endif()
|
||||
|
||||
set(BOOST_TOOLSET toolset=msvc-14.1)
|
||||
set(BOOST_COMPILER_STRING -vc141)
|
||||
|
||||
set(BOOST_CONFIGURE_COMMAND bootstrap.bat)
|
||||
set(BOOST_BUILD_COMMAND bjam)
|
||||
set(BOOST_BUILD_OPTIONS runtime-link=shared )
|
||||
set(BOOST_HARVEST_CMD ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/boost/lib/ ${HARVEST_TARGET}/boost/lib/ )
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
set(BOOST_HARVEST_CMD ${BOOST_HARVEST_CMD} && ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/boost/include/boost-${BOOST_VERSION_NODOTS_SHORT}/ ${HARVEST_TARGET}/boost/include/)
|
||||
endif()
|
||||
|
||||
elseif(APPLE)
|
||||
set(BOOST_CONFIGURE_COMMAND ./bootstrap.sh)
|
||||
set(BOOST_BUILD_COMMAND ./b2)
|
||||
set(BOOST_BUILD_OPTIONS toolset=darwin cxxflags=${PLATFORM_CXXFLAGS} linkflags=${PLATFORM_LDFLAGS} visibility=global --disable-icu boost.locale.icu=off)
|
||||
set(BOOST_HARVEST_CMD echo .)
|
||||
set(BOOST_PATCH_COMMAND echo .)
|
||||
else()
|
||||
set(BOOST_HARVEST_CMD echo .)
|
||||
set(BOOST_CONFIGURE_COMMAND ./bootstrap.sh)
|
||||
set(BOOST_BUILD_COMMAND ./b2)
|
||||
set(BOOST_BUILD_OPTIONS cxxflags=${PLATFORM_CXXFLAGS} --disable-icu boost.locale.icu=off)
|
||||
set(BOOST_PATCH_COMMAND echo .)
|
||||
if("${CMAKE_SIZEOF_VOID_P}" EQUAL "8")
|
||||
set(BOOST_ADDRESS_MODEL 64)
|
||||
else()
|
||||
set(BOOST_ADDRESS_MODEL 32)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
set(BOOST_OPTIONS
|
||||
--with-filesystem
|
||||
--with-locale
|
||||
--with-thread
|
||||
--with-regex
|
||||
--with-system
|
||||
--with-date_time
|
||||
--with-wave
|
||||
--with-atomic
|
||||
--with-serialization
|
||||
--with-program_options
|
||||
--with-iostreams
|
||||
-sNO_BZIP2=1
|
||||
-sNO_LZMA=1
|
||||
-sNO_ZSTD=1
|
||||
${BOOST_TOOLSET}
|
||||
)
|
||||
|
||||
string(TOLOWER ${BUILD_MODE} BOOST_BUILD_TYPE)
|
||||
|
||||
ExternalProject_Add(external_boost
|
||||
URL ${BOOST_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${BOOST_HASH}
|
||||
PREFIX ${BUILD_DIR}/boost
|
||||
UPDATE_COMMAND ""
|
||||
PATCH_COMMAND ${BOOST_PATCH_COMMAND}
|
||||
CONFIGURE_COMMAND ${BOOST_CONFIGURE_COMMAND}
|
||||
BUILD_COMMAND ${BOOST_BUILD_COMMAND} ${BOOST_BUILD_OPTIONS} -j${MAKE_THREADS} architecture=x86 address-model=${BOOST_ADDRESS_MODEL} link=static threading=multi ${BOOST_OPTIONS} --prefix=${LIBDIR}/boost install
|
||||
BUILD_IN_SOURCE 1
|
||||
INSTALL_COMMAND "${BOOST_HARVEST_CMD}"
|
||||
)
|
@@ -1,39 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(BZIP2_PREFIX "${LIBDIR}/bzip2")
|
||||
set(BZIP2_CONFIGURE_ENV echo .)
|
||||
set(BZIP2_CONFIGURATION_ARGS)
|
||||
|
||||
if(UNIX AND NOT APPLE)
|
||||
set(BZIP2_LDFLAGS "-Wl,--as-needed")
|
||||
set(BZIP2_CFLAGS "-fPIC -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64")
|
||||
set(BZIP2_CONFIGURE_ENV ${BZIP2_CONFIGURE_ENV} && export LDFLAGS=${BZIP2_LDFLAGS} && export CFLAGS=${BZIP2_CFLAGS}
|
||||
&& export PREFIX=${BZIP2_PREFIX})
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_bzip2
|
||||
URL ${BZIP2_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH SHA256=${BZIP2_HASH}
|
||||
PREFIX ${BUILD_DIR}/bzip2
|
||||
CONFIGURE_COMMAND echo .
|
||||
BUILD_COMMAND ${BZIP2_CONFIGURE_ENV} && cd ${BUILD_DIR}/bzip2/src/external_bzip2/ && make CFLAGS=${BZIP2_CFLAGS} LDFLAGS=${BZIP2_LDFLAGS} -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${BZIP2_CONFIGURE_ENV} && cd ${BUILD_DIR}/bzip2/src/external_bzip2/ && make CFLAGS=${BZIP2_CFLAGS} LDFLAGS=${BZIP2_LDFLAGS} PREFIX=${BZIP2_PREFIX} install
|
||||
INSTALL_DIR ${LIBDIR}/bzip2
|
||||
)
|
@@ -1,59 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(UNIX)
|
||||
if(APPLE)
|
||||
set(_libtoolize_name glibtoolize)
|
||||
else()
|
||||
set(_libtoolize_name libtoolize)
|
||||
endif()
|
||||
|
||||
set(_required_software
|
||||
autoconf
|
||||
automake
|
||||
${_libtoolize_name}
|
||||
nasm
|
||||
yasm
|
||||
tclsh
|
||||
)
|
||||
|
||||
foreach(_software ${_required_software})
|
||||
find_program(_software_find NAMES ${_software})
|
||||
if(NOT _software_find)
|
||||
set(_software_missing "${_software_missing}${_software} ")
|
||||
endif()
|
||||
unset(_software_find CACHE)
|
||||
endforeach()
|
||||
|
||||
if(_software_missing)
|
||||
message(
|
||||
"\n"
|
||||
"Missing software for building Blender dependencies:\n"
|
||||
" ${_software_missing}\n"
|
||||
"\n"
|
||||
"On Debian and Ubuntu:\n"
|
||||
" apt install autoconf automake libtool yasm nasm tcl\n"
|
||||
"\n"
|
||||
"On macOS (with homebrew):\n"
|
||||
" brew install cmake autoconf automake libtool yasm nasm\n"
|
||||
"\n"
|
||||
"Other platforms:\n"
|
||||
" Install equivalent packages.\n")
|
||||
message(FATAL_ERROR "Install missing software before continuing")
|
||||
endif()
|
||||
endif()
|
@@ -1,61 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(CLANG_EXTRA_ARGS
|
||||
-DCLANG_PATH_TO_LLVM_SOURCE=${BUILD_DIR}/ll/src/ll
|
||||
-DCLANG_PATH_TO_LLVM_BUILD=${LIBDIR}/llvm
|
||||
-DLLVM_USE_CRT_RELEASE=MD
|
||||
-DLLVM_USE_CRT_DEBUG=MDd
|
||||
-DLLVM_CONFIG=${LIBDIR}/llvm/bin/llvm-config
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
set(CLANG_GENERATOR "Ninja")
|
||||
else()
|
||||
set(CLANG_GENERATOR "Unix Makefiles")
|
||||
endif()
|
||||
|
||||
|
||||
ExternalProject_Add(external_clang
|
||||
URL ${CLANG_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${CLANG_HASH}
|
||||
PREFIX ${BUILD_DIR}/clang
|
||||
CMAKE_GENERATOR ${CLANG_GENERATOR}
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/clang ${DEFAULT_CMAKE_FLAGS} ${CLANG_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/clang
|
||||
)
|
||||
|
||||
if(MSVC)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
set(CLANG_HARVEST_COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/clang/ ${HARVEST_TARGET}/llvm/)
|
||||
else()
|
||||
set(CLANG_HARVEST_COMMAND
|
||||
${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/clang/lib/ ${HARVEST_TARGET}/llvm/debug/lib/
|
||||
)
|
||||
endif()
|
||||
ExternalProject_Add_Step(external_clang after_install
|
||||
COMMAND ${CLANG_HARVEST_COMMAND}
|
||||
DEPENDEES mkdir update patch download configure build install
|
||||
)
|
||||
endif()
|
||||
|
||||
add_dependencies(
|
||||
external_clang
|
||||
ll
|
||||
)
|
@@ -1,28 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(CLEW_EXTRA_ARGS)
|
||||
|
||||
ExternalProject_Add(external_clew
|
||||
URL ${CLEW_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${CLEW_HASH}
|
||||
PREFIX ${BUILD_DIR}/clew
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/clew -Wno-dev ${DEFAULT_CMAKE_FLAGS} ${CLEW_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/clew
|
||||
)
|
@@ -1,29 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(CUEW_EXTRA_ARGS)
|
||||
|
||||
ExternalProject_Add(external_cuew
|
||||
URL ${CUEW_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${CUEW_HASH}
|
||||
PREFIX ${BUILD_DIR}/cuew
|
||||
PATCH_COMMAND ${PATCH_CMD} --verbose -p 0 -N -d ${BUILD_DIR}/cuew/src/external_cuew < ${PATCH_DIR}/cuew.diff
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/cuew -Wno-dev ${DEFAULT_CMAKE_FLAGS} ${CUEW_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/cuew
|
||||
)
|
@@ -1,69 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
# Note the utility apps may use png/tiff/gif system libraries, but the
|
||||
# library itself does not depend on them, so should give no problems.
|
||||
|
||||
set(EMBREE_EXTRA_ARGS
|
||||
-DEMBREE_ISPC_SUPPORT=OFF
|
||||
-DEMBREE_TUTORIALS=OFF
|
||||
-DEMBREE_STATIC_LIB=ON
|
||||
-DEMBREE_RAY_MASK=ON
|
||||
-DEMBREE_FILTER_FUNCTION=ON
|
||||
-DEMBREE_BACKFACE_CULLING=OFF
|
||||
-DEMBREE_TASKING_SYSTEM=INTERNAL
|
||||
-DEMBREE_MAX_ISA=AVX2
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
set(EMBREE_BUILD_DIR ${BUILD_MODE}/)
|
||||
else()
|
||||
set(EMBREE_BUILD_DIR)
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_embree
|
||||
URL ${EMBREE_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${EMBREE_HASH}
|
||||
PREFIX ${BUILD_DIR}/embree
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/embree ${DEFAULT_CMAKE_FLAGS} ${EMBREE_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/embree
|
||||
)
|
||||
if(WIN32)
|
||||
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_embree after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/embree ${HARVEST_TARGET}/embree
|
||||
DEPENDEES install
|
||||
)
|
||||
else()
|
||||
ExternalProject_Add_Step(external_embree after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/embree/lib/embree3.lib ${HARVEST_TARGET}/embree/lib/embree3_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/embree/lib/embree_avx.lib ${HARVEST_TARGET}/embree/lib/embree_avx_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/embree/lib/embree_avx2.lib ${HARVEST_TARGET}/embree/lib/embree_avx2_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/embree/lib/embree_sse42.lib ${HARVEST_TARGET}/embree/lib/embree_sse42_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/embree/lib/lexers.lib ${HARVEST_TARGET}/embree/lib/lexers_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/embree/lib/math.lib ${HARVEST_TARGET}/embree/lib/math_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/embree/lib/simd.lib ${HARVEST_TARGET}/embree/lib/simd_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/embree/lib/sys.lib ${HARVEST_TARGET}/embree/lib/sys_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/embree/lib/tasking.lib ${HARVEST_TARGET}/embree/lib/tasking_d.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
|
||||
endif()
|
@@ -1,40 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(FAAD_EXTRA_ARGS)
|
||||
|
||||
if(WIN32)
|
||||
set(FAAD_EXTRA_CONFIGURE "utils\\win32\\ac2ver.exe" "faad2" "configure.ac" > libfaad\\win32_ver.h)
|
||||
else()
|
||||
set(FAAD_EXTRA_CONFIGURE echo .)
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_faad
|
||||
URL ${FAAD_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${FAAD_HASH}
|
||||
PREFIX ${BUILD_DIR}/faad
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/faad/src/external_faad/ && ${FAAD_EXTRA_CONFIGURE} && ${CONFIGURE_COMMAND} --disable-shared --enable-static --prefix=${LIBDIR}/faad
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/faad/src/external_faad/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/faad/src/external_faad/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/faad
|
||||
)
|
||||
|
||||
if(MSVC)
|
||||
set_target_properties(external_faad PROPERTIES FOLDER Mingw)
|
||||
endif()
|
@@ -1,40 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
ExternalProject_Add(external_ffi
|
||||
URL ${FFI_URI}
|
||||
URL_HASH SHA256=${FFI_HASH}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
PREFIX ${BUILD_DIR}/ffi
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/ffi/src/external_ffi/ && ${CONFIGURE_COMMAND} --prefix=${LIBDIR}/ffi
|
||||
--enable-shared=no
|
||||
--enable-static=yes
|
||||
--with-pic
|
||||
--libdir=${LIBDIR}/ffi/lib/
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/ffi/src/external_ffi/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/ffi/src/external_ffi/ && make install
|
||||
PATCH_COMMAND ${PATCH_CMD} -p 0 -d ${BUILD_DIR}/ffi/src/external_ffi < ${PATCH_DIR}/ffi.diff
|
||||
INSTALL_DIR ${LIBDIR}/ffi
|
||||
)
|
||||
|
||||
if(UNIX AND NOT APPLE)
|
||||
ExternalProject_Add_Step(external_ffi after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/ffi/lib/libffi.a ${LIBDIR}/ffi/lib/libffi_pic.a
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
@@ -1,154 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(FFMPEG_CFLAGS "-I${mingw_LIBDIR}/lame/include -I${mingw_LIBDIR}/openjpeg/include/ -I${mingw_LIBDIR}/ogg/include -I${mingw_LIBDIR}/vorbis/include -I${mingw_LIBDIR}/theora/include -I${mingw_LIBDIR}/opus/include -I${mingw_LIBDIR}/vpx/include -I${mingw_LIBDIR}/x264/include -I${mingw_LIBDIR}/xvidcore/include -I${mingw_LIBDIR}/zlib/include")
|
||||
set(FFMPEG_LDFLAGS "-L${mingw_LIBDIR}/lame/lib -L${mingw_LIBDIR}/openjpeg/lib -L${mingw_LIBDIR}/ogg/lib -L${mingw_LIBDIR}/vorbis/lib -L${mingw_LIBDIR}/theora/lib -L${mingw_LIBDIR}/opus/lib -L${mingw_LIBDIR}/vpx/lib -L${mingw_LIBDIR}/x264/lib -L${mingw_LIBDIR}/xvidcore/lib -L${mingw_LIBDIR}/zlib/lib")
|
||||
set(FFMPEG_EXTRA_FLAGS --pkg-config-flags=--static --extra-cflags=${FFMPEG_CFLAGS} --extra-ldflags=${FFMPEG_LDFLAGS})
|
||||
set(FFMPEG_ENV PKG_CONFIG_PATH=${mingw_LIBDIR}/openjpeg/lib/pkgconfig:${mingw_LIBDIR}/x264/lib/pkgconfig:${mingw_LIBDIR}/vorbis/lib/pkgconfig:${mingw_LIBDIR}/ogg/lib/pkgconfig:${mingw_LIBDIR}:${mingw_LIBDIR}/vpx/lib/pkgconfig:${mingw_LIBDIR}/theora/lib/pkgconfig:${mingw_LIBDIR}/openjpeg/lib/pkgconfig:${mingw_LIBDIR}/opus/lib/pkgconfig:)
|
||||
|
||||
if(WIN32)
|
||||
set(FFMPEG_ENV set ${FFMPEG_ENV} &&)
|
||||
set(FFMPEG_EXTRA_FLAGS
|
||||
${FFMPEG_EXTRA_FLAGS}
|
||||
--disable-static
|
||||
--enable-shared
|
||||
--enable-w32threads
|
||||
--disable-pthreads
|
||||
--enable-libopenjpeg
|
||||
)
|
||||
if("${CMAKE_SIZEOF_VOID_P}" EQUAL "4")
|
||||
set(FFMPEG_EXTRA_FLAGS
|
||||
${FFMPEG_EXTRA_FLAGS}
|
||||
--x86asmexe=yasm
|
||||
)
|
||||
endif()
|
||||
else()
|
||||
set(FFMPEG_EXTRA_FLAGS
|
||||
${FFMPEG_EXTRA_FLAGS}
|
||||
--enable-static
|
||||
--disable-shared
|
||||
--enable-libopenjpeg
|
||||
)
|
||||
endif()
|
||||
|
||||
if(APPLE)
|
||||
set(FFMPEG_EXTRA_FLAGS
|
||||
${FFMPEG_EXTRA_FLAGS}
|
||||
--target-os=darwin
|
||||
)
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_ffmpeg
|
||||
URL ${FFMPEG_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${FFMPEG_HASH}
|
||||
# OpenJpeg is compiled with pthread support on Linux, which is all fine and is what we
|
||||
# want for maximum runtime performance, but due to static nature of that library we
|
||||
# need to force ffmpeg to link against pthread, otherwise test program used by autoconf
|
||||
# will fail. This patch does that in a way that is compatible with multiple distributions.
|
||||
PATCH_COMMAND ${PATCH_CMD} --verbose -p 1 -N -d ${BUILD_DIR}/ffmpeg/src/external_ffmpeg < ${PATCH_DIR}/ffmpeg.diff
|
||||
PREFIX ${BUILD_DIR}/ffmpeg
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV_NO_PERL} &&
|
||||
cd ${BUILD_DIR}/ffmpeg/src/external_ffmpeg/ &&
|
||||
${FFMPEG_ENV} ${CONFIGURE_COMMAND_NO_TARGET} ${FFMPEG_EXTRA_FLAGS}
|
||||
--disable-lzma
|
||||
--disable-avfilter
|
||||
--disable-vdpau
|
||||
--disable-bzlib
|
||||
--disable-libgsm
|
||||
--disable-libspeex
|
||||
--enable-libvpx
|
||||
--enable-libopus
|
||||
--prefix=${LIBDIR}/ffmpeg
|
||||
--enable-libtheora
|
||||
--enable-libvorbis
|
||||
--enable-zlib
|
||||
--enable-stripping
|
||||
--enable-runtime-cpudetect
|
||||
--disable-vaapi
|
||||
--disable-nonfree
|
||||
--enable-gpl
|
||||
--disable-postproc
|
||||
--enable-libmp3lame
|
||||
--disable-librtmp
|
||||
--enable-libx264
|
||||
--enable-libxvid
|
||||
--disable-libopencore-amrnb
|
||||
--disable-libopencore-amrwb
|
||||
--disable-libdc1394
|
||||
--disable-version3
|
||||
--disable-debug
|
||||
--enable-optimizations
|
||||
--disable-sse
|
||||
--disable-ssse3
|
||||
--enable-ffplay
|
||||
--disable-openssl
|
||||
--disable-securetransport
|
||||
--disable-indev=avfoundation
|
||||
--disable-indev=qtkit
|
||||
--disable-sdl2
|
||||
--disable-gnutls
|
||||
--disable-videotoolbox
|
||||
--disable-libxcb
|
||||
--disable-xlib
|
||||
--disable-audiotoolbox
|
||||
--disable-cuvid
|
||||
--disable-nvenc
|
||||
--disable-indev=jack
|
||||
--disable-indev=alsa
|
||||
--disable-outdev=alsa
|
||||
--disable-crystalhd
|
||||
--disable-sndio
|
||||
BUILD_COMMAND ${CONFIGURE_ENV_NO_PERL} && cd ${BUILD_DIR}/ffmpeg/src/external_ffmpeg/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV_NO_PERL} && cd ${BUILD_DIR}/ffmpeg/src/external_ffmpeg/ && make install
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/ffmpeg ${DEFAULT_CMAKE_FLAGS}
|
||||
INSTALL_DIR ${LIBDIR}/ffmpeg
|
||||
)
|
||||
|
||||
if(MSVC)
|
||||
set_target_properties(external_ffmpeg PROPERTIES FOLDER Mingw)
|
||||
endif()
|
||||
|
||||
add_dependencies(
|
||||
external_ffmpeg
|
||||
external_zlib
|
||||
external_faad
|
||||
external_openjpeg
|
||||
external_xvidcore
|
||||
external_x264
|
||||
external_opus
|
||||
external_vpx
|
||||
external_theora
|
||||
external_vorbis
|
||||
external_ogg
|
||||
external_lame
|
||||
)
|
||||
if(WIN32)
|
||||
add_dependencies(
|
||||
external_ffmpeg
|
||||
external_zlib_mingw
|
||||
)
|
||||
endif()
|
||||
|
||||
if(BUILD_MODE STREQUAL Release AND WIN32)
|
||||
ExternalProject_Add_Step(external_ffmpeg after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/ffmpeg/include ${HARVEST_TARGET}/ffmpeg/include
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/ffmpeg/bin ${HARVEST_TARGET}/ffmpeg/lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
@@ -1,47 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(FFTW_EXTRA_ARGS)
|
||||
|
||||
if(WIN32)
|
||||
set(FFTW3_ENV set CFLAGS=-fno-stack-check -fno-stack-protector -mno-stack-arg-probe -fno-lto &&)
|
||||
set(FFTW3_PATCH_COMMAND ${PATCH_CMD} --verbose -p 0 -N -d ${BUILD_DIR}/fftw3/src/external_fftw3 < ${PATCH_DIR}/fftw3.diff)
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_fftw3
|
||||
URL ${FFTW_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${FFTW_HASH}
|
||||
PREFIX ${BUILD_DIR}/fftw3
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && ${FFTW3_ENV} cd ${BUILD_DIR}/fftw3/src/external_fftw3/ && ${CONFIGURE_COMMAND} --enable-static --prefix=${mingw_LIBDIR}/fftw3
|
||||
PATCH_COMMAND ${FFTW3_PATCH_COMMAND}
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/fftw3/src/external_fftw3/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/fftw3/src/external_fftw3/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/fftw3
|
||||
)
|
||||
|
||||
if(MSVC)
|
||||
set_target_properties(external_fftw3 PROPERTIES FOLDER Mingw)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_fftw3 after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/fftw3/lib/libfftw3.a ${HARVEST_TARGET}/fftw3/lib/libfftw.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/fftw3/include/fftw3.h ${HARVEST_TARGET}/fftw3/include/fftw3.h
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
endif()
|
@@ -1,32 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
ExternalProject_Add(external_flac
|
||||
URL ${FLAC_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH SHA256=${FLAC_HASH}
|
||||
PREFIX ${BUILD_DIR}/flac
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/flac/src/external_flac/ && ${CONFIGURE_COMMAND} --prefix=${LIBDIR}/flac --disable-shared --enable-static
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/flac/src/external_flac/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/flac/src/external_flac/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/flac
|
||||
)
|
||||
|
||||
if(MSVC)
|
||||
set_target_properties(external_flac PROPERTIES FOLDER Mingw)
|
||||
endif()
|
@@ -1,31 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(FLEXBISON_EXTRA_ARGS)
|
||||
|
||||
ExternalProject_Add(external_flexbison
|
||||
URL ${FLEXBISON_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${FLEXBISON_HASH}
|
||||
PREFIX ${BUILD_DIR}/flexbison
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/flexbison ${DEFAULT_CMAKE_FLAGS} ${FLEXBISON_EXTRA_ARGS}
|
||||
CONFIGURE_COMMAND echo .
|
||||
BUILD_COMMAND echo .
|
||||
INSTALL_COMMAND COMMAND ${CMAKE_COMMAND} -E copy_directory ${BUILD_DIR}/flexbison/src/external_flexbison/ ${LIBDIR}/flexbison/
|
||||
INSTALL_DIR ${LIBDIR}/flexbison
|
||||
)
|
@@ -1,35 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(WIN32)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
set(FREEGLUT_EXTRA_ARGS
|
||||
-DFREEGLUT_BUILD_SHARED_LIBS=Off
|
||||
-DFREEGLUT_BUILD_STATIC_LIBS=On
|
||||
)
|
||||
|
||||
ExternalProject_Add(external_freeglut
|
||||
URL ${FREEGLUT_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${FREEGLUT_HASH}
|
||||
PREFIX ${BUILD_DIR}/freeglut
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/freeglut ${DEFAULT_C_FLAGS} ${DEFAULT_CXX_FLAGS} ${FREEGLUT_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/freeglut
|
||||
)
|
||||
endif()
|
||||
endif()
|
@@ -1,43 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(FREETYPE_EXTRA_ARGS
|
||||
-DCMAKE_RELEASE_POSTFIX:STRING=2ST
|
||||
-DCMAKE_DEBUG_POSTFIX:STRING=2ST_d
|
||||
-DWITH_BZip2=OFF
|
||||
-DWITH_HarfBuzz=OFF
|
||||
-DFT_WITH_HARFBUZZ=OFF
|
||||
-DFT_WITH_BZIP2=OFF
|
||||
-DCMAKE_DISABLE_FIND_PACKAGE_HarfBuzz=TRUE
|
||||
-DCMAKE_DISABLE_FIND_PACKAGE_BZip2=TRUE)
|
||||
|
||||
ExternalProject_Add(external_freetype
|
||||
URL ${FREETYPE_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${FREETYPE_HASH}
|
||||
PREFIX ${BUILD_DIR}/freetype
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/freetype ${DEFAULT_CMAKE_FLAGS} ${FREETYPE_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/freetype
|
||||
)
|
||||
|
||||
if(BUILD_MODE STREQUAL Release AND WIN32)
|
||||
ExternalProject_Add_Step(external_freetype after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/freetype ${HARVEST_TARGET}/freetype
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
@@ -1,32 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(GLEW_EXTRA_ARGS
|
||||
-DBUILD_UTILS=Off
|
||||
-DBUILD_SHARED_LIBS=Off
|
||||
)
|
||||
|
||||
ExternalProject_Add(external_glew
|
||||
URL ${GLEW_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${GLEW_HASH}
|
||||
PATCH_COMMAND COMMAND ${CMAKE_COMMAND} -E copy ${PATCH_DIR}/cmakelists_glew.txt ${BUILD_DIR}/glew/src/external_glew/CMakeLists.txt
|
||||
PREFIX ${BUILD_DIR}/glew
|
||||
CMAKE_ARGS -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_INSTALL_PREFIX=${LIBDIR}/glew ${DEFAULT_CMAKE_FLAGS} ${GLEW_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/glew
|
||||
)
|
@@ -1,28 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(GLFW_EXTRA_ARGS)
|
||||
|
||||
ExternalProject_Add(external_glfw
|
||||
URL ${GLFW_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${GLFW_HASH}
|
||||
PREFIX ${BUILD_DIR}/glfw
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/glfw -Wno-dev ${DEFAULT_CMAKE_FLAGS} ${GLFW_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/glfw
|
||||
)
|
@@ -1,203 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
########################################################################
|
||||
# Copy all generated files to the proper strucure as blender prefers
|
||||
########################################################################
|
||||
|
||||
if(NOT DEFINED HARVEST_TARGET)
|
||||
set(HARVEST_TARGET ${CMAKE_CURRENT_SOURCE_DIR}/Harvest)
|
||||
endif()
|
||||
message("HARVEST_TARGET = ${HARVEST_TARGET}")
|
||||
|
||||
if(WIN32)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
add_custom_target(Harvest_Release_Results
|
||||
COMMAND # jpeg rename libfile + copy include
|
||||
${CMAKE_COMMAND} -E copy ${LIBDIR}/jpg/lib/jpeg-static.lib ${HARVEST_TARGET}/jpeg/lib/libjpeg.lib &&
|
||||
${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/jpg/include/ ${HARVEST_TARGET}/jpeg/include/ &&
|
||||
# OpenImageIO
|
||||
${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/OpenImageIO/include ${HARVEST_TARGET}/OpenImageIO/include &&
|
||||
${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/OpenImageIO/lib ${HARVEST_TARGET}/OpenImageIO/lib &&
|
||||
${CMAKE_COMMAND} -E copy ${LIBDIR}/OpenImageIO/bin/idiff.exe ${HARVEST_TARGET}/OpenImageIO/bin/idiff.exe &&
|
||||
# png
|
||||
${CMAKE_COMMAND} -E copy ${LIBDIR}/png/lib/libpng16_static.lib ${HARVEST_TARGET}/png/lib/libpng.lib &&
|
||||
${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/png/include/ ${HARVEST_TARGET}/png/include/ &&
|
||||
# freeglut-> opengl
|
||||
${CMAKE_COMMAND} -E copy ${LIBDIR}/freeglut/lib/freeglut_static.lib ${HARVEST_TARGET}/opengl/lib/freeglut_static.lib &&
|
||||
${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/freeglut/include/ ${HARVEST_TARGET}/opengl/include/ &&
|
||||
# glew-> opengl
|
||||
${CMAKE_COMMAND} -E copy ${LIBDIR}/glew/lib/libglew32.lib ${HARVEST_TARGET}/opengl/lib/glew.lib &&
|
||||
${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/glew/include/ ${HARVEST_TARGET}/opengl/include/ &&
|
||||
# sndfile
|
||||
${CMAKE_COMMAND} -E copy ${LIBDIR}/sndfile/lib/libsndfile.dll.a ${HARVEST_TARGET}/sndfile/lib/libsndfile-1.lib &&
|
||||
${CMAKE_COMMAND} -E copy ${LIBDIR}/sndfile/bin/libsndfile-1.dll ${HARVEST_TARGET}/sndfile/lib/libsndfile-1.dll &&
|
||||
${CMAKE_COMMAND} -E copy ${LIBDIR}/sndfile/include/sndfile.h ${HARVEST_TARGET}/sndfile/include/sndfile.h &&
|
||||
# tiff
|
||||
${CMAKE_COMMAND} -E copy ${LIBDIR}/tiff/lib/tiff.lib ${HARVEST_TARGET}/tiff/lib/libtiff.lib &&
|
||||
${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/tiff/include/ ${HARVEST_TARGET}/tiff/include/ &&
|
||||
# hidapi
|
||||
${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/hidapi/ ${HARVEST_TARGET}/hidapi/
|
||||
DEPENDS
|
||||
)
|
||||
endif()
|
||||
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
add_custom_target(Harvest_Debug_Results
|
||||
# OpenImageIO
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/openimageio/lib/OpenImageIO.lib ${HARVEST_TARGET}/openimageio/lib/OpenImageIO_d.lib &&
|
||||
${CMAKE_COMMAND} -E copy ${LIBDIR}/openimageio/lib/OpenImageIO_Util.lib ${HARVEST_TARGET}/openimageio/lib/OpenImageIO_Util_d.lib &&
|
||||
# hdf5
|
||||
${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/hdf5/lib ${HARVEST_TARGET}/hdf5/lib &&
|
||||
DEPENDS Package_Python
|
||||
)
|
||||
endif()
|
||||
|
||||
else(WIN32)
|
||||
|
||||
function(harvest from to)
|
||||
set(pattern "")
|
||||
foreach(f ${ARGN})
|
||||
set(pattern ${f})
|
||||
endforeach()
|
||||
|
||||
if(pattern STREQUAL "")
|
||||
get_filename_component(dirpath ${to} DIRECTORY)
|
||||
get_filename_component(filename ${to} NAME)
|
||||
install(
|
||||
FILES ${LIBDIR}/${from}
|
||||
DESTINATION ${HARVEST_TARGET}/${dirpath}
|
||||
RENAME ${filename})
|
||||
else()
|
||||
install(
|
||||
DIRECTORY ${LIBDIR}/${from}/
|
||||
DESTINATION ${HARVEST_TARGET}/${to}
|
||||
USE_SOURCE_PERMISSIONS
|
||||
FILES_MATCHING PATTERN ${pattern}
|
||||
PATTERN "pkgconfig" EXCLUDE
|
||||
PATTERN "cmake" EXCLUDE
|
||||
PATTERN "__pycache__" EXCLUDE
|
||||
PATTERN "tests" EXCLUDE)
|
||||
endif()
|
||||
endfunction()
|
||||
|
||||
harvest(alembic/include alembic/include "*.h")
|
||||
harvest(alembic/lib/libAlembic.a alembic/lib/libAlembic.a)
|
||||
harvest(alembic/bin alembic/bin "*")
|
||||
harvest(boost/include boost/include "*")
|
||||
harvest(boost/lib boost/lib "*.a")
|
||||
harvest(ffmpeg/include ffmpeg/include "*.h")
|
||||
harvest(ffmpeg/lib ffmpeg/lib "*.a")
|
||||
harvest(fftw3/include fftw3/include "*.h")
|
||||
harvest(fftw3/lib fftw3/lib "*.a")
|
||||
harvest(flac/lib sndfile/lib "libFLAC.a")
|
||||
harvest(freetype/include freetype/include "*.h")
|
||||
harvest(freetype/lib/libfreetype2ST.a freetype/lib/libfreetype.a)
|
||||
harvest(glew/include glew/include "*.h")
|
||||
harvest(glew/lib glew/lib "*.a")
|
||||
harvest(jemalloc/include jemalloc/include "*.h")
|
||||
harvest(jemalloc/lib jemalloc/lib "*.a")
|
||||
harvest(jpg/include jpeg/include "*.h")
|
||||
harvest(jpg/lib jpeg/lib "libjpeg.a")
|
||||
harvest(lame/lib ffmpeg/lib "*.a")
|
||||
harvest(clang/bin llvm/bin "clang-format")
|
||||
harvest(clang/include llvm/include "*")
|
||||
harvest(llvm/include llvm/include "*")
|
||||
harvest(llvm/bin llvm/bin "llvm-config")
|
||||
harvest(llvm/lib llvm/lib "libLLVM*.a")
|
||||
if(APPLE)
|
||||
harvest(openmp/lib openmp/lib "*")
|
||||
harvest(openmp/include openmp/include "*.h")
|
||||
endif()
|
||||
harvest(ogg/lib ffmpeg/lib "*.a")
|
||||
harvest(openal/include openal/include "*.h")
|
||||
if(UNIX AND NOT APPLE)
|
||||
harvest(openal/lib openal/lib "*.a")
|
||||
|
||||
harvest(blosc/include blosc/include "*.h")
|
||||
harvest(blosc/lib blosc/lib "*.a")
|
||||
|
||||
harvest(zlib/include zlib/include "*.h")
|
||||
harvest(zlib/lib zlib/lib "*.a")
|
||||
|
||||
harvest(xml2/include xml2/include "*.h")
|
||||
harvest(xml2/lib xml2/lib "*.a")
|
||||
else()
|
||||
harvest(blosc/lib openvdb/lib "*.a")
|
||||
harvest(xml2/lib opencollada/lib "*.a")
|
||||
endif()
|
||||
harvest(opencollada/include/opencollada opencollada/include "*.h")
|
||||
harvest(opencollada/lib/opencollada opencollada/lib "*.a")
|
||||
harvest(opencolorio/include opencolorio/include "*.h")
|
||||
harvest(opencolorio/lib opencolorio/lib "*.a")
|
||||
harvest(opencolorio/lib/static opencolorio/lib "*.a")
|
||||
harvest(openexr/include openexr/include "*.h")
|
||||
harvest(openexr/lib openexr/lib "*.a")
|
||||
harvest(openimageio/bin openimageio/bin "idiff")
|
||||
harvest(openimageio/bin openimageio/bin "maketx")
|
||||
harvest(openimageio/bin openimageio/bin "oiiotool")
|
||||
harvest(openimageio/include openimageio/include "*")
|
||||
harvest(openimageio/lib openimageio/lib "*.a")
|
||||
harvest(openimagedenoise/include openimagedenoise/include "*")
|
||||
harvest(openimagedenoise/lib openimagedenoise/lib "*.a")
|
||||
harvest(openjpeg/include/openjpeg-2.3 openjpeg/include "*.h")
|
||||
harvest(openjpeg/lib openjpeg/lib "*.a")
|
||||
harvest(opensubdiv/include opensubdiv/include "*.h")
|
||||
harvest(opensubdiv/lib opensubdiv/lib "*.a")
|
||||
harvest(openvdb/include/openvdb openvdb/include/openvdb "*.h")
|
||||
harvest(openvdb/lib openvdb/lib "*.a")
|
||||
harvest(xr_openxr_sdk/include/openxr xr_openxr_sdk/include/openxr "*.h")
|
||||
harvest(xr_openxr_sdk/lib xr_openxr_sdk/lib "*.a")
|
||||
harvest(osl/bin osl/bin "oslc")
|
||||
harvest(osl/include osl/include "*.h")
|
||||
harvest(osl/lib osl/lib "*.a")
|
||||
harvest(osl/shaders osl/shaders "*.h")
|
||||
harvest(png/include png/include "*.h")
|
||||
harvest(png/lib png/lib "*.a")
|
||||
harvest(python/bin python/bin "python${PYTHON_SHORT_VERSION}m")
|
||||
harvest(python/include python/include "*h")
|
||||
harvest(python/lib python/lib "*")
|
||||
harvest(sdl/include/SDL2 sdl/include "*.h")
|
||||
harvest(sdl/lib sdl/lib "libSDL2.a")
|
||||
harvest(sndfile/include sndfile/include "*.h")
|
||||
harvest(sndfile/lib sndfile/lib "*.a")
|
||||
harvest(spnav/include spnav/include "*.h")
|
||||
harvest(spnav/lib spnav/lib "*.a")
|
||||
harvest(tbb/include tbb/include "*.h")
|
||||
harvest(tbb/lib/libtbb_static.a tbb/lib/libtbb.a)
|
||||
harvest(theora/lib ffmpeg/lib "*.a")
|
||||
harvest(tiff/include tiff/include "*.h")
|
||||
harvest(tiff/lib tiff/lib "*.a")
|
||||
harvest(vorbis/lib ffmpeg/lib "*.a")
|
||||
harvest(opus/lib ffmpeg/lib "*.a")
|
||||
harvest(vpx/lib ffmpeg/lib "*.a")
|
||||
harvest(webp/lib ffmpeg/lib "*.a")
|
||||
harvest(x264/lib ffmpeg/lib "*.a")
|
||||
harvest(xvidcore/lib ffmpeg/lib "*.a")
|
||||
harvest(embree/include embree/include "*.h")
|
||||
harvest(embree/lib embree/lib "*.a")
|
||||
harvest(usd/include usd/include "*.h")
|
||||
harvest(usd/lib/usd usd/lib/usd "*")
|
||||
harvest(usd/plugin usd/plugin "*")
|
||||
|
||||
if(UNIX AND NOT APPLE)
|
||||
harvest(libglu/lib mesa/lib "*.so*")
|
||||
harvest(mesa/lib mesa/lib "*.so*")
|
||||
endif()
|
||||
|
||||
endif()
|
@@ -1,42 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(HDF5_EXTRA_ARGS
|
||||
-DHDF5_ENABLE_THREADSAFE=Off
|
||||
-DHDF5_BUILD_CPP_LIB=Off
|
||||
-DBUILD_TESTING=Off
|
||||
-DHDF5_BUILD_TOOLS=Off
|
||||
-DHDF5_BUILD_EXAMPLES=Off
|
||||
-DHDF5_BUILD_HL_LIB=On
|
||||
-DBUILD_STATIC_CRT_LIBS=On
|
||||
-DBUILD_SHARED_LIBS=On
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
set(HDF5_PATCH ${PATCH_CMD} --verbose -p 0 -d ${BUILD_DIR}/hdf5/src/external_hdf5 < ${PATCH_DIR}/hdf5.diff)
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_hdf5
|
||||
URL ${HDF5_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${HDF5_HASH}
|
||||
PREFIX ${BUILD_DIR}/hdf5
|
||||
PATCH_COMMAND ${HDF5_PATCH}
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/hdf5 ${HDF5_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/hdf5
|
||||
)
|
@@ -1,29 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(HIDAPI_EXTRA_ARGS)
|
||||
|
||||
ExternalProject_Add(external_hidapi
|
||||
URL ${HIDAPI_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${HIDAPI_HASH}
|
||||
PREFIX ${BUILD_DIR}/hidapi
|
||||
PATCH_COMMAND COMMAND ${CMAKE_COMMAND} -E copy ${PATCH_DIR}/cmakelists_hidapi.txt ${BUILD_DIR}/hidapi/src/external_hidapi/cmakelists.txt && ${PATCH_CMD} -p 0 -d ${BUILD_DIR}/hidapi/src/external_hidapi < ${PATCH_DIR}/hidapi.diff
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/hidapi -Wno-dev ${DEFAULT_CMAKE_FLAGS} ${HIDAPI_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/hidapi
|
||||
)
|
@@ -1,41 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(ICONV_EXTRA_ARGS)
|
||||
|
||||
ExternalProject_Add(external_iconv
|
||||
URL ${ICONV_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${ICONV_HASH}
|
||||
PREFIX ${BUILD_DIR}/iconv
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/iconv/src/external_iconv/ && ${CONFIGURE_COMMAND} --enable-static --prefix=${mingw_LIBDIR}/iconv
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/iconv/src/external_iconv/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/iconv/src/external_iconv/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/iconv
|
||||
)
|
||||
|
||||
if(MSVC)
|
||||
set_target_properties(external_iconv PROPERTIES FOLDER Mingw)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_iconv after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/iconv/lib/libiconv.a ${HARVEST_TARGET}/iconv/lib/iconv.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/iconv/include/iconv.h ${HARVEST_TARGET}/iconv/include/iconv.h
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
endif()
|
@@ -1,28 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
ExternalProject_Add(external_jemalloc
|
||||
URL ${JEMALLOC_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${JEMALLOC_HASH}
|
||||
PREFIX ${BUILD_DIR}/jemalloc
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/jemalloc/src/external_jemalloc/ && ${CONFIGURE_COMMAND} --prefix=${LIBDIR}/jemalloc --disable-shared --enable-static --with-pic
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/jemalloc/src/external_jemalloc/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/jemalloc/src/external_jemalloc/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/jemalloc
|
||||
)
|
@@ -1,65 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(WIN32)
|
||||
# cmake for windows
|
||||
set(JPEG_EXTRA_ARGS -DNASM=${NASM_PATH} -DWITH_JPEG8=ON -DCMAKE_DEBUG_POSTFIX=d)
|
||||
|
||||
ExternalProject_Add(external_jpeg
|
||||
URL ${JPEG_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${JPEG_HASH}
|
||||
PREFIX ${BUILD_DIR}/jpg
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/jpg ${DEFAULT_CMAKE_FLAGS} ${JPEG_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/jpg
|
||||
)
|
||||
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
ExternalProject_Add_Step(external_jpeg after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/jpg/lib/jpegd${LIBEXT} ${LIBDIR}/jpg/lib/jpeg${LIBEXT}
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
set(JPEG_LIBRARY jpeg-static${LIBEXT})
|
||||
else()
|
||||
set(JPEG_LIBRARY jpeg-staticd${LIBEXT})
|
||||
endif()
|
||||
else(WIN32)
|
||||
# autoconf for unix
|
||||
if(APPLE)
|
||||
set(JPEG_EXTRA_ARGS --host x86_64-apple-darwin --with-jpeg8)
|
||||
else()
|
||||
set(JPEG_EXTRA_ARGS --with-jpeg8)
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_jpeg
|
||||
URL ${JPEG_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${JPEG_HASH}
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && autoreconf -fiv && ${CONFIGURE_COMMAND} --prefix=${LIBDIR}/jpg NASM=yasm ${JPEG_EXTRA_ARGS}
|
||||
BUILD_IN_SOURCE 1
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && make install
|
||||
PREFIX ${BUILD_DIR}/jpg
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/jpg ${DEFAULT_CMAKE_FLAGS} ${JPEG_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/jpg
|
||||
)
|
||||
|
||||
set(JPEG_LIBRARY libjpeg${LIBEXT})
|
||||
endif(WIN32)
|
@@ -1,47 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(LAME_EXTRA_ARGS)
|
||||
if(MSVC)
|
||||
if("${CMAKE_SIZEOF_VOID_P}" EQUAL "4")
|
||||
set(LAME_EXTRA_ARGS CFLAGS=-msse)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_lame
|
||||
URL ${LAME_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${LAME_HASH}
|
||||
PREFIX ${BUILD_DIR}/lame
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/lame/src/external_lame/ && ${CONFIGURE_COMMAND} --prefix=${LIBDIR}/lame --disable-shared --enable-static ${LAME_EXTRA_ARGS}
|
||||
--enable-export=full
|
||||
--with-fileio=sndfile
|
||||
--without-vorbis
|
||||
--with-pic
|
||||
--disable-mp3x
|
||||
--disable-mp3rtp
|
||||
--disable-gtktest
|
||||
--disable-frontend
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/lame/src/external_lame/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/lame/src/external_lame/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/lame
|
||||
)
|
||||
|
||||
if(MSVC)
|
||||
set_target_properties(external_lame PROPERTIES FOLDER Mingw)
|
||||
endif()
|
@@ -1,31 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(LCMS_EXTRA_ARGS
|
||||
)
|
||||
|
||||
ExternalProject_Add(external_lcms
|
||||
URL ${LCMS_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${LCMS_HASH}
|
||||
PREFIX ${BUILD_DIR}/lcms
|
||||
# Patch taken from ocio.
|
||||
PATCH_COMMAND ${CMAKE_COMMAND} -E copy ${PATCH_DIR}/cmakelists_lcms.txt ${BUILD_DIR}/lcms/src/external_lcms/CMakeLists.txt
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/lcms ${DEFAULT_CMAKE_FLAGS} ${LCMS_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/lcms
|
||||
)
|
@@ -1,40 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(LIBGLU_CFLAGS "-static-libgcc")
|
||||
set(LIBGLU_CXXFLAGS "-static-libgcc -static-libstdc++ -Bstatic -lstdc++ -Bdynamic -l:libstdc++.a")
|
||||
set(LIBGLU_LDFLAGS "-pthread -static-libgcc -static-libstdc++ -Bstatic -lstdc++ -Bdynamic -l:libstdc++.a")
|
||||
|
||||
set(LIBGLU_EXTRA_FLAGS
|
||||
CFLAGS=${LIBGLU_CFLAGS}
|
||||
CXXFLAGS=${LIBGLU_CXXFLAGS}
|
||||
LDFLAGS=${LIBGLU_LDFLAGS}
|
||||
)
|
||||
|
||||
ExternalProject_Add(external_libglu
|
||||
URL ${LIBGLU_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${LIBGLU_HASH}
|
||||
PREFIX ${BUILD_DIR}/libglu
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} &&
|
||||
cd ${BUILD_DIR}/libglu/src/external_libglu/ &&
|
||||
${CONFIGURE_COMMAND_NO_TARGET} --prefix=${LIBDIR}/libglu ${LIBGLU_EXTRA_FLAGS}
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/libglu/src/external_libglu/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/libglu/src/external_libglu/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/libglu
|
||||
)
|
@@ -1,61 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(LLVM_EXTRA_ARGS
|
||||
-DLLVM_USE_CRT_RELEASE=MD
|
||||
-DLLVM_USE_CRT_DEBUG=MDd
|
||||
-DLLVM_INCLUDE_TESTS=OFF
|
||||
-DLLVM_TARGETS_TO_BUILD=X86
|
||||
-DLLVM_INCLUDE_EXAMPLES=OFF
|
||||
-DLLVM_ENABLE_TERMINFO=OFF
|
||||
-DLLVM_BUILD_LLVM_C_DYLIB=OFF
|
||||
-DLLVM_ENABLE_UNWIND_TABLES=OFF
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
set(LLVM_GENERATOR "Ninja")
|
||||
else()
|
||||
set(LLVM_GENERATOR "Unix Makefiles")
|
||||
endif()
|
||||
|
||||
# short project name due to long filename issues on windows
|
||||
ExternalProject_Add(ll
|
||||
URL ${LLVM_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${LLVM_HASH}
|
||||
CMAKE_GENERATOR ${LLVM_GENERATOR}
|
||||
PREFIX ${BUILD_DIR}/ll
|
||||
PATCH_COMMAND ${PATCH_CMD} -p 1 -d ${BUILD_DIR}/ll/src/ll < ${PATCH_DIR}/llvm.diff
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/llvm ${DEFAULT_CMAKE_FLAGS} ${LLVM_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/llvm
|
||||
)
|
||||
|
||||
if(MSVC)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
set(LLVM_HARVEST_COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/llvm/ ${HARVEST_TARGET}/llvm/ )
|
||||
else()
|
||||
set(LLVM_HARVEST_COMMAND
|
||||
${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/llvm/lib/ ${HARVEST_TARGET}/llvm/debug/lib/ &&
|
||||
${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/llvm/include/ ${HARVEST_TARGET}/llvm/debug/include/
|
||||
)
|
||||
endif()
|
||||
ExternalProject_Add_Step(ll after_install
|
||||
COMMAND ${LLVM_HARVEST_COMMAND}
|
||||
DEPENDEES mkdir update patch download configure build install
|
||||
)
|
||||
endif()
|
@@ -1,32 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(LZMA_PATCH_CMD echo .)
|
||||
|
||||
ExternalProject_Add(external_lzma
|
||||
URL ${LZMA_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH SHA256=${LZMA_HASH}
|
||||
PREFIX ${BUILD_DIR}/lzma
|
||||
PATCH_COMMAND ${LZMA_PATCH_CMD}
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/lzma/src/external_lzma/ && ${CONFIGURE_COMMAND} --prefix=${LIBDIR}/lzma
|
||||
--disable-shared
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/lzma/src/external_lzma/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/lzma/src/external_lzma/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/lzma
|
||||
)
|
@@ -1,54 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(MESA_CFLAGS "-static-libgcc")
|
||||
set(MESA_CXXFLAGS "-static-libgcc -static-libstdc++ -Bstatic -lstdc++ -Bdynamic -l:libstdc++.a")
|
||||
set(MESA_LDFLAGS "-L${LIBDIR}/zlib/lib -pthread -static-libgcc -static-libstdc++ -Bstatic -lstdc++ -Bdynamic -l:libstdc++.a -l:libz_pic.a")
|
||||
|
||||
set(MESA_EXTRA_FLAGS
|
||||
CFLAGS=${MESA_CFLAGS}
|
||||
CXXFLAGS=${MESA_CXXFLAGS}
|
||||
LDFLAGS=${MESA_LDFLAGS}
|
||||
--enable-glx=gallium-xlib
|
||||
--with-gallium-drivers=swrast
|
||||
--disable-dri
|
||||
--disable-gbm
|
||||
--disable-egl
|
||||
--disable-gles1
|
||||
--disable-gles2
|
||||
--disable-llvm-shared-libs
|
||||
--with-llvm-prefix=${LIBDIR}/llvm
|
||||
)
|
||||
|
||||
ExternalProject_Add(external_mesa
|
||||
URL ${MESA_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${MESA_HASH}
|
||||
PREFIX ${BUILD_DIR}/mesa
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} &&
|
||||
cd ${BUILD_DIR}/mesa/src/external_mesa/ &&
|
||||
${CONFIGURE_COMMAND_NO_TARGET} --prefix=${LIBDIR}/mesa ${MESA_EXTRA_FLAGS}
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/mesa/src/external_mesa/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/mesa/src/external_mesa/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/mesa
|
||||
)
|
||||
|
||||
add_dependencies(
|
||||
external_mesa
|
||||
ll
|
||||
)
|
@@ -1,49 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(MSVC)
|
||||
message("BIN >${PYTHON_BINARY}<")
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
set(NUMPY_DIR_POSTFIX -pydebug)
|
||||
set(NUMPY_ARCHIVE_POSTFIX d)
|
||||
set(NUMPY_BUILD_OPTION --debug)
|
||||
else()
|
||||
set(NUMPY_DIR_POSTFIX)
|
||||
set(NUMPY_ARCHIVE_POSTFIX)
|
||||
set(NUMPY_BUILD_OPTION)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
set(NUMPY_POSTFIX)
|
||||
|
||||
ExternalProject_Add(external_numpy
|
||||
URL ${NUMPY_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${NUMPY_HASH}
|
||||
PREFIX ${BUILD_DIR}/numpy
|
||||
PATCH_COMMAND ${NUMPY_PATCH}
|
||||
CONFIGURE_COMMAND ""
|
||||
LOG_BUILD 1
|
||||
BUILD_COMMAND ${PYTHON_BINARY} ${BUILD_DIR}/numpy/src/external_numpy/setup.py build ${NUMPY_BUILD_OPTION} install --old-and-unmanageable
|
||||
INSTALL_COMMAND ""
|
||||
)
|
||||
|
||||
add_dependencies(
|
||||
external_numpy
|
||||
external_python
|
||||
)
|
@@ -1,32 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
ExternalProject_Add(external_ogg
|
||||
URL ${OGG_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH SHA256=${OGG_HASH}
|
||||
PREFIX ${BUILD_DIR}/ogg
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/ogg/src/external_ogg/ && ${CONFIGURE_COMMAND} --prefix=${LIBDIR}/ogg --disable-shared --enable-static
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/ogg/src/external_ogg/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/ogg/src/external_ogg/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/ogg
|
||||
)
|
||||
|
||||
if(MSVC)
|
||||
set_target_properties(external_ogg PROPERTIES FOLDER Mingw)
|
||||
endif()
|
@@ -1,67 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
set(OPENAL_EXTRA_ARGS
|
||||
-DALSOFT_UTILS=OFF
|
||||
-DALSOFT_NO_CONFIG_UTIL=ON
|
||||
-DALSOFT_EXAMPLES=OFF
|
||||
-DALSOFT_TESTS=OFF
|
||||
-DALSOFT_CONFIG=OFF
|
||||
-DALSOFT_HRTF_DEFS=OFF
|
||||
-DALSOFT_INSTALL=ON
|
||||
-DALSOFT_BACKEND_SNDIO=OFF
|
||||
)
|
||||
|
||||
if(UNIX)
|
||||
set(OPENAL_EXTRA_ARGS
|
||||
${OPENAL_EXTRA_ARGS}
|
||||
-DLIBTYPE=STATIC
|
||||
)
|
||||
endif()
|
||||
|
||||
if(UNIX AND NOT APPLE)
|
||||
# Ensure we have backends for playback.
|
||||
set(OPENAL_EXTRA_ARGS
|
||||
${OPENAL_EXTRA_ARGS}
|
||||
-DALSOFT_REQUIRE_ALSA=ON
|
||||
-DALSOFT_REQUIRE_OSS=ON
|
||||
-DALSOFT_REQUIRE_PULSEAUDIO=ON
|
||||
)
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_openal
|
||||
URL ${OPENAL_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${OPENAL_HASH}
|
||||
PREFIX ${BUILD_DIR}/openal
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/openal ${DEFAULT_CMAKE_FLAGS} ${OPENAL_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/openal
|
||||
PATCH_COMMAND ${PATCH_CMD} -p 1 -d ${BUILD_DIR}/openal/src/external_openal < ${PATCH_DIR}/openal.diff
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
ExternalProject_Add_Step(external_openal after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/openal/lib/openal32.lib ${HARVEST_TARGET}/openal/lib/openal32.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/openal/bin/openal32.dll ${HARVEST_TARGET}/openal/lib/openal32.dll
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/openal/include/ ${HARVEST_TARGET}/openal/include/
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
|
||||
endif()
|
@@ -1,65 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(UNIX)
|
||||
set(OPENCOLLADA_EXTRA_ARGS
|
||||
-DLIBXML2_INCLUDE_DIR=${LIBDIR}/xml2/include/libxml2
|
||||
-DLIBXML2_LIBRARIES=${LIBDIR}/xml2/lib/libxml2.a)
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_opencollada
|
||||
URL ${OPENCOLLADA_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${OPENCOLLADA_HASH}
|
||||
PREFIX ${BUILD_DIR}/opencollada
|
||||
PATCH_COMMAND ${PATCH_CMD} -p 1 -N -d ${BUILD_DIR}/opencollada/src/external_opencollada < ${PATCH_DIR}/opencollada.diff
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/opencollada ${DEFAULT_CMAKE_FLAGS} ${OPENCOLLADA_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/opencollada
|
||||
)
|
||||
|
||||
if(UNIX)
|
||||
add_dependencies(
|
||||
external_opencollada
|
||||
external_xml2
|
||||
)
|
||||
endif()
|
||||
|
||||
if(WIN32)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_opencollada after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/opencollada/ ${HARVEST_TARGET}/opencollada/
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
ExternalProject_Add_Step(external_opencollada after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/opencollada/lib/opencollada/buffer.lib ${HARVEST_TARGET}/opencollada/lib/opencollada/buffer_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/opencollada/lib/opencollada/ftoa.lib ${HARVEST_TARGET}/opencollada/lib/opencollada/ftoa_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/opencollada/lib/opencollada/GeneratedSaxParser.lib ${HARVEST_TARGET}/opencollada/lib/opencollada/GeneratedSaxParser_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/opencollada/lib/opencollada/MathMLSolver.lib ${HARVEST_TARGET}/opencollada/lib/opencollada/MathMLSolver_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/opencollada/lib/opencollada/OpenCOLLADABaseUtils.lib ${HARVEST_TARGET}/opencollada/lib/opencollada/OpenCOLLADABaseUtils_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/opencollada/lib/opencollada/OpenCOLLADAFramework.lib ${HARVEST_TARGET}/opencollada/lib/opencollada/OpenCOLLADAFramework_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/opencollada/lib/opencollada/OpenCOLLADASaxFrameworkLoader.lib ${HARVEST_TARGET}/opencollada/lib/opencollada/OpenCOLLADASaxFrameworkLoader_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/opencollada/lib/opencollada/OpenCOLLADAStreamWriter.lib ${HARVEST_TARGET}/opencollada/lib/opencollada/OpenCOLLADAStreamWriter_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/opencollada/lib/opencollada/pcre.lib ${HARVEST_TARGET}/opencollada/lib/opencollada/pcre_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/opencollada/lib/opencollada/UTF.lib ${HARVEST_TARGET}/opencollada/lib/opencollada/UTF_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/opencollada/lib/opencollada/xml.lib ${HARVEST_TARGET}/opencollada/lib/opencollada/xml_d.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
endif()
|
@@ -1,112 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(OPENCOLORIO_EXTRA_ARGS
|
||||
-DOCIO_BUILD_APPS=OFF
|
||||
-DOCIO_BUILD_PYGLUE=OFF
|
||||
-DOCIO_BUILD_NUKE=OFF
|
||||
-DOCIO_USE_BOOST_PTR=OFF
|
||||
-DOCIO_BUILD_STATIC=ON
|
||||
-DOCIO_BUILD_SHARED=OFF
|
||||
-DOCIO_BUILD_TRUELIGHT=OFF
|
||||
-DOCIO_BUILD_DOCS=OFF
|
||||
-DOCIO_BUILD_PYGLUE=OFF
|
||||
-DOCIO_BUILD_JNIGLUE=OFF
|
||||
-DOCIO_STATIC_JNIGLUE=OFF
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
set(OCIO_PATCH opencolorio_win.diff)
|
||||
set(OPENCOLORIO_EXTRA_ARGS
|
||||
${OPENCOLORIO_EXTRA_ARGS}
|
||||
-DOCIO_BUILD_TESTS=OFF
|
||||
-DOCIO_USE_SSE=ON
|
||||
-DOCIO_INLINES_HIDDEN=OFF
|
||||
-DOCIO_PYGLUE_LINK=OFF
|
||||
-DOCIO_PYGLUE_RESPECT_ABI=OFF
|
||||
-DOCIO_PYGLUE_SONAME=OFF
|
||||
-DOCIO_PYGLUE_LIB_PREFIX=OFF
|
||||
-DUSE_EXTERNAL_TINYXML=ON
|
||||
-DTINYXML_INCLUDE_DIR=${LIBDIR}/tinyxml/include
|
||||
-DTINYXML_LIBRARY=${LIBDIR}/tinyxml/lib/tinyxml${libext}
|
||||
-DUSE_EXTERNAL_YAML=ON
|
||||
-DYAML_CPP_FOUND=ON
|
||||
-DYAML_CPP_VERSION=${YAMLCPP_VERSION}
|
||||
-DUSE_EXTERNAL_LCMS=ON
|
||||
-DINC_1=${LIBDIR}/tinyxml/include
|
||||
-DINC_2=${LIBDIR}/yamlcpp/include
|
||||
# Lie because ocio cmake is demanding boost even though it is not needed.
|
||||
-DYAML_CPP_VERSION=0.5.0
|
||||
)
|
||||
else()
|
||||
set(OCIO_PATCH opencolorio.diff)
|
||||
set(OPENCOLORIO_EXTRA_ARGS
|
||||
${OPENCOLORIO_EXTRA_ARGS}
|
||||
)
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_opencolorio
|
||||
URL ${OPENCOLORIO_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${OPENCOLORIO_HASH}
|
||||
PREFIX ${BUILD_DIR}/opencolorio
|
||||
PATCH_COMMAND ${PATCH_CMD} -p 1 -N -d ${BUILD_DIR}/opencolorio/src/external_opencolorio < ${PATCH_DIR}/${OCIO_PATCH}
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/opencolorio ${DEFAULT_CMAKE_FLAGS} ${OPENCOLORIO_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/opencolorio
|
||||
)
|
||||
|
||||
if(NOT WIN32)
|
||||
add_custom_command(
|
||||
OUTPUT ${LIBDIR}/opencolorio/lib/libtinyxml.a
|
||||
COMMAND cp ${BUILD_DIR}/opencolorio/src/external_opencolorio-build/ext/dist/lib/libtinyxml.a ${LIBDIR}/opencolorio/lib/libtinyxml.a
|
||||
COMMAND cp ${BUILD_DIR}/opencolorio/src/external_opencolorio-build/ext/dist/lib/libyaml-cpp.a ${LIBDIR}/opencolorio/lib/libyaml-cpp.a
|
||||
)
|
||||
add_custom_target(external_opencolorio_extra ALL DEPENDS external_opencolorio ${LIBDIR}/opencolorio/lib/libtinyxml.a)
|
||||
endif()
|
||||
|
||||
add_dependencies(
|
||||
external_opencolorio
|
||||
external_boost
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
add_dependencies(
|
||||
external_opencolorio
|
||||
external_tinyxml
|
||||
external_yamlcpp
|
||||
|
||||
)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_opencolorio after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/opencolorio/include ${HARVEST_TARGET}/opencolorio/include
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/opencolorio/lib/static ${HARVEST_TARGET}/opencolorio/lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/yamlcpp/lib/libyaml-cppmd.lib ${HARVEST_TARGET}/opencolorio/lib/libyaml-cpp.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/tinyxml/lib/tinyxml.lib ${HARVEST_TARGET}/opencolorio/lib/tinyxml.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
ExternalProject_Add_Step(external_opencolorio after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/opencolorio/lib/static/Opencolorio.lib ${HARVEST_TARGET}/opencolorio/lib/OpencolorIO_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/yamlcpp/lib/libyaml-cppmdd.lib ${HARVEST_TARGET}/opencolorio/lib/libyaml-cpp_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/tinyxml/lib/tinyxml.lib ${HARVEST_TARGET}/opencolorio/lib/tinyxml_d.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
|
||||
endif()
|
@@ -1,64 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(WIN32)
|
||||
set(OPENEXR_CMAKE_CXX_STANDARD_LIBRARIES "kernel32${LIBEXT} user32${LIBEXT} gdi32${LIBEXT} winspool${LIBEXT} shell32${LIBEXT} ole32${LIBEXT} oleaut32${LIBEXT} uuid${LIBEXT} comdlg32${LIBEXT} advapi32${LIBEXT} psapi${LIBEXT}")
|
||||
set(OPENEXR_EXTRA_ARGS
|
||||
-DCMAKE_CXX_STANDARD_LIBRARIES=${OPENEXR_CMAKE_CXX_STANDARD_LIBRARIES}
|
||||
)
|
||||
else()
|
||||
set(OPENEXR_EXTRA_ARGS
|
||||
)
|
||||
endif()
|
||||
|
||||
set(OPENEXR_EXTRA_ARGS
|
||||
${OPENEXR_EXTRA_ARGS}
|
||||
-DZLIB_LIBRARY=${LIBDIR}/zlib/lib/${ZLIB_LIBRARY}
|
||||
-DZLIB_INCLUDE_DIR=${LIBDIR}/zlib/include/
|
||||
-DBUILD_TESTING=OFF
|
||||
-DOPENEXR_BUILD_BOTH_STATIC_SHARED=OFF
|
||||
-DILMBASE_BUILD_BOTH_STATIC_SHARED=OFF
|
||||
-DBUILD_SHARED_LIBS=OFF
|
||||
-DOPENEXR_BUILD_UTILS=OFF
|
||||
-DPYILMBASE_ENABLE=OFF
|
||||
-DOPENEXR_VIEWERS_ENABLE=OFF
|
||||
-DILMBASE_LIB_SUFFIX=${OPENEXR_VERSION_BUILD_POSTFIX}
|
||||
-DOPENEXR_LIB_SUFFIX=${OPENEXR_VERSION_BUILD_POSTFIX}
|
||||
)
|
||||
|
||||
ExternalProject_Add(external_openexr
|
||||
URL ${OPENEXR_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${OPENEXR_HASH}
|
||||
PREFIX ${BUILD_DIR}/openexr
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/openexr ${DEFAULT_CMAKE_FLAGS} ${OPENEXR_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/openexr
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
ExternalProject_Add_Step(external_openexr after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/openexr/lib ${HARVEST_TARGET}/openexr/lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/openexr/include ${HARVEST_TARGET}/openexr/include
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
|
||||
add_dependencies(
|
||||
external_openexr
|
||||
external_zlib
|
||||
)
|
@@ -1,61 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
|
||||
set(OIDN_EXTRA_ARGS
|
||||
-DWITH_EXAMPLE=OFF
|
||||
-DWITH_TEST=OFF
|
||||
-DTBB_ROOT=${LIBDIR}/tbb
|
||||
-DTBB_STATIC_LIB=ON
|
||||
-DOIDN_STATIC_LIB=ON
|
||||
)
|
||||
|
||||
ExternalProject_Add(external_openimagedenoise
|
||||
URL ${OIDN_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${OIDN_HASH}
|
||||
PREFIX ${BUILD_DIR}/openimagedenoise
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/openimagedenoise ${DEFAULT_CMAKE_FLAGS} ${OIDN_EXTRA_ARGS}
|
||||
PATCH_COMMAND ${PATCH_CMD} --verbose -p 1 -N -d ${BUILD_DIR}/openimagedenoise/src/external_openimagedenoise < ${PATCH_DIR}/openimagedenoise.diff
|
||||
INSTALL_DIR ${LIBDIR}/openimagedenoise
|
||||
)
|
||||
|
||||
add_dependencies(
|
||||
external_openimagedenoise
|
||||
external_tbb
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_openimagedenoise after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/openimagedenoise/include ${HARVEST_TARGET}/openimagedenoise/include
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/openimagedenoise/lib/openimagedenoise.lib ${HARVEST_TARGET}/openimagedenoise/lib/openimagedenoise.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/openimagedenoise/lib/common.lib ${HARVEST_TARGET}/openimagedenoise/lib/common.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/openimagedenoise/lib/mkldnn.lib ${HARVEST_TARGET}/openimagedenoise/lib/mkldnn.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
ExternalProject_Add_Step(external_openimagedenoise after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/openimagedenoise/lib/openimagedenoise.lib ${HARVEST_TARGET}/openimagedenoise/lib/openimagedenoise_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/openimagedenoise/lib/common.lib ${HARVEST_TARGET}/openimagedenoise/lib/common_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/openimagedenoise/lib/mkldnn.lib ${HARVEST_TARGET}/openimagedenoise/lib/mkldnn_d.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
endif()
|
@@ -1,151 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
set(OIIO_TOOLS ON)
|
||||
else()
|
||||
set(OIIO_TOOLS OFF)
|
||||
endif()
|
||||
|
||||
if(UNIX AND NOT APPLE)
|
||||
# This causes linking to static pthread libraries which gives link errors.
|
||||
# Since we manually specify library paths it should static link other libs.
|
||||
set(OPENIMAGEIO_LINKSTATIC -DLINKSTATIC=OFF)
|
||||
else()
|
||||
set(OPENIMAGEIO_LINKSTATIC -DLINKSTATIC=ON)
|
||||
endif()
|
||||
|
||||
if(WIN32)
|
||||
set(PNG_LIBNAME libpng16_static${LIBEXT})
|
||||
set(OIIO_SIMD_FLAGS -DUSE_SIMD=sse2 -DOPJ_STATIC=1)
|
||||
set(OPENJPEG_POSTFIX _msvc)
|
||||
else()
|
||||
set(PNG_LIBNAME libpng${LIBEXT})
|
||||
set(OIIO_SIMD_FLAGS)
|
||||
endif()
|
||||
|
||||
if(WITH_WEBP)
|
||||
set(WEBP_ARGS
|
||||
-DWEBP_INCLUDE_DIR=${LIBDIR}/webp/include
|
||||
-DWEBP_LIBRARY=${LIBDIR}/webp/lib/${LIBPREFIX}webp${LIBEXT}
|
||||
)
|
||||
set(WEBP_DEP external_webp)
|
||||
endif()
|
||||
|
||||
if(MSVC)
|
||||
set(OPENJPEG_FLAGS
|
||||
-DOPENJPEG_HOME=${LIBDIR}/openjpeg_msvc
|
||||
-DOPENJPEG_INCLUDE_DIR=${LIBDIR}/openjpeg_msvc/include/openjpeg-${OPENJPEG_SHORT_VERSION}
|
||||
-DOPENJPEG_LIBRARY=${LIBDIR}/openjpeg_msvc/lib/openjp2${LIBEXT}
|
||||
-DOPENJPEG_LIBRARY_DEBUG=${LIBDIR}/openjpeg_msvc/lib/openjp2${LIBEXT}
|
||||
)
|
||||
else()
|
||||
set(OPENJPEG_FLAGS
|
||||
-DOPENJPEG_INCLUDE_DIR=${LIBDIR}/openjpeg/include/openjpeg-${OPENJPEG_SHORT_VERSION}
|
||||
-DOPENJPEG_LIBRARY=${LIBDIR}/openjpeg/lib/${OPENJPEG_LIBRARY}
|
||||
)
|
||||
endif()
|
||||
|
||||
set(OPENIMAGEIO_EXTRA_ARGS
|
||||
-DBUILDSTATIC=ON
|
||||
${OPENIMAGEIO_LINKSTATIC}
|
||||
-DOPENEXR_INCLUDE_DIR=${LIBDIR}/openexr/include/openexr/
|
||||
-DOPENEXR_ILMIMF_LIBRARIES=${LIBDIR}/openexr/lib/IlmImf${OPENEXR_VERSION_POSTFIX}${LIBEXT}
|
||||
-DBoost_COMPILER:STRING=${BOOST_COMPILER_STRING}
|
||||
-DBoost_USE_MULTITHREADED=ON
|
||||
-DBoost_USE_STATIC_LIBS=ON
|
||||
-DBoost_USE_STATIC_RUNTIME=OFF
|
||||
-DBOOST_ROOT=${LIBDIR}/boost
|
||||
-DBOOST_LIBRARYDIR=${LIBDIR}/boost/lib/
|
||||
-DBoost_NO_SYSTEM_PATHS=ON
|
||||
-OIIO_BUILD_CPP11=ON
|
||||
-DUSE_OPENGL=OFF
|
||||
-DUSE_TBB=OFF
|
||||
-DUSE_FIELD3D=OFF
|
||||
-DUSE_QT=OFF
|
||||
-DUSE_PYTHON=OFF
|
||||
-DUSE_GIF=OFF
|
||||
-DUSE_OPENCV=OFF
|
||||
-DUSE_OPENSSL=OFF
|
||||
-DUSE_OPENJPEG=ON
|
||||
-DUSE_FFMPEG=OFF
|
||||
-DUSE_PTEX=OFF
|
||||
-DUSE_FREETYPE=OFF
|
||||
-DUSE_LIBRAW=OFF
|
||||
-DUSE_PYTHON=OFF
|
||||
-DUSE_PYTHON3=OFF
|
||||
-DUSE_OCIO=OFF
|
||||
-DUSE_WEBP=${WITH_WEBP}
|
||||
-DOIIO_BUILD_TOOLS=${OIIO_TOOLS}
|
||||
-DOIIO_BUILD_TESTS=OFF
|
||||
-DBUILD_TESTING=OFF
|
||||
-DZLIB_LIBRARY=${LIBDIR}/zlib/lib/${ZLIB_LIBRARY}
|
||||
-DZLIB_INCLUDE_DIR=${LIBDIR}/zlib/include
|
||||
-DPNG_LIBRARY=${LIBDIR}/png/lib/${PNG_LIBNAME}
|
||||
-DPNG_PNG_INCLUDE_DIR=${LIBDIR}/png/include
|
||||
-DTIFF_LIBRARY=${LIBDIR}/tiff/lib/${LIBPREFIX}tiff${LIBEXT}
|
||||
-DTIFF_INCLUDE_DIR=${LIBDIR}/tiff/include
|
||||
-DJPEG_LIBRARY=${LIBDIR}/jpg/lib/${JPEG_LIBRARY}
|
||||
-DJPEG_INCLUDE_DIR=${LIBDIR}/jpg/include
|
||||
${OPENJPEG_FLAGS}
|
||||
-DOCIO_PATH=${LIBDIR}/opencolorio/
|
||||
-DOpenEXR_USE_STATIC_LIBS=On
|
||||
-DOPENEXR_HOME=${LIBDIR}/openexr/
|
||||
-DILMBASE_INCLUDE_PATH=${LIBDIR}/openexr/
|
||||
-DILMBASE_PACKAGE_PREFIX=${LIBDIR}/openexr/
|
||||
-DILMBASE_INCLUDE_DIR=${LIBDIR}/openexr/include/
|
||||
-DOPENEXR_HALF_LIBRARY=${LIBDIR}/openexr/lib/${LIBPREFIX}Half${OPENEXR_VERSION_POSTFIX}${LIBEXT}
|
||||
-DOPENEXR_IMATH_LIBRARY=${LIBDIR}/openexr/lib/${LIBPREFIX}Imath${OPENEXR_VERSION_POSTFIX}${LIBEXT}
|
||||
-DOPENEXR_ILMTHREAD_LIBRARY=${LIBDIR}/openexr/lib/${LIBPREFIX}IlmThread${OPENEXR_VERSION_POSTFIX}${LIBEXT}
|
||||
-DOPENEXR_IEX_LIBRARY=${LIBDIR}/openexr/lib/${LIBPREFIX}Iex${OPENEXR_VERSION_POSTFIX}${LIBEXT}
|
||||
-DOPENEXR_INCLUDE_DIR=${LIBDIR}/openexr/include/
|
||||
-DOPENEXR_ILMIMF_LIBRARY=${LIBDIR}/openexr/lib/${LIBPREFIX}IlmImf${OPENEXR_VERSION_POSTFIX}${LIBEXT}
|
||||
-DSTOP_ON_WARNING=OFF
|
||||
${WEBP_FLAGS}
|
||||
${OIIO_SIMD_FLAGS}
|
||||
)
|
||||
|
||||
ExternalProject_Add(external_openimageio
|
||||
URL ${OPENIMAGEIO_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${OPENIMAGEIO_HASH}
|
||||
PREFIX ${BUILD_DIR}/openimageio
|
||||
PATCH_COMMAND
|
||||
${PATCH_CMD} -p 0 -N -d ${BUILD_DIR}/openimageio/src/external_openimageio/src/include < ${PATCH_DIR}/openimageio_gdi.diff &&
|
||||
${PATCH_CMD} -p 1 -N -d ${BUILD_DIR}/openimageio/src/external_openimageio/ < ${PATCH_DIR}/openimageio_static_libs.diff
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/openimageio ${DEFAULT_CMAKE_FLAGS} ${OPENIMAGEIO_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/openimageio
|
||||
)
|
||||
|
||||
add_dependencies(
|
||||
external_openimageio
|
||||
external_png external_zlib
|
||||
external_openexr
|
||||
external_jpeg
|
||||
external_boost
|
||||
external_tiff
|
||||
external_opencolorio
|
||||
external_openjpeg${OPENJPEG_POSTFIX}
|
||||
${WEBP_DEP}
|
||||
)
|
||||
if(NOT WIN32)
|
||||
add_dependencies(
|
||||
external_openimageio
|
||||
external_opencolorio_extra
|
||||
)
|
||||
endif()
|
@@ -1,64 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
# Note the encoder/decoder may use png/tiff/lcms system libraries, but the
|
||||
# library itself does not depend on them, so should give no problems.
|
||||
|
||||
set(OPENJPEG_EXTRA_ARGS -DBUILD_SHARED_LIBS=OFF)
|
||||
|
||||
if(WIN32)
|
||||
set(OPENJPEG_EXTRA_ARGS -G "MSYS Makefiles" -DBUILD_PKGCONFIG_FILES=On)
|
||||
else()
|
||||
set(OPENJPEG_EXTRA_ARGS ${DEFAULT_CMAKE_FLAGS})
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_openjpeg
|
||||
URL ${OPENJPEG_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH SHA256=${OPENJPEG_HASH}
|
||||
PREFIX ${BUILD_DIR}/openjpeg
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/openjpeg/src/external_openjpeg-build && ${CMAKE_COMMAND} ${OPENJPEG_EXTRA_ARGS} -DCMAKE_INSTALL_PREFIX=${LIBDIR}/openjpeg -DBUILD_SHARED_LIBS=Off -DBUILD_THIRDPARTY=OFF ${BUILD_DIR}/openjpeg/src/external_openjpeg
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/openjpeg/src/external_openjpeg-build/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/openjpeg/src/external_openjpeg-build/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/openjpeg
|
||||
)
|
||||
|
||||
# On windows ffmpeg wants a mingw build, while oiio needs a msvc build.
|
||||
if(MSVC)
|
||||
set(OPENJPEG_EXTRA_ARGS ${DEFAULT_CMAKE_FLAGS})
|
||||
ExternalProject_Add(external_openjpeg_msvc
|
||||
URL ${OPENJPEG_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH SHA256=${OPENJPEG_HASH}
|
||||
PREFIX ${BUILD_DIR}/openjpeg_msvc
|
||||
CMAKE_ARGS ${OPENJPEG_EXTRA_ARGS} -DCMAKE_INSTALL_PREFIX=${LIBDIR}/openjpeg_msvc -DBUILD_SHARED_LIBS=Off -DBUILD_THIRDPARTY=OFF
|
||||
INSTALL_DIR ${LIBDIR}/openjpeg_msvc
|
||||
)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_openjpeg_msvc after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/openjpeg_msvc/lib ${HARVEST_TARGET}/openjpeg/lib &&
|
||||
${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/openjpeg_msvc/include ${HARVEST_TARGET}/openjpeg/include
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
set(OPENJPEG_LIBRARY libopenjp2${LIBEXT})
|
||||
if(MSVC)
|
||||
set_target_properties(external_openjpeg PROPERTIES FOLDER Mingw)
|
||||
endif()
|
@@ -1,33 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
|
||||
ExternalProject_Add(external_openmp
|
||||
URL ${OPENMP_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${OPENMP_HASH}
|
||||
PREFIX ${BUILD_DIR}/openmp
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/openmp ${DEFAULT_CMAKE_FLAGS}
|
||||
INSTALL_COMMAND cd ${BUILD_DIR}/openmp/src/external_openmp-build && install_name_tool -id @executable_path/../Resources/lib/libomp.dylib runtime/src/libomp.dylib && make install
|
||||
INSTALL_DIR ${LIBDIR}/openmp
|
||||
)
|
||||
|
||||
add_dependencies(
|
||||
external_openmp
|
||||
external_clang
|
||||
)
|
@@ -1,100 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(OPENSUBDIV_EXTRA_ARGS
|
||||
-DNO_EXAMPLES=ON
|
||||
-DNO_REGRESSION=ON
|
||||
-DNO_PYTHON=ON
|
||||
-DNO_MAYA=ON
|
||||
-DNO_PTEX=ON
|
||||
-DNO_DOC=ON
|
||||
-DNO_CLEW=OFF
|
||||
-DNO_OPENCL=OFF
|
||||
-DNO_TUTORIALS=ON
|
||||
-DGLEW_INCLUDE_DIR=${LIBDIR}/glew/include
|
||||
-DGLEW_LIBRARY=${LIBDIR}/glew/lib/libGLEW${LIBEXT}
|
||||
-DGLFW_INCLUDE_DIR=${LIBDIR}/glfw/include
|
||||
-DGLFW_LIBRARIES=${LIBDIR}/glfw/lib/glfw3${LIBEXT}
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
set(OPENSUBDIV_EXTRA_ARGS
|
||||
${OPENSUBDIV_EXTRA_ARGS}
|
||||
-DTBB_INCLUDE_DIR=${LIBDIR}/tbb/include
|
||||
-DTBB_LIBRARIES=${LIBDIR}/tbb/lib/tbb_static.lib
|
||||
-DCLEW_INCLUDE_DIR=${LIBDIR}/clew/include/CL
|
||||
-DCLEW_LIBRARY=${LIBDIR}/clew/lib/clew${LIBEXT}
|
||||
-DCUEW_INCLUDE_DIR=${LIBDIR}/cuew/include
|
||||
-DCUEW_LIBRARY=${LIBDIR}/cuew/lib/cuew${LIBEXT}
|
||||
)
|
||||
if("${CMAKE_SIZEOF_VOID_P}" EQUAL "8")
|
||||
set(OPENSUBDIV_EXTRA_ARGS
|
||||
${OPENSUBDIV_EXTRA_ARGS}
|
||||
-DNO_CUDA=OFF
|
||||
)
|
||||
else()
|
||||
set(OPENSUBDIV_EXTRA_ARGS
|
||||
${OPENSUBDIV_EXTRA_ARGS}
|
||||
-DNO_CUDA=ON
|
||||
)
|
||||
endif()
|
||||
|
||||
else()
|
||||
set(OPENSUBDIV_EXTRA_ARGS
|
||||
${OPENSUBDIV_EXTRA_ARGS}
|
||||
-DNO_CUDA=ON
|
||||
-DCUEW_INCLUDE_DIR=${LIBDIR}/cuew/include
|
||||
-DCLEW_INCLUDE_DIR=${LIBDIR}/clew/include/CL
|
||||
-DCLEW_LIBRARY=${LIBDIR}/clew/lib/static/${LIBPREFIX}clew${LIBEXT}
|
||||
)
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_opensubdiv
|
||||
URL ${OPENSUBDIV_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${OPENSUBDIV_Hash}
|
||||
PREFIX ${BUILD_DIR}/opensubdiv
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/opensubdiv -Wno-dev ${DEFAULT_CMAKE_FLAGS} ${OPENSUBDIV_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/opensubdiv
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_opensubdiv after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/opensubdiv/lib ${HARVEST_TARGET}/opensubdiv/lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/opensubdiv/include ${HARVEST_TARGET}/opensubdiv/include
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
ExternalProject_Add_Step(external_opensubdiv after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/opensubdiv/lib/osdCPU.lib ${HARVEST_TARGET}/opensubdiv/lib/osdCPU_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/opensubdiv/lib/osdGPU.lib ${HARVEST_TARGET}/opensubdiv/lib/osdGPU_d.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
add_dependencies(
|
||||
external_opensubdiv
|
||||
external_glew
|
||||
external_glfw
|
||||
external_clew
|
||||
external_cuew
|
||||
external_tbb
|
||||
)
|
@@ -1,99 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
set(BLOSC_POST _d)
|
||||
endif()
|
||||
|
||||
set(OPENVDB_EXTRA_ARGS
|
||||
-DBoost_COMPILER:STRING=${BOOST_COMPILER_STRING}
|
||||
-DBoost_USE_MULTITHREADED=ON
|
||||
-DBoost_USE_STATIC_LIBS=ON
|
||||
-DBoost_USE_STATIC_RUNTIME=OFF
|
||||
-DBOOST_ROOT=${LIBDIR}/boost
|
||||
-DBoost_NO_SYSTEM_PATHS=ON
|
||||
-DZLIB_LIBRARY=${LIBDIR}/zlib/lib/${ZLIB_LIBRARY}
|
||||
-DZLIB_INCLUDE_DIR=${LIBDIR}/zlib/include/
|
||||
-DBlosc_INCLUDE_DIR=${LIBDIR}/blosc/include/
|
||||
-DBlosc_LIBRARY=${LIBDIR}/blosc/lib/libblosc${BLOSC_POST}${LIBEXT}
|
||||
-DOPENVDB_ENABLE_3_ABI_COMPATIBLE=OFF
|
||||
-DOPENVDB_BUILD_UNITTESTS=Off
|
||||
-DOPENVDB_BUILD_PYTHON_MODULE=Off
|
||||
-DBlosc_ROOT=${LIBDIR}/blosc/
|
||||
-DTBB_ROOT=${LIBDIR}/tbb/
|
||||
-DOpenEXR_ROOT=${LIBDIR}/openexr
|
||||
-DIlmBase_ROOT=${LIBDIR}/openexr
|
||||
-DOPENEXR_LIBRARYDIR=${LIBDIR}/openexr/lib
|
||||
# All libs live in openexr, even the ilmbase ones
|
||||
-DILMBASE_LIBRARYDIR=${LIBDIR}/openexr/lib
|
||||
-DOPENVDB_CORE_SHARED=Off
|
||||
-DOPENVDB_BUILD_BINARIES=Off
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
# Namespaces seem to be buggy and cause linker errors due to things not
|
||||
# being in the correct namespace
|
||||
# needs to link pthreads due to it being a blosc dependency
|
||||
set(OPENVDB_EXTRA_ARGS ${OPENVDB_EXTRA_ARGS}
|
||||
-DCMAKE_CXX_STANDARD_LIBRARIES="${LIBDIR}/pthreads/lib/pthreadVC3.lib"
|
||||
-DUSE_EXR=On
|
||||
)
|
||||
else()
|
||||
# OpenVDB can't find the _static libraries automatically.
|
||||
set(OPENVDB_EXTRA_ARGS ${OPENVDB_EXTRA_ARGS}
|
||||
-DTbb_LIBRARIES=${LIBDIR}/tbb/lib/${LIBPREFIX}tbb_static${LIBEXT}
|
||||
-DTbb_tbb_LIBRARY=${LIBDIR}/tbb/lib/${LIBPREFIX}tbb_static${LIBEXT}
|
||||
-DTbb_tbbmalloc_LIBRARY=${LIBDIR}/tbb/lib/${LIBPREFIX}tbbmalloc_static${LIBEXT}
|
||||
-DTbb_tbbmalloc_proxy_LIBRARY=${LIBDIR}/tbb/lib/${LIBPREFIX}tbbmalloc_proxy_static${LIBEXT}
|
||||
)
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(openvdb
|
||||
URL ${OPENVDB_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${OPENVDB_HASH}
|
||||
PREFIX ${BUILD_DIR}/openvdb
|
||||
PATCH_COMMAND ${PATCH_CMD} -p 1 -d ${BUILD_DIR}/openvdb/src/openvdb < ${PATCH_DIR}/openvdb.diff
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/openvdb ${DEFAULT_CMAKE_FLAGS} ${OPENVDB_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/openvdb
|
||||
)
|
||||
|
||||
add_dependencies(
|
||||
openvdb
|
||||
external_tbb
|
||||
external_boost
|
||||
external_openexr
|
||||
external_zlib
|
||||
external_blosc
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(openvdb after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/openvdb/include ${HARVEST_TARGET}/openvdb/include
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/openvdb/lib/libopenvdb.lib ${HARVEST_TARGET}/openvdb/lib/openvdb.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
ExternalProject_Add_Step(openvdb after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/openvdb/lib/libopenvdb.lib ${HARVEST_TARGET}/openvdb/lib/openvdb_d.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
endif()
|
@@ -1,217 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(WIN32)
|
||||
option(ENABLE_MINGW64 "Enable building of ffmpeg/iconv/libsndfile/lapack/fftw3 by installing mingw64" ON)
|
||||
endif()
|
||||
option(WITH_WEBP "Enable building of oiio with webp support" OFF)
|
||||
set(MAKE_THREADS 1 CACHE STRING "Number of threads to run make with")
|
||||
|
||||
if(NOT BUILD_MODE)
|
||||
set(BUILD_MODE "Release")
|
||||
message(STATUS "Build type not specified: defaulting to a release build.")
|
||||
endif()
|
||||
message("BuildMode = ${BUILD_MODE}")
|
||||
|
||||
if(BUILD_MODE STREQUAL "Debug")
|
||||
set(LIBDIR ${CMAKE_CURRENT_BINARY_DIR}/Debug)
|
||||
else(BUILD_MODE STREQUAL "Debug")
|
||||
set(LIBDIR ${CMAKE_CURRENT_BINARY_DIR}/Release)
|
||||
endif()
|
||||
|
||||
option(DOWNLOAD_DIR "Path for downloaded files" ${CMAKE_CURRENT_SOURCE_DIR}/downloads)
|
||||
file(TO_CMAKE_PATH ${DOWNLOAD_DIR} DOWNLOAD_DIR)
|
||||
set(PATCH_DIR ${CMAKE_CURRENT_SOURCE_DIR}/patches)
|
||||
set(BUILD_DIR ${CMAKE_CURRENT_BINARY_DIR}/build)
|
||||
|
||||
message("LIBDIR = ${LIBDIR}")
|
||||
message("DOWNLOAD_DIR = ${DOWNLOAD_DIR}")
|
||||
message("PATCH_DIR = ${PATCH_DIR}")
|
||||
message("BUILD_DIR = ${BUILD_DIR}")
|
||||
|
||||
if(WIN32)
|
||||
if("${CMAKE_SIZEOF_VOID_P}" EQUAL "8")
|
||||
set(PATCH_CMD ${DOWNLOAD_DIR}/mingw/mingw64/msys/1.0/bin/patch.exe)
|
||||
else()
|
||||
set(PATCH_CMD ${DOWNLOAD_DIR}/mingw/mingw32/msys/1.0/bin/patch.exe)
|
||||
endif()
|
||||
set(LIBEXT ".lib")
|
||||
set(LIBPREFIX "")
|
||||
|
||||
# For OIIO and OSL
|
||||
set(COMMON_DEFINES /DPSAPI_VERSION=1 /DOIIO_STATIC_BUILD /DTINYFORMAT_ALLOW_WCHAR_STRINGS)
|
||||
|
||||
if(MSVC_VERSION GREATER 1909)
|
||||
set(COMMON_MSVC_FLAGS "/Wv:18") #some deps with warnings as error aren't quite ready for dealing with the new 2017 warnings.
|
||||
endif()
|
||||
set(COMMON_MSVC_FLAGS "${COMMON_MSVC_FLAGS} /bigobj")
|
||||
if(WITH_OPTIMIZED_DEBUG)
|
||||
set(BLENDER_CMAKE_C_FLAGS_DEBUG "/MDd ${COMMON_MSVC_FLAGS} /O2 /Ob2 /DNDEBUG /DPSAPI_VERSION=1 /DOIIO_STATIC_BUILD /DTINYFORMAT_ALLOW_WCHAR_STRINGS")
|
||||
else()
|
||||
set(BLENDER_CMAKE_C_FLAGS_DEBUG "/MDd ${COMMON_MSVC_FLAGS} /Zi /Ob0 /Od /RTC1 /D_DEBUG /DPSAPI_VERSION=1 /DOIIO_STATIC_BUILD /DTINYFORMAT_ALLOW_WCHAR_STRINGS")
|
||||
endif()
|
||||
set(BLENDER_CMAKE_C_FLAGS_MINSIZEREL "/MD ${COMMON_MSVC_FLAGS} /O1 /Ob1 /D NDEBUG /DPSAPI_VERSION=1 /DOIIO_STATIC_BUILD /DTINYFORMAT_ALLOW_WCHAR_STRINGS")
|
||||
set(BLENDER_CMAKE_C_FLAGS_RELEASE "/MD ${COMMON_MSVC_FLAGS} /O2 /Ob2 /DNDEBUG /DPSAPI_VERSION=1 /DOIIO_STATIC_BUILD /DTINYFORMAT_ALLOW_WCHAR_STRINGS")
|
||||
set(BLENDER_CMAKE_C_FLAGS_RELWITHDEBINFO "/MD ${COMMON_MSVC_FLAGS} /Zi /O2 /Ob1 /D NDEBUG /DPSAPI_VERSION=1 /DOIIO_STATIC_BUILD /DTINYFORMAT_ALLOW_WCHAR_STRINGS")
|
||||
|
||||
if(WITH_OPTIMIZED_DEBUG)
|
||||
set(BLENDER_CMAKE_CXX_FLAGS_DEBUG "/MDd ${COMMON_MSVC_FLAGS} /O2 /Ob2 /D NDEBUG /D PLATFORM_WINDOWS /DPSAPI_VERSION=1 /DOIIO_STATIC_BUILD /DTINYFORMAT_ALLOW_WCHAR_STRINGS")
|
||||
else()
|
||||
set(BLENDER_CMAKE_CXX_FLAGS_DEBUG "/D_DEBUG /D PLATFORM_WINDOWS /MTd ${COMMON_MSVC_FLAGS} /Zi /Ob0 /Od /RTC1 /DPSAPI_VERSION=1 /DOIIO_STATIC_BUILD /DTINYFORMAT_ALLOW_WCHAR_STRINGS")
|
||||
endif()
|
||||
set(BLENDER_CMAKE_CXX_FLAGS_MINSIZEREL "/MD /${COMMON_MSVC_FLAGS} /O1 /Ob1 /D NDEBUG /D PLATFORM_WINDOWS /DPSAPI_VERSION=1 /DOIIO_STATIC_BUILD /DTINYFORMAT_ALLOW_WCHAR_STRINGS")
|
||||
set(BLENDER_CMAKE_CXX_FLAGS_RELEASE "/MD ${COMMON_MSVC_FLAGS} /O2 /Ob2 /D NDEBUG /D PLATFORM_WINDOWS /DPSAPI_VERSION=1 /DOIIO_STATIC_BUILD /DTINYFORMAT_ALLOW_WCHAR_STRINGS")
|
||||
set(BLENDER_CMAKE_CXX_FLAGS_RELWITHDEBINFO "/MD ${COMMON_MSVC_FLAGS} /Zi /O2 /Ob1 /D NDEBUG /D PLATFORM_WINDOWS /DPSAPI_VERSION=1 /DOIIO_STATIC_BUILD /DTINYFORMAT_ALLOW_WCHAR_STRINGS")
|
||||
|
||||
set(PLATFORM_FLAGS)
|
||||
set(PLATFORM_CXX_FLAGS)
|
||||
set(PLATFORM_CMAKE_FLAGS)
|
||||
|
||||
if("${CMAKE_SIZEOF_VOID_P}" EQUAL "8")
|
||||
set(MINGW_PATH ${DOWNLOAD_DIR}/mingw/mingw64)
|
||||
set(MINGW_SHELL ming64sh.cmd)
|
||||
set(PERL_SHELL ${DOWNLOAD_DIR}/perl/portableshell.bat)
|
||||
set(MINGW_HOST x86_64-w64-mingw32)
|
||||
else()
|
||||
set(MINGW_PATH ${DOWNLOAD_DIR}/mingw/mingw32)
|
||||
set(MINGW_SHELL ming32sh.cmd)
|
||||
set(PERL_SHELL ${DOWNLOAD_DIR}/perl32/portableshell.bat)
|
||||
set(MINGW_HOST i686-w64-mingw32)
|
||||
endif()
|
||||
|
||||
set(CONFIGURE_ENV
|
||||
cd ${MINGW_PATH} &&
|
||||
call ${PERL_SHELL} &&
|
||||
call ${MINGW_SHELL} &&
|
||||
set path &&
|
||||
set CFLAGS=-g &&
|
||||
set LDFLAGS=-Wl,--as-needed -static-libgcc
|
||||
)
|
||||
|
||||
set(CONFIGURE_ENV_NO_PERL
|
||||
cd ${MINGW_PATH} &&
|
||||
call ${MINGW_SHELL} &&
|
||||
set path &&
|
||||
set CFLAGS=-g &&
|
||||
set LDFLAGS=-Wl,--as-needed -static-libgcc
|
||||
)
|
||||
|
||||
set(CONFIGURE_COMMAND sh ./configure)
|
||||
set(CONFIGURE_COMMAND_NO_TARGET ${CONFIGURE_COMMAND})
|
||||
else()
|
||||
set(PATCH_CMD patch)
|
||||
set(LIBEXT ".a")
|
||||
set(LIBPREFIX "lib")
|
||||
|
||||
if(APPLE)
|
||||
# Let's get the current Xcode dir, to support xcode-select
|
||||
execute_process(
|
||||
COMMAND xcode-select --print-path
|
||||
OUTPUT_VARIABLE XCODE_DEV_PATH OUTPUT_STRIP_TRAILING_WHITESPACE
|
||||
)
|
||||
set(OSX_ARCHITECTURES x86_64)
|
||||
set(OSX_DEPLOYMENT_TARGET 10.11)
|
||||
set(OSX_SYSROOT ${XCODE_DEV_PATH}/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk)
|
||||
|
||||
set(PLATFORM_CFLAGS "-isysroot ${OSX_SYSROOT} -mmacosx-version-min=${OSX_DEPLOYMENT_TARGET}")
|
||||
set(PLATFORM_CXXFLAGS "-isysroot ${OSX_SYSROOT} -mmacosx-version-min=${OSX_DEPLOYMENT_TARGET} -std=c++11 -stdlib=libc++")
|
||||
set(PLATFORM_LDFLAGS "-isysroot ${OSX_SYSROOT} -mmacosx-version-min=${OSX_DEPLOYMENT_TARGET}")
|
||||
set(PLATFORM_BUILD_TARGET --build=x86_64-apple-darwin15.0.0) # OS X 10.11
|
||||
set(PLATFORM_CMAKE_FLAGS
|
||||
-DCMAKE_OSX_ARCHITECTURES:STRING=${OSX_ARCHITECTURES}
|
||||
-DCMAKE_OSX_DEPLOYMENT_TARGET:STRING=${OSX_DEPLOYMENT_TARGET}
|
||||
-DCMAKE_OSX_SYSROOT:PATH=${OSX_SYSROOT}
|
||||
)
|
||||
else()
|
||||
set(PLATFORM_CFLAGS "-fPIC")
|
||||
set(PLATFORM_CXXFLAGS "-std=c++11 -fPIC")
|
||||
set(PLATFORM_LDFLAGS)
|
||||
set(PLATFORM_BUILD_TARGET)
|
||||
set(PLATFORM_CMAKE_FLAGS -DCMAKE_INSTALL_LIBDIR=lib)
|
||||
endif()
|
||||
|
||||
if(WITH_OPTIMIZED_DEBUG)
|
||||
set(BLENDER_CMAKE_C_FLAGS_DEBUG "-O2 -DNDEBUG ${PLATFORM_CFLAGS}")
|
||||
else()
|
||||
set(BLENDER_CMAKE_C_FLAGS_DEBUG "-g ${PLATFORM_CFLAGS}")
|
||||
endif()
|
||||
set(BLENDER_CMAKE_C_FLAGS_MINSIZEREL "-Os -DNDEBUG ${PLATFORM_CFLAGS}")
|
||||
set(BLENDER_CMAKE_C_FLAGS_RELEASE "-O2 -DNDEBUG ${PLATFORM_CFLAGS}")
|
||||
set(BLENDER_CMAKE_C_FLAGS_RELWITHDEBINFO "-O2 -g -DNDEBUG ${PLATFORM_CFLAGS}")
|
||||
|
||||
if(WITH_OPTIMIZED_DEBUG)
|
||||
set(BLENDER_CMAKE_CXX_FLAGS_DEBUG "-O2 -DNDEBUG ${PLATFORM_CXXFLAGS}")
|
||||
else()
|
||||
set(BLENDER_CMAKE_CXX_FLAGS_DEBUG "-g ${PLATFORM_CXXFLAGS}")
|
||||
endif()
|
||||
|
||||
set(BLENDER_CMAKE_CXX_FLAGS_MINSIZEREL "-Os -DNDEBUG ${PLATFORM_CXXFLAGS}")
|
||||
set(BLENDER_CMAKE_CXX_FLAGS_RELEASE "-O2 -DNDEBUG ${PLATFORM_CXXFLAGS}")
|
||||
set(BLENDER_CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DNDEBUG ${PLATFORM_CXXFLAGS}")
|
||||
|
||||
set(CONFIGURE_ENV
|
||||
export MACOSX_DEPLOYMENT_TARGET=${OSX_DEPLOYMENT_TARGET} &&
|
||||
export CFLAGS=${PLATFORM_CFLAGS} &&
|
||||
export CXXFLAGS=${PLATFORM_CXXFLAGS} &&
|
||||
export LDFLAGS=${PLATFORM_LDFLAGS}
|
||||
)
|
||||
set(CONFIGURE_ENV_NO_PERL ${CONFIGURE_ENV})
|
||||
set(CONFIGURE_COMMAND ./configure ${PLATFORM_BUILD_TARGET})
|
||||
set(CONFIGURE_COMMAND_NO_TARGET ./configure)
|
||||
endif()
|
||||
|
||||
set(DEFAULT_CMAKE_FLAGS
|
||||
-DCMAKE_BUILD_TYPE=${BUILD_MODE}
|
||||
-DCMAKE_C_FLAGS_DEBUG=${BLENDER_CMAKE_C_FLAGS_DEBUG}
|
||||
-DCMAKE_C_FLAGS_MINSIZEREL=${BLENDER_CMAKE_C_FLAGS_MINSIZEREL}
|
||||
-DCMAKE_C_FLAGS_RELEASE=${BLENDER_CMAKE_C_FLAGS_RELEASE}
|
||||
-DCMAKE_C_FLAGS_RELWITHDEBINFO=${BLENDER_CMAKE_C_FLAGS_RELWITHDEBINFO}
|
||||
-DCMAKE_CXX_FLAGS_DEBUG=${BLENDER_CMAKE_CXX_FLAGS_DEBUG}
|
||||
-DCMAKE_CXX_FLAGS_MINSIZEREL=${BLENDER_CMAKE_CXX_FLAGS_MINSIZEREL}
|
||||
-DCMAKE_CXX_FLAGS_RELEASE=${BLENDER_CMAKE_CXX_FLAGS_RELEASE}
|
||||
-DCMAKE_CXX_FLAGS_RELWITHDEBINFO=${CMAKE_CXX_FLAGS_RELWITHDEBINFO}
|
||||
${PLATFORM_CMAKE_FLAGS}
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
# We need both flavors to build the thumbnail dlls
|
||||
if(MSVC12)
|
||||
set(GENERATOR_32 "Visual Studio 12 2013")
|
||||
set(GENERATOR_64 "Visual Studio 12 2013 Win64")
|
||||
elseif(MSVC14)
|
||||
set(GENERATOR_32 "Visual Studio 14 2015")
|
||||
set(GENERATOR_64 "Visual Studio 14 2015 Win64")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
||||
if(WIN32)
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
set(ZLIB_LIBRARY zlibstaticd${LIBEXT})
|
||||
else()
|
||||
set(ZLIB_LIBRARY zlibstatic${LIBEXT})
|
||||
endif()
|
||||
else()
|
||||
set(ZLIB_LIBRARY libz${LIBEXT})
|
||||
endif()
|
||||
|
||||
if(MSVC)
|
||||
set_property(GLOBAL PROPERTY USE_FOLDERS ON)
|
||||
endif()
|
||||
|
||||
set(CMAKE_INSTALL_MESSAGE LAZY)
|
@@ -1,35 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
ExternalProject_Add(external_opus
|
||||
URL ${OPUS_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH SHA256=${OPUS_HASH}
|
||||
PREFIX ${BUILD_DIR}/opus
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/opus/src/external_opus/ && ${CONFIGURE_COMMAND} --prefix=${LIBDIR}/opus
|
||||
--disable-shared
|
||||
--enable-static
|
||||
--with-pic
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/opus/src/external_opus/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/opus/src/external_opus/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/opus
|
||||
)
|
||||
|
||||
if(MSVC)
|
||||
set_target_properties(external_opus PROPERTIES FOLDER Mingw)
|
||||
endif()
|
@@ -1,141 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(WIN32)
|
||||
set(OSL_CMAKE_CXX_STANDARD_LIBRARIES "kernel32${LIBEXT} user32${LIBEXT} gdi32${LIBEXT} winspool${LIBEXT} shell32${LIBEXT} ole32${LIBEXT} oleaut32${LIBEXT} uuid${LIBEXT} comdlg32${LIBEXT} advapi32${LIBEXT} psapi${LIBEXT}")
|
||||
set(OSL_FLEX_BISON -DFLEX_EXECUTABLE=${LIBDIR}/flexbison/win_flex.exe -DBISON_EXECUTABLE=${LIBDIR}/flexbison/win_bison.exe)
|
||||
set(OSL_OPENIMAGEIO_LIBRARY "${LIBDIR}/openimageio/lib/${LIBPREFIX}OpenImageIO${LIBEXT};${LIBDIR}/openimageio/lib/${LIBPREFIX}OpenImageIO_Util${LIBEXT};${LIBDIR}/png/lib/libpng16${LIBEXT};${LIBDIR}/jpg/lib/${LIBPREFIX}jpeg${LIBEXT};${LIBDIR}/tiff/lib/${LIBPREFIX}tiff${LIBEXT};${LIBDIR}/openexr/lib/${LIBPREFIX}IlmImf${OPENEXR_VERSION_POSTFIX}${LIBEXT}")
|
||||
if("${CMAKE_SIZEOF_VOID_P}" EQUAL "4")
|
||||
set(OSL_SIMD_FLAGS -DOIIO_NOSIMD=1 -DOIIO_SIMD=0)
|
||||
else()
|
||||
set(OSL_SIMD_FLAGS -DOIIO_NOSIMD=1 -DOIIO_SIMD=sse2)
|
||||
endif()
|
||||
SET(OSL_PLATFORM_FLAGS -DLINKSTATIC=ON)
|
||||
else()
|
||||
set(OSL_CMAKE_CXX_STANDARD_LIBRARIES)
|
||||
set(OSL_FLEX_BISON)
|
||||
set(OSL_OPENIMAGEIO_LIBRARY "${LIBDIR}/openimageio/lib/${LIBPREFIX}OpenImageIO${LIBEXT};${LIBDIR}/openimageio/lib/${LIBPREFIX}OpenImageIO_Util${LIBEXT};${LIBDIR}/png/lib/${LIBPREFIX}png16${LIBEXT};${LIBDIR}/jpg/lib/${LIBPREFIX}jpeg${LIBEXT};${LIBDIR}/tiff/lib/${LIBPREFIX}tiff${LIBEXT};${LIBDIR}/openexr/lib/${LIBPREFIX}IlmImf${OPENEXR_VERSION_POSTFIX}${LIBEXT}")
|
||||
SET(OSL_PLATFORM_FLAGS)
|
||||
endif()
|
||||
|
||||
set(OSL_ILMBASE_CUSTOM_LIBRARIES "${LIBDIR}/openexr/lib/Imath${OPENEXR_VERSION_POSTFIX}.lib^^${LIBDIR}/openexr/lib/Half{OPENEXR_VERSION_POSTFIX}.lib^^${LIBDIR}/openexr/lib/IlmThread${OPENEXR_VERSION_POSTFIX}.lib^^${LIBDIR}/openexr/lib/Iex${OPENEXR_VERSION_POSTFIX}.lib")
|
||||
set(OSL_LLVM_LIBRARY "${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMAnalysis${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMAsmParser${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMAsmPrinter${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMBitReader${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMBitWriter${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMCodeGen${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMCore${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMDebugInfo${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMExecutionEngine${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMInstCombine${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMInstrumentation${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMInterpreter${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMJIT${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMLinker${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMMC${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMMCDisassembler${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMMCJIT${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMMCParser${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMObject${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMRuntimeDyld${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMScalarOpts${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMSelectionDAG${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMSupport${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMTableGen${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMTarget${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMTransformUtils${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMVectorize${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMX86AsmParser${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMX86AsmPrinter${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMX86CodeGen${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMX86Desc${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMX86Disassembler${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMX86Info${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMX86Utils${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMipa${LIBEXT};${LIBDIR}/llvm/lib/${LIBPREFIX}LLVMipo${LIBEXT}")
|
||||
|
||||
set(OSL_EXTRA_ARGS
|
||||
-DBoost_COMPILER:STRING=${BOOST_COMPILER_STRING}
|
||||
-DBoost_USE_MULTITHREADED=ON
|
||||
-DBoost_USE_STATIC_LIBS=ON
|
||||
-DBoost_USE_STATIC_RUNTIME=OFF
|
||||
-DBOOST_ROOT=${LIBDIR}/boost
|
||||
-DBOOST_LIBRARYDIR=${LIBDIR}/boost/lib/
|
||||
-DBoost_NO_SYSTEM_PATHS=ON
|
||||
-DLLVM_DIRECTORY=${LIBDIR}/llvm
|
||||
-DLLVM_INCLUDES=${LIBDIR}/llvm/include
|
||||
-DLLVM_LIB_DIR=${LIBDIR}/llvm/lib
|
||||
-DLLVM_VERSION=3.4
|
||||
-DLLVM_LIBRARY=${OSL_LLVM_LIBRARY}
|
||||
-DOPENEXR_HOME=${LIBDIR}/openexr/
|
||||
-DILMBASE_HOME=${LIBDIR}/openexr/
|
||||
-DILMBASE_INCLUDE_DIR=${LIBDIR}/openexr/include/
|
||||
-DOPENEXR_HALF_LIBRARY=${LIBDIR}/openexr/lib/${LIBPREFIX}Half${OPENEXR_VERSION_POSTFIX}${LIBEXT}
|
||||
-DOPENEXR_IMATH_LIBRARY=${LIBDIR}/openexr/lib/${LIBPREFIX}Imath${OPENEXR_VERSION_POSTFIX}${LIBEXT}
|
||||
-DOPENEXR_ILMTHREAD_LIBRARY=${LIBDIR}/openexr/lib/${LIBPREFIX}IlmThread${OPENEXR_VERSION_POSTFIX}${LIBEXT}
|
||||
-DOPENEXR_IEX_LIBRARY=${LIBDIR}/openexr/lib/${LIBPREFIX}Iex${OPENEXR_VERSION_POSTFIX}${LIBEXT}
|
||||
-DOPENEXR_INCLUDE_DIR=${LIBDIR}/openexr/include/
|
||||
-DOPENEXR_ILMIMF_LIBRARY=${LIBDIR}/openexr/lib/${LIBPREFIX}IlmImf${OPENEXR_VERSION_POSTFIX}${LIBEXT}
|
||||
-DOSL_BUILD_TESTS=OFF
|
||||
-DOSL_BUILD_MATERIALX=OFF
|
||||
-DZLIB_LIBRARY=${LIBDIR}/zlib/lib/${ZLIB_LIBRARY}
|
||||
-DZLIB_INCLUDE_DIR=${LIBDIR}/zlib/include/
|
||||
-DOPENIMAGEIOHOME=${LIBDIR}/openimageio/
|
||||
-DOPENIMAGEIO_INCLUDE_DIR=${LIBDIR}/openimageio/include
|
||||
-DOPENIMAGEIO_LIBRARY=${OSL_OPENIMAGEIO_LIBRARY}
|
||||
${OSL_FLEX_BISON}
|
||||
-DCMAKE_CXX_STANDARD_LIBRARIES=${OSL_CMAKE_CXX_STANDARD_LIBRARIES}
|
||||
-DBUILDSTATIC=ON
|
||||
${OSL_PLATFORM_FLAGS}
|
||||
-DOSL_BUILD_PLUGINS=Off
|
||||
-DSTOP_ON_WARNING=OFF
|
||||
-DUSE_LLVM_BITCODE=OFF
|
||||
-DUSE_PARTIO=OFF
|
||||
-DUSE_QT=OFF
|
||||
${OSL_SIMD_FLAGS}
|
||||
-DPARTIO_LIBRARIES=
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
set(OSL_EXTRA_ARGS
|
||||
${OSL_EXTRA_ARGS}
|
||||
-DPUGIXML_HOME=${LIBDIR}/pugixml
|
||||
)
|
||||
elseif(APPLE)
|
||||
# Make symbol hiding consistent with OIIO which defaults to OFF,
|
||||
# avoids linker warnings on macOS
|
||||
set(OSL_EXTRA_ARGS
|
||||
${OSL_EXTRA_ARGS}
|
||||
-DHIDE_SYMBOLS=OFF
|
||||
)
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_osl
|
||||
URL ${OSL_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
LIST_SEPARATOR ^^
|
||||
URL_HASH MD5=${OSL_HASH}
|
||||
PREFIX ${BUILD_DIR}/osl
|
||||
PATCH_COMMAND ${PATCH_CMD} -p 1 -d ${BUILD_DIR}/osl/src/external_osl < ${PATCH_DIR}/osl.diff
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/osl -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE} ${DEFAULT_CMAKE_FLAGS} ${OSL_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/osl
|
||||
)
|
||||
|
||||
add_dependencies(
|
||||
external_osl
|
||||
external_boost
|
||||
ll
|
||||
external_clang
|
||||
external_openexr
|
||||
external_zlib
|
||||
external_flexbison
|
||||
external_openimageio
|
||||
)
|
||||
|
||||
if(UNIX)
|
||||
# Rely on PugiXML compiled with OpenImageIO
|
||||
else()
|
||||
add_dependencies(
|
||||
external_osl
|
||||
external_pugixml
|
||||
)
|
||||
endif()
|
||||
|
||||
if(WIN32)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_osl after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/osl/ ${HARVEST_TARGET}/osl
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
ExternalProject_Add_Step(external_osl after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/osl/lib/oslcomp.lib ${HARVEST_TARGET}/osl/lib/oslcomp_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/osl/lib/oslexec.lib ${HARVEST_TARGET}/osl/lib/oslexec_d.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/osl/lib/oslquery.lib ${HARVEST_TARGET}/osl/lib/oslquery_d.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
endif()
|
@@ -1,60 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(MSVC)
|
||||
set(PYTARGET ${HARVEST_TARGET}/python/${PYTHON_SHORT_VERSION_NO_DOTS})
|
||||
set(PYSRC ${LIBDIR}/python/)
|
||||
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
add_custom_command(
|
||||
OUTPUT ${PYTARGET}/bin/python${PYTHON_POSTFIX}.exe
|
||||
COMMAND echo packaging python
|
||||
COMMAND echo this should ouput at ${PYTARGET}/bin/python${PYTHON_POSTFIX}.exe
|
||||
COMMAND ${CMAKE_COMMAND} -E make_directory ${PYTARGET}/libs
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${PYSRC}/libs/python${PYTHON_SHORT_VERSION_NO_DOTS}.lib ${PYTARGET}/libs/python${PYTHON_SHORT_VERSION_NO_DOTS}.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${PYSRC}/python.exe ${PYTARGET}/bin/python.exe
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${PYSRC}/python${PYTHON_SHORT_VERSION_NO_DOTS}.dll ${PYTARGET}/bin/python${PYTHON_SHORT_VERSION_NO_DOTS}.dll
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${PYSRC}/python3${PYTHON_POSTFIX}.dll ${PYTARGET}/bin/python3${PYTHON_POSTFIX}.dll
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${PYSRC}/python${PYTHON_SHORT_VERSION_NO_DOTS}.pdb ${PYTARGET}/libs/python${PYTHON_SHORT_VERSION_NO_DOTS}.pdb
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${PYSRC}/include/ ${PYTARGET}/include/
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${PYSRC}/lib/ ${PYTARGET}/lib/
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${PYSRC}/DLLs/ ${PYTARGET}/DLLs/
|
||||
COMMAND cd ${PYTARGET}/lib/ && for /d /r . %%d in (__pycache__) do @if exist "%%d" echo "%%d" && rd /s/q "%%d"
|
||||
)
|
||||
add_custom_target(Package_Python ALL DEPENDS external_python external_numpy external_python_site_packages OUTPUT ${HARVEST_TARGET}/python/${PYTHON_SHORT_VERSION_NO_DOTS}/bin/python${PYTHON_POSTFIX}.exe)
|
||||
endif()
|
||||
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
add_custom_command(
|
||||
OUTPUT ${PYTARGET}/bin/python${PYTHON_POSTFIX}.exe
|
||||
COMMAND echo packaging python
|
||||
COMMAND echo this should ouput at ${PYTARGET}/bin/python${PYTHON_POSTFIX}.exe
|
||||
COMMAND ${CMAKE_COMMAND} -E make_directory ${PYTARGET}/libs
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${PYSRC}/libs/python${PYTHON_SHORT_VERSION_NO_DOTS}${PYTHON_POSTFIX}.lib ${PYTARGET}/libs/python${PYTHON_SHORT_VERSION_NO_DOTS}${PYTHON_POSTFIX}.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${PYSRC}/python${PYTHON_POSTFIX}.exe ${PYTARGET}/bin/python${PYTHON_POSTFIX}.exe
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${PYSRC}/python${PYTHON_SHORT_VERSION_NO_DOTS}${PYTHON_POSTFIX}.dll ${PYTARGET}/bin/python${PYTHON_SHORT_VERSION_NO_DOTS}${PYTHON_POSTFIX}.dll
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${PYSRC}/python3${PYTHON_POSTFIX}.dll ${PYTARGET}/bin/python3${PYTHON_POSTFIX}.dll
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${PYSRC}/python${PYTHON_SHORT_VERSION_NO_DOTS}${PYTHON_POSTFIX}.pdb ${PYTARGET}/libs/python${PYTHON_SHORT_VERSION_NO_DOTS}${PYTHON_POSTFIX}.pdb
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${PYSRC}/include/ ${PYTARGET}/include/
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${PYSRC}/lib/ ${PYTARGET}/lib/
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${PYSRC}/DLLs/ ${PYTARGET}/DLLs/
|
||||
COMMAND cd ${PYTARGET}/lib/ && for /d /r . %%d in (__pycache__) do @if exist "%%d" echo "%%d" && rd /s/q "%%d"
|
||||
)
|
||||
add_custom_target(Package_Python ALL DEPENDS external_python external_numpy external_python_site_packages OUTPUT ${PYTARGET}/bin/python${PYTHON_POSTFIX}.exe)
|
||||
endif()
|
||||
endif()
|
@@ -1,44 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(PNG_EXTRA_ARGS
|
||||
-DZLIB_LIBRARY=${LIBDIR}/zlib/lib/${ZLIB_LIBRARY}
|
||||
-DZLIB_INCLUDE_DIR=${LIBDIR}/zlib/include/
|
||||
-DPNG_STATIC=ON
|
||||
)
|
||||
|
||||
ExternalProject_Add(external_png
|
||||
URL ${PNG_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${PNG_HASH}
|
||||
PREFIX ${BUILD_DIR}/png
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/png ${DEFAULT_CMAKE_FLAGS} ${PNG_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/png
|
||||
)
|
||||
|
||||
add_dependencies(
|
||||
external_png
|
||||
external_zlib
|
||||
)
|
||||
|
||||
if(WIN32 AND BUILD_MODE STREQUAL Debug)
|
||||
ExternalProject_Add_Step(external_png after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/png/lib/libpng16_staticd${LIBEXT} ${LIBDIR}/png/lib/libpng16${LIBEXT}
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
@@ -1,53 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(WIN32)
|
||||
|
||||
if(MSVC14) # vs2015 has timespec
|
||||
set(PTHREAD_CPPFLAGS "/I. /DHAVE_CONFIG_H /D_TIMESPEC_DEFINED ")
|
||||
else() # everything before doesn't
|
||||
set(PTHREAD_CPPFLAGS "/I. /DHAVE_CONFIG_H ")
|
||||
endif()
|
||||
|
||||
set(PTHREADS_BUILD cd ${BUILD_DIR}/pthreads/src/external_pthreads/ && cd && nmake VC-static /e CPPFLAGS=${PTHREAD_CPPFLAGS} /e XLIBS=/NODEFAULTLIB:msvcr)
|
||||
|
||||
ExternalProject_Add(external_pthreads
|
||||
URL ${PTHREADS_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${PTHREADS_HASH}
|
||||
PREFIX ${BUILD_DIR}/pthreads
|
||||
CONFIGURE_COMMAND echo .
|
||||
BUILD_COMMAND ${PTHREADS_BUILD}
|
||||
INSTALL_COMMAND COMMAND
|
||||
${CMAKE_COMMAND} -E copy ${BUILD_DIR}/pthreads/src/external_pthreads/libpthreadVC3${LIBEXT} ${LIBDIR}/pthreads/lib/pthreadVC3${LIBEXT} &&
|
||||
${CMAKE_COMMAND} -E copy ${BUILD_DIR}/pthreads/src/external_pthreads/pthread.h ${LIBDIR}/pthreads/inc/pthread.h &&
|
||||
${CMAKE_COMMAND} -E copy ${BUILD_DIR}/pthreads/src/external_pthreads/sched.h ${LIBDIR}/pthreads/inc/sched.h &&
|
||||
${CMAKE_COMMAND} -E copy ${BUILD_DIR}/pthreads/src/external_pthreads/semaphore.h ${LIBDIR}/pthreads/inc/semaphore.h &&
|
||||
${CMAKE_COMMAND} -E copy ${BUILD_DIR}/pthreads/src/external_pthreads/_ptw32.h ${LIBDIR}/pthreads/inc/_ptw32.h
|
||||
INSTALL_DIR ${LIBDIR}/pthreads
|
||||
)
|
||||
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_pthreads after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/pthreads/inc/ ${HARVEST_TARGET}/pthreads/include/
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/pthreads/lib/ ${HARVEST_TARGET}/pthreads/lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
|
||||
endif()
|
@@ -1,43 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(PUGIXML_EXTRA_ARGS
|
||||
)
|
||||
|
||||
ExternalProject_Add(external_pugixml
|
||||
URL ${PUGIXML_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${PUGIXML_HASH}
|
||||
PREFIX ${BUILD_DIR}/pugixml
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/pugixml ${DEFAULT_CMAKE_FLAGS} ${PUGIXML_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/pugixml
|
||||
)
|
||||
if(WIN32)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_pugixml after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/pugixml/lib/pugixml.lib ${HARVEST_TARGET}/osl/lib/pugixml.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
ExternalProject_Add_Step(external_pugixml after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/pugixml/lib/pugixml.lib ${HARVEST_TARGET}/osl/lib/pugixml_d.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
endif()
|
@@ -1,103 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(PYTHON_POSTFIX)
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
set(PYTHON_POSTFIX _d)
|
||||
set(PYTHON_EXTRA_INSTLAL_FLAGS -d)
|
||||
endif()
|
||||
|
||||
if(WIN32)
|
||||
set(PYTHON_BINARY_INTERNAL ${BUILD_DIR}/python/src/external_python/PCBuild/amd64/python${PYTHON_POSTFIX}.exe)
|
||||
set(PYTHON_BINARY ${LIBDIR}/python/python${PYTHON_POSTFIX}.exe)
|
||||
set(PYTHON_SRC ${BUILD_DIR}/python/src/external_python/)
|
||||
macro(cmake_to_dos_path MsysPath ResultingPath)
|
||||
string(REPLACE "/" "\\" ${ResultingPath} "${MsysPath}")
|
||||
endmacro()
|
||||
|
||||
set(PYTHON_EXTERNALS_FOLDER ${BUILD_DIR}/python/src/external_python/externals)
|
||||
set(DOWNLOADS_EXTERNALS_FOLDER ${DOWNLOAD_DIR}/externals)
|
||||
|
||||
cmake_to_dos_path(${PYTHON_EXTERNALS_FOLDER} PYTHON_EXTERNALS_FOLDER_DOS)
|
||||
cmake_to_dos_path(${DOWNLOADS_EXTERNALS_FOLDER} DOWNLOADS_EXTERNALS_FOLDER_DOS)
|
||||
|
||||
ExternalProject_Add(external_python
|
||||
URL ${PYTHON_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${PYTHON_HASH}
|
||||
PREFIX ${BUILD_DIR}/python
|
||||
CONFIGURE_COMMAND ""
|
||||
BUILD_COMMAND cd ${BUILD_DIR}/python/src/external_python/pcbuild/ && set IncludeTkinter=false && call build.bat -e -p ${PYTHON_ARCH} -c ${BUILD_MODE}
|
||||
INSTALL_COMMAND ${PYTHON_BINARY_INTERNAL} ${PYTHON_SRC}/PC/layout/main.py -b ${PYTHON_SRC}/PCbuild/amd64 -s ${PYTHON_SRC} -t ${PYTHON_SRC}/tmp/ --include-underpth --include-stable --include-pip --include-dev --include-launchers --include-venv --include-symbols ${PYTHON_EXTRA_INSTLAL_FLAGS} --copy ${LIBDIR}/python
|
||||
)
|
||||
|
||||
else()
|
||||
if(APPLE)
|
||||
# disable functions that can be in 10.13 sdk but aren't available on 10.9 target
|
||||
set(PYTHON_FUNC_CONFIGS
|
||||
export ac_cv_func_futimens=no &&
|
||||
export ac_cv_func_utimensat=no &&
|
||||
export ac_cv_func_basename_r=no &&
|
||||
export ac_cv_func_clock_getres=no &&
|
||||
export ac_cv_func_clock_gettime=no &&
|
||||
export ac_cv_func_clock_settime=no &&
|
||||
export ac_cv_func_dirname_r=no &&
|
||||
export ac_cv_func_getentropy=no &&
|
||||
export ac_cv_func_mkostemp=no &&
|
||||
export ac_cv_func_mkostemps=no &&
|
||||
export ac_cv_func_timingsafe_bcmp=no)
|
||||
set(PYTHON_CONFIGURE_ENV ${CONFIGURE_ENV} && ${PYTHON_FUNC_CONFIGS})
|
||||
set(PYTHON_BINARY ${BUILD_DIR}/python/src/external_python/python.exe)
|
||||
else()
|
||||
set(PYTHON_CONFIGURE_ENV ${CONFIGURE_ENV})
|
||||
set(PYTHON_BINARY ${BUILD_DIR}/python/src/external_python/python)
|
||||
endif()
|
||||
|
||||
set(PYTHON_CONFIGURE_EXTRA_ARGS "--with-openssl=${LIBDIR}/ssl")
|
||||
set(PYTHON_CFLAGS "-I${LIBDIR}/sqlite/include -I${LIBDIR}/bzip2/include -I${LIBDIR}/lzma/include -I${LIBDIR}/zlib/include")
|
||||
set(PYTHON_LDFLAGS "-L${LIBDIR}/ffi/lib -L${LIBDIR}/sqlite/lib -L${LIBDIR}/bzip2/lib -L${LIBDIR}/lzma/lib -L${LIBDIR}/zlib/lib")
|
||||
set(PYTHON_CONFIGURE_EXTRA_ENV
|
||||
export CFLAGS=${PYTHON_CFLAGS} &&
|
||||
export CPPFLAGS=${PYTHON_CFLAGS} &&
|
||||
export LDFLAGS=${PYTHON_LDFLAGS} &&
|
||||
export PKG_CONFIG_PATH=${LIBDIR}/ffi/lib/pkgconfig)
|
||||
set(PYTHON_PATCH ${PATCH_CMD} --verbose -p1 -d ${BUILD_DIR}/python/src/external_python < ${PATCH_DIR}/python_linux.diff)
|
||||
|
||||
ExternalProject_Add(external_python
|
||||
URL ${PYTHON_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${PYTHON_HASH}
|
||||
PREFIX ${BUILD_DIR}/python
|
||||
PATCH_COMMAND ${PYTHON_PATCH}
|
||||
CONFIGURE_COMMAND ${PYTHON_CONFIGURE_ENV} && ${PYTHON_CONFIGURE_EXTRA_ENV} && cd ${BUILD_DIR}/python/src/external_python/ && ${CONFIGURE_COMMAND} --prefix=${LIBDIR}/python ${PYTHON_CONFIGURE_EXTRA_ARGS}
|
||||
BUILD_COMMAND ${PYTHON_CONFIGURE_ENV} && cd ${BUILD_DIR}/python/src/external_python/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${PYTHON_CONFIGURE_ENV} && cd ${BUILD_DIR}/python/src/external_python/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/python)
|
||||
endif()
|
||||
|
||||
if(UNIX)
|
||||
add_dependencies(
|
||||
external_python
|
||||
external_bzip2
|
||||
external_ffi
|
||||
external_lzma
|
||||
external_ssl
|
||||
external_sqlite
|
||||
external_zlib
|
||||
)
|
||||
endif()
|
@@ -1,9 +0,0 @@
|
||||
{
|
||||
global:
|
||||
Py*;
|
||||
_Py*;
|
||||
_py*;
|
||||
local:
|
||||
*;
|
||||
};
|
||||
|
@@ -1,30 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
ExternalProject_Add(external_python_site_packages
|
||||
DOWNLOAD_COMMAND ""
|
||||
CONFIGURE_COMMAND ""
|
||||
BUILD_COMMAND ""
|
||||
PREFIX ${BUILD_DIR}/site_packages
|
||||
INSTALL_COMMAND ${PYTHON_BINARY} -m pip install idna==${IDNA_VERSION} chardet==${CHARDET_VERSION} urllib3==${URLLIB3_VERSION} certifi==${CERTIFI_VERSION} requests==${REQUESTS_VERSION} --no-binary :all:
|
||||
)
|
||||
|
||||
add_dependencies(
|
||||
external_python_site_packages
|
||||
external_python
|
||||
)
|
@@ -1,49 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(WIN32)
|
||||
set(SDL_EXTRA_ARGS
|
||||
-DSDL_STATIC=Off
|
||||
)
|
||||
else()
|
||||
set(SDL_EXTRA_ARGS
|
||||
-DSDL_STATIC=ON
|
||||
-DSDL_SHARED=OFF
|
||||
-DSDL_VIDEO=OFF
|
||||
-DSNDIO=OFF
|
||||
)
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_sdl
|
||||
URL ${SDL_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${SDL_HASH}
|
||||
PREFIX ${BUILD_DIR}/sdl
|
||||
PATCH_COMMAND ${PATCH_CMD} -p 0 -N -d ${BUILD_DIR}/sdl/src/external_sdl < ${PATCH_DIR}/sdl.diff
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/sdl ${DEFAULT_CMAKE_FLAGS} ${SDL_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/sdl
|
||||
)
|
||||
|
||||
if(BUILD_MODE STREQUAL Release AND WIN32)
|
||||
ExternalProject_Add_Step(external_sdl after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/sdl/include/sdl2 ${HARVEST_TARGET}/sdl/include
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/sdl/lib ${HARVEST_TARGET}/sdl/lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/sdl/bin ${HARVEST_TARGET}/sdl/lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
@@ -1,227 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
####################################################################################################################
|
||||
# Mingw32 Builds
|
||||
####################################################################################################################
|
||||
# This installs mingw32+msys to compile ffmpeg/iconv/libsndfile/lapack/fftw3
|
||||
####################################################################################################################
|
||||
|
||||
message("LIBDIR = ${LIBDIR}")
|
||||
macro(cmake_to_msys_path MsysPath ResultingPath)
|
||||
string(REPLACE ":" "" TmpPath "${MsysPath}")
|
||||
string(SUBSTRING ${TmpPath} 0 1 Drive)
|
||||
string(SUBSTRING ${TmpPath} 1 255 PathPart)
|
||||
string(TOLOWER ${Drive} LowerDrive)
|
||||
string(CONCAT ${ResultingPath} "/" ${LowerDrive} ${PathPart})
|
||||
endmacro()
|
||||
cmake_to_msys_path(${LIBDIR} mingw_LIBDIR)
|
||||
message("mingw_LIBDIR = ${mingw_LIBDIR}")
|
||||
|
||||
message("Checking for mingw32")
|
||||
# download mingw32
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/i686-4.9.4-release-win32-sjlj-rt_v5-rev0.7z")
|
||||
message("Downloading mingw32")
|
||||
file(DOWNLOAD "https://astuteinternet.dl.sourceforge.net/project/mingw-w64/Toolchains%20targetting%20Win32/Personal%20Builds/mingw-builds/4.9.4/threads-win32/sjlj/i686-4.9.4-release-win32-sjlj-rt_v5-rev0.7z" "${DOWNLOAD_DIR}/i686-4.9.4-release-win32-sjlj-rt_v5-rev0.7z")
|
||||
endif()
|
||||
|
||||
# make mingw root directory
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/mingw")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E make_directory ${DOWNLOAD_DIR}/mingw
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}
|
||||
)
|
||||
endif()
|
||||
|
||||
# extract mingw32
|
||||
if((NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw32/ming32sh.cmd") AND (EXISTS "${DOWNLOAD_DIR}/i686-4.9.4-release-win32-sjlj-rt_v5-rev0.7z"))
|
||||
message("Extracting mingw32")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E tar jxf ${DOWNLOAD_DIR}/i686-4.9.4-release-win32-sjlj-rt_v5-rev0.7z
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/mingw
|
||||
)
|
||||
endif()
|
||||
|
||||
message("Checking for pkg-config")
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/pkg-config-lite-0.28-1_bin-win32.zip")
|
||||
message("Downloading pkg-config")
|
||||
file(DOWNLOAD "https://nchc.dl.sourceforge.net/project/pkgconfiglite/0.28-1/pkg-config-lite-0.28-1_bin-win32.zip" "${DOWNLOAD_DIR}/pkg-config-lite-0.28-1_bin-win32.zip")
|
||||
endif()
|
||||
|
||||
# extract pkgconfig
|
||||
if((NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw32/bin/pkg-config.exe") AND (EXISTS "${DOWNLOAD_DIR}/pkg-config-lite-0.28-1_bin-win32.zip"))
|
||||
message("Extracting pkg-config")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E tar jxf "${DOWNLOAD_DIR}/pkg-config-lite-0.28-1_bin-win32.zip"
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/
|
||||
)
|
||||
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E copy "${DOWNLOAD_DIR}/pkg-config-lite-0.28-1/bin/pkg-config.exe" "${DOWNLOAD_DIR}/mingw/mingw32/bin/pkg-config.exe"
|
||||
)
|
||||
|
||||
endif()
|
||||
|
||||
message("Checking for nasm")
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/nasm-2.13.02-win32.zip")
|
||||
message("Downloading nasm")
|
||||
file(DOWNLOAD "http://www.nasm.us/pub/nasm/releasebuilds/2.13.02/win32/nasm-2.13.02-win32.zip" "${DOWNLOAD_DIR}/nasm-2.13.02-win32.zip")
|
||||
endif()
|
||||
|
||||
# extract nasm
|
||||
if((NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw32/bin/nasm.exe") AND (EXISTS "${DOWNLOAD_DIR}/nasm-2.13.02-win32.zip"))
|
||||
message("Extracting nasm")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E tar jxf "${DOWNLOAD_DIR}/nasm-2.13.02-win32.zip"
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/
|
||||
)
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E copy "${DOWNLOAD_DIR}/nasm-2.13.02/nasm.exe" "${DOWNLOAD_DIR}/mingw/mingw32/bin/nasm.exe"
|
||||
)
|
||||
|
||||
endif()
|
||||
SET(NASM_PATH ${DOWNLOAD_DIR}/mingw/mingw32/bin/nasm.exe)
|
||||
message("Checking for mingwGet")
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/mingw-get-0.6.2-mingw32-beta-20131004-1-bin.zip")
|
||||
message("Downloading mingw-get")
|
||||
file(DOWNLOAD "https://nchc.dl.sourceforge.net/project/mingw/Installer/mingw-get/mingw-get-0.6.2-beta-20131004-1/mingw-get-0.6.2-mingw32-beta-20131004-1-bin.zip" "${DOWNLOAD_DIR}/mingw-get-0.6.2-mingw32-beta-20131004-1-bin.zip")
|
||||
endif()
|
||||
|
||||
# extract mingw_get
|
||||
if((NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw32/bin/mingw-get.exe") AND (EXISTS "${DOWNLOAD_DIR}/mingw-get-0.6.2-mingw32-beta-20131004-1-bin.zip"))
|
||||
message("Extracting mingw-get")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E tar jxf "${DOWNLOAD_DIR}/mingw-get-0.6.2-mingw32-beta-20131004-1-bin.zip"
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/mingw/mingw32/
|
||||
)
|
||||
endif()
|
||||
|
||||
if((EXISTS "${DOWNLOAD_DIR}/mingw/mingw32/bin/mingw-get.exe") AND (NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw32/msys/1.0/bin/make.exe"))
|
||||
message("Installing MSYS")
|
||||
execute_process(
|
||||
COMMAND ${DOWNLOAD_DIR}/mingw/mingw32/bin/mingw-get install msys msys-patch
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/mingw/mingw32/bin/
|
||||
)
|
||||
endif()
|
||||
|
||||
if((EXISTS "${DOWNLOAD_DIR}/mingw/mingw32/bin/mingw-get.exe") AND (NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw32/msys/1.0/bin/mktemp.exe"))
|
||||
message("Installing mktemp")
|
||||
execute_process(
|
||||
COMMAND ${DOWNLOAD_DIR}/mingw/mingw32/bin/mingw-get install msys msys-mktemp
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/mingw/mingw32/bin/
|
||||
)
|
||||
endif()
|
||||
|
||||
|
||||
message("Checking for CoreUtils")
|
||||
# download old core_utils for pr.exe (ffmpeg needs it to build)
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/coreutils-5.97-MSYS-1.0.11-snapshot.tar.bz2")
|
||||
message("Downloading CoreUtils 5.97")
|
||||
file(DOWNLOAD "https://nchc.dl.sourceforge.net/project/mingw/MSYS/Base/msys-core/_obsolete/coreutils-5.97-MSYS-1.0.11-2/coreutils-5.97-MSYS-1.0.11-snapshot.tar.bz2" "${DOWNLOAD_DIR}/coreutils-5.97-MSYS-1.0.11-snapshot.tar.bz2")
|
||||
endif()
|
||||
|
||||
if((EXISTS "${DOWNLOAD_DIR}/coreutils-5.97-MSYS-1.0.11-snapshot.tar.bz2") AND (NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw32/msys/1.0/bin/pr.exe"))
|
||||
message("Installing pr from CoreUtils 5.97")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E make_directory ${DOWNLOAD_DIR}/tmp_coreutils
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}
|
||||
)
|
||||
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E tar jxf ${DOWNLOAD_DIR}/coreutils-5.97-MSYS-1.0.11-snapshot.tar.bz2
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/tmp_coreutils/
|
||||
)
|
||||
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${DOWNLOAD_DIR}/tmp_coreutils/coreutils-5.97/bin/pr.exe "${DOWNLOAD_DIR}/mingw/mingw32/msys/1.0/bin/pr.exe"
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/tmp_coreutils/
|
||||
)
|
||||
endif()
|
||||
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw32/ming32sh.cmd")
|
||||
message("Installing ming32sh.cmd")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${PATCH_DIR}/ming32sh.cmd ${DOWNLOAD_DIR}/mingw/mingw32/ming32sh.cmd
|
||||
)
|
||||
endif()
|
||||
|
||||
message("Checking for perl")
|
||||
# download perl for libvpx
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/strawberry-perl-5.22.1.3-32bit-portable.zip")
|
||||
message("Downloading perl")
|
||||
file(DOWNLOAD "http://strawberryperl.com/download/5.22.1.3/strawberry-perl-5.22.1.3-32bit-portable.zip" "${DOWNLOAD_DIR}/strawberry-perl-5.22.1.3-32bit-portable.zip")
|
||||
endif()
|
||||
|
||||
# make perl root directory
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/perl32")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E make_directory ${DOWNLOAD_DIR}/perl32
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}
|
||||
)
|
||||
endif()
|
||||
|
||||
# extract perl
|
||||
if((NOT EXISTS "${DOWNLOAD_DIR}/perl32/portable.perl") AND (EXISTS "${DOWNLOAD_DIR}/strawberry-perl-5.22.1.3-32bit-portable.zip"))
|
||||
message("Extracting perl")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E tar jxf ${DOWNLOAD_DIR}/strawberry-perl-5.22.1.3-32bit-portable.zip
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/perl32
|
||||
)
|
||||
endif()
|
||||
|
||||
# get yasm for vpx
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw32/bin/yasm.exe")
|
||||
message("Downloading yasm")
|
||||
file(DOWNLOAD "http://www.tortall.net/projects/yasm/releases/yasm-1.3.0-win32.exe" "${DOWNLOAD_DIR}/mingw/mingw32/bin/yasm.exe")
|
||||
endif()
|
||||
|
||||
message("checking i686-w64-mingw32-strings")
|
||||
# copy strings.exe to i686-w64-mingw32-strings for x264
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw32/bin/i686-w64-mingw32-strings.exe")
|
||||
message("fixing i686-w64-mingw32-strings.exe")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E copy "${DOWNLOAD_DIR}/mingw/mingw32/bin/strings.exe" "${DOWNLOAD_DIR}/mingw/mingw32/bin/i686-w64-mingw32-strings.exe"
|
||||
)
|
||||
endif()
|
||||
|
||||
message("checking i686-w64-mingw32-ar.exe")
|
||||
# copy ar.exe to i686-w64-mingw32-ar.exe for x264
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw32/bin/i686-w64-mingw32-ar.exe")
|
||||
message("fixing i686-w64-mingw32-ar.exe")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E copy "${DOWNLOAD_DIR}/mingw/mingw32/bin/ar.exe" "${DOWNLOAD_DIR}/mingw/mingw32/bin/i686-w64-mingw32-ar.exe"
|
||||
)
|
||||
endif()
|
||||
|
||||
message("checking i686-w64-mingw32-strip.exe")
|
||||
# copy strip.exe to i686-w64-mingw32-strip.exe for x264
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw32/bin/i686-w64-mingw32-strip.exe")
|
||||
message("fixing i686-w64-mingw32-strip.exe")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E copy "${DOWNLOAD_DIR}/mingw/mingw32/bin/strip.exe" "${DOWNLOAD_DIR}/mingw/mingw32/bin/i686-w64-mingw32-strip.exe"
|
||||
)
|
||||
endif()
|
||||
|
||||
message("checking i686-w64-mingw32-ranlib.exe")
|
||||
# copy ranlib.exe to i686-w64-mingw32-ranlib.exe for x264
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw32/bin/i686-w64-mingw32-ranlib.exe")
|
||||
message("fixing i686-w64-mingw32-ranlib.exe")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E copy "${DOWNLOAD_DIR}/mingw/mingw32/bin/ranlib.exe" "${DOWNLOAD_DIR}/mingw/mingw32/bin/i686-w64-mingw32-ranlib.exe"
|
||||
)
|
||||
endif()
|
@@ -1,227 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
####################################################################################################################
|
||||
# Mingw64 Builds
|
||||
####################################################################################################################
|
||||
# This installs mingw64+msys to compile ffmpeg/iconv/libsndfile/lapack/fftw3
|
||||
####################################################################################################################
|
||||
|
||||
message("LIBDIR = ${LIBDIR}")
|
||||
macro(cmake_to_msys_path MsysPath ResultingPath)
|
||||
string(REPLACE ":" "" TmpPath "${MsysPath}")
|
||||
string(SUBSTRING ${TmpPath} 0 1 Drive)
|
||||
string(SUBSTRING ${TmpPath} 1 255 PathPart)
|
||||
string(TOLOWER ${Drive} LowerDrive)
|
||||
string(CONCAT ${ResultingPath} "/" ${LowerDrive} ${PathPart})
|
||||
endmacro()
|
||||
cmake_to_msys_path(${LIBDIR} mingw_LIBDIR)
|
||||
message("mingw_LIBDIR = ${mingw_LIBDIR}")
|
||||
|
||||
message("Checking for mingw64")
|
||||
# download ming64
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/x86_64-4.9.4-release-win32-seh-rt_v5-rev0.7z")
|
||||
message("Downloading mingw64")
|
||||
file(DOWNLOAD "https://nchc.dl.sourceforge.net/project/mingw-w64/Toolchains%20targetting%20Win64/Personal%20Builds/mingw-builds/4.9.4/threads-win32/seh/x86_64-4.9.4-release-win32-seh-rt_v5-rev0.7z" "${DOWNLOAD_DIR}/x86_64-4.9.4-release-win32-seh-rt_v5-rev0.7z")
|
||||
endif()
|
||||
|
||||
# make mingw root directory
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/mingw")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E make_directory ${DOWNLOAD_DIR}/mingw
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}
|
||||
)
|
||||
endif()
|
||||
|
||||
# extract mingw64
|
||||
if((NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw64/ming64sh.cmd") AND (EXISTS "${DOWNLOAD_DIR}/x86_64-4.9.4-release-win32-seh-rt_v5-rev0.7z"))
|
||||
message("Extracting mingw64")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E tar jxf ${DOWNLOAD_DIR}/x86_64-4.9.4-release-win32-seh-rt_v5-rev0.7z
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/mingw
|
||||
)
|
||||
endif()
|
||||
|
||||
message("Checking for pkg-config")
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/pkg-config-lite-0.28-1_bin-win32.zip")
|
||||
message("Downloading pkg-config")
|
||||
file(DOWNLOAD "https://nchc.dl.sourceforge.net/project/pkgconfiglite/0.28-1/pkg-config-lite-0.28-1_bin-win32.zip" "${DOWNLOAD_DIR}/pkg-config-lite-0.28-1_bin-win32.zip")
|
||||
endif()
|
||||
|
||||
# extract pkgconfig
|
||||
if((NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw64/bin/pkg-config.exe") AND (EXISTS "${DOWNLOAD_DIR}/pkg-config-lite-0.28-1_bin-win32.zip"))
|
||||
message("Extracting pkg-config")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E tar jxf "${DOWNLOAD_DIR}/pkg-config-lite-0.28-1_bin-win32.zip"
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/
|
||||
)
|
||||
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E copy "${DOWNLOAD_DIR}/pkg-config-lite-0.28-1/bin/pkg-config.exe" "${DOWNLOAD_DIR}/mingw/mingw64/bin/pkg-config.exe"
|
||||
)
|
||||
|
||||
endif()
|
||||
|
||||
message("Checking for nasm")
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/nasm-2.13.02-win64.zip")
|
||||
message("Downloading nasm")
|
||||
file(DOWNLOAD "http://www.nasm.us/pub/nasm/releasebuilds/2.13.02/win64/nasm-2.13.02-win64.zip" "${DOWNLOAD_DIR}/nasm-2.13.02-win64.zip")
|
||||
endif()
|
||||
|
||||
# extract nasm
|
||||
if((NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw64/bin/nasm.exe") AND (EXISTS "${DOWNLOAD_DIR}/nasm-2.13.02-win64.zip"))
|
||||
message("Extracting nasm")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E tar jxf "${DOWNLOAD_DIR}/nasm-2.13.02-win64.zip"
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/
|
||||
)
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E copy "${DOWNLOAD_DIR}/nasm-2.13.02/nasm.exe" "${DOWNLOAD_DIR}/mingw/mingw64/bin/nasm.exe"
|
||||
)
|
||||
|
||||
endif()
|
||||
SET(NASM_PATH ${DOWNLOAD_DIR}/mingw/mingw64/bin/nasm.exe)
|
||||
|
||||
message("Checking for mingwGet")
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/mingw-get-0.6.2-mingw32-beta-20131004-1-bin.zip")
|
||||
message("Downloading mingw-get")
|
||||
file(DOWNLOAD "https://nchc.dl.sourceforge.net/project/mingw/Installer/mingw-get/mingw-get-0.6.2-beta-20131004-1/mingw-get-0.6.2-mingw32-beta-20131004-1-bin.zip" "${DOWNLOAD_DIR}/mingw-get-0.6.2-mingw32-beta-20131004-1-bin.zip")
|
||||
endif()
|
||||
|
||||
# extract mingw_get
|
||||
if((NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw64/bin/mingw-get.exe") AND (EXISTS "${DOWNLOAD_DIR}/mingw-get-0.6.2-mingw32-beta-20131004-1-bin.zip"))
|
||||
message("Extracting mingw-get")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E tar jxf "${DOWNLOAD_DIR}/mingw-get-0.6.2-mingw32-beta-20131004-1-bin.zip"
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/mingw/mingw64/
|
||||
)
|
||||
endif()
|
||||
|
||||
if((EXISTS "${DOWNLOAD_DIR}/mingw/mingw64/bin/mingw-get.exe") AND (NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw64/msys/1.0/bin/make.exe"))
|
||||
message("Installing MSYS")
|
||||
execute_process(
|
||||
COMMAND ${DOWNLOAD_DIR}/mingw/mingw64/bin/mingw-get install msys msys-patch
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/mingw/mingw64/bin/
|
||||
)
|
||||
endif()
|
||||
|
||||
if((EXISTS "${DOWNLOAD_DIR}/mingw/mingw64/bin/mingw-get.exe") AND (NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw64/msys/1.0/bin/mktemp.exe"))
|
||||
message("Installing mktemp")
|
||||
execute_process(
|
||||
COMMAND ${DOWNLOAD_DIR}/mingw/mingw64/bin/mingw-get install msys msys-mktemp
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/mingw/mingw64/bin/
|
||||
)
|
||||
endif()
|
||||
|
||||
message("Checking for CoreUtils")
|
||||
# download old core_utils for pr.exe (ffmpeg needs it to build)
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/coreutils-5.97-MSYS-1.0.11-snapshot.tar.bz2")
|
||||
message("Downloading CoreUtils 5.97")
|
||||
file(DOWNLOAD "https://nchc.dl.sourceforge.net/project/mingw/MSYS/Base/msys-core/_obsolete/coreutils-5.97-MSYS-1.0.11-2/coreutils-5.97-MSYS-1.0.11-snapshot.tar.bz2" "${DOWNLOAD_DIR}/coreutils-5.97-MSYS-1.0.11-snapshot.tar.bz2")
|
||||
endif()
|
||||
|
||||
if((EXISTS "${DOWNLOAD_DIR}/coreutils-5.97-MSYS-1.0.11-snapshot.tar.bz2") AND (NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw64/msys/1.0/bin/pr.exe"))
|
||||
message("Installing pr from CoreUtils 5.97")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E make_directory ${DOWNLOAD_DIR}/tmp_coreutils
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}
|
||||
)
|
||||
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E tar jxf ${DOWNLOAD_DIR}/coreutils-5.97-MSYS-1.0.11-snapshot.tar.bz2
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/tmp_coreutils/
|
||||
)
|
||||
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${DOWNLOAD_DIR}/tmp_coreutils/coreutils-5.97/bin/pr.exe "${DOWNLOAD_DIR}/mingw/mingw64/msys/1.0/bin/pr.exe"
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/tmp_coreutils/
|
||||
)
|
||||
endif()
|
||||
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw64/ming64sh.cmd")
|
||||
message("Installing ming64sh.cmd")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${PATCH_DIR}/ming64sh.cmd ${DOWNLOAD_DIR}/mingw/mingw64/ming64sh.cmd
|
||||
)
|
||||
endif()
|
||||
|
||||
message("Checking for perl")
|
||||
# download perl for libvpx
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/strawberry-perl-5.22.1.3-64bit-portable.zip")
|
||||
message("Downloading perl")
|
||||
file(DOWNLOAD "http://strawberryperl.com/download/5.22.1.3/strawberry-perl-5.22.1.3-64bit-portable.zip" "${DOWNLOAD_DIR}/strawberry-perl-5.22.1.3-64bit-portable.zip")
|
||||
endif()
|
||||
|
||||
# make perl root directory
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/perl")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E make_directory ${DOWNLOAD_DIR}/perl
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}
|
||||
)
|
||||
endif()
|
||||
|
||||
# extract perl
|
||||
if((NOT EXISTS "${DOWNLOAD_DIR}/perl/portable.perl") AND (EXISTS "${DOWNLOAD_DIR}/strawberry-perl-5.22.1.3-64bit-portable.zip"))
|
||||
message("Extracting perl")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E tar jxf ${DOWNLOAD_DIR}/strawberry-perl-5.22.1.3-64bit-portable.zip
|
||||
WORKING_DIRECTORY ${DOWNLOAD_DIR}/perl
|
||||
)
|
||||
endif()
|
||||
|
||||
# get yasm for vpx
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw64/bin/yasm.exe")
|
||||
message("Downloading yasm")
|
||||
file(DOWNLOAD "http://www.tortall.net/projects/yasm/releases/yasm-1.3.0-win64.exe" "${DOWNLOAD_DIR}/mingw/mingw64/bin/yasm.exe")
|
||||
endif()
|
||||
|
||||
message("checking x86_64-w64-mingw32-strings.exe")
|
||||
# copy strings.exe to x86_64-w64-mingw32-strings.exe for x264
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw64/bin/x86_64-w64-mingw32-strings.exe")
|
||||
message("fixing x86_64-w64-mingw32-strings.exe")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E copy "${DOWNLOAD_DIR}/mingw/mingw64/bin/strings.exe" "${DOWNLOAD_DIR}/mingw/mingw64/bin/x86_64-w64-mingw32-strings.exe"
|
||||
)
|
||||
endif()
|
||||
|
||||
message("checking x86_64-w64-mingw32-ar.exe")
|
||||
# copy ar.exe to x86_64-w64-mingw32-ar.exe for x264
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw64/bin/x86_64-w64-mingw32-ar.exe")
|
||||
message("fixing x86_64-w64-mingw32-ar.exe")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E copy "${DOWNLOAD_DIR}/mingw/mingw64/bin/ar.exe" "${DOWNLOAD_DIR}/mingw/mingw64/bin/x86_64-w64-mingw32-ar.exe"
|
||||
)
|
||||
endif()
|
||||
|
||||
message("checking x86_64-w64-mingw32-strip.exe")
|
||||
# copy strip.exe to x86_64-w64-mingw32-strip.exe for x264
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw64/bin/x86_64-w64-mingw32-strip.exe")
|
||||
message("fixing x86_64-w64-mingw32-strip.exe")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E copy "${DOWNLOAD_DIR}/mingw/mingw64/bin/strip.exe" "${DOWNLOAD_DIR}/mingw/mingw64/bin/x86_64-w64-mingw32-strip.exe"
|
||||
)
|
||||
endif()
|
||||
|
||||
message("checking x86_64-w64-mingw32-ranlib.exe")
|
||||
# copy ranlib.exe to x86_64-w64-mingw32-ranlib.exe for x264
|
||||
if(NOT EXISTS "${DOWNLOAD_DIR}/mingw/mingw64/bin/x86_64-w64-mingw32-ranlib.exe")
|
||||
message("fixing x86_64-w64-mingw32-ranlib.exe")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E copy "${DOWNLOAD_DIR}/mingw/mingw64/bin/ranlib.exe" "${DOWNLOAD_DIR}/mingw/mingw64/bin/x86_64-w64-mingw32-ranlib.exe"
|
||||
)
|
||||
endif()
|
@@ -1,62 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(SNDFILE_EXTRA_ARGS)
|
||||
set(SNDFILE_ENV PKG_CONFIG_PATH=${mingw_LIBDIR}/ogg/lib/pkgconfig:${mingw_LIBDIR}/vorbis/lib/pkgconfig:${mingw_LIBDIR}/flac/lib/pkgconfig:${mingw_LIBDIR})
|
||||
|
||||
if(WIN32)
|
||||
set(SNDFILE_ENV set ${SNDFILE_ENV} &&)
|
||||
# Shared for windows because static libs will drag in a libgcc dependency.
|
||||
set(SNDFILE_OPTIONS --disable-static --enable-shared )
|
||||
else()
|
||||
set(SNDFILE_OPTIONS --enable-static --disable-shared )
|
||||
endif()
|
||||
|
||||
if(UNIX)
|
||||
set(SNDFILE_PATCH_CMD ${PATCH_CMD} --verbose -p 0 -d ${BUILD_DIR}/sndfile/src/external_sndfile < ${PATCH_DIR}/sndfile.diff)
|
||||
else()
|
||||
set(SNDFILE_PATCH_CMD)
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_sndfile
|
||||
URL ${SNDFILE_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${SNDFILE_HASH}
|
||||
PREFIX ${BUILD_DIR}/sndfile
|
||||
PATCH_COMMAND ${SNDFILE_PATCH_CMD}
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/sndfile/src/external_sndfile/ && ${SNDFILE_ENV} ${CONFIGURE_COMMAND} ${SNDFILE_OPTIONS} --prefix=${mingw_LIBDIR}/sndfile
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/sndfile/src/external_sndfile/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/sndfile/src/external_sndfile/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/sndfile
|
||||
)
|
||||
|
||||
if(MSVC)
|
||||
set_target_properties(external_sndfile PROPERTIES FOLDER Mingw)
|
||||
endif()
|
||||
|
||||
add_dependencies(
|
||||
external_sndfile
|
||||
external_ogg
|
||||
external_vorbis
|
||||
)
|
||||
if(UNIX)
|
||||
add_dependencies(
|
||||
external_sndfile
|
||||
external_flac
|
||||
)
|
||||
endif()
|
@@ -1,28 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
ExternalProject_Add(external_spnav
|
||||
URL ${SPNAV_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${SPNAV_HASH}
|
||||
PREFIX ${BUILD_DIR}/spnav
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/spnav/src/external_spnav/ && ${CONFIGURE_COMMAND} --prefix=${LIBDIR}/spnav --disable-shared --enable-static --with-pic
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/spnav/src/external_spnav/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/spnav/src/external_spnav/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/spnav
|
||||
)
|
@@ -1,59 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(SQLITE_CONFIGURE_ENV echo .)
|
||||
set(SQLITE_CONFIGURATION_ARGS)
|
||||
|
||||
if(UNIX)
|
||||
if(NOT APPLE)
|
||||
set(SQLITE_LDFLAGS -Wl,--as-needed)
|
||||
endif()
|
||||
set(SQLITE_CFLAGS
|
||||
"-DSQLITE_SECURE_DELETE -DSQLITE_ENABLE_COLUMN_METADATA \
|
||||
-DSQLITE_ENABLE_FTS3 -DSQLITE_ENABLE_FTS3_PARENTHESIS \
|
||||
-DSQLITE_ENABLE_RTREE=1 -DSQLITE_SOUNDEX=1 \
|
||||
-DSQLITE_ENABLE_UNLOCK_NOTIFY \
|
||||
-DSQLITE_OMIT_LOOKASIDE=1 -DSQLITE_ENABLE_DBSTAT_VTAB \
|
||||
-DSQLITE_ENABLE_UPDATE_DELETE_LIMIT=1 \
|
||||
-DSQLITE_ENABLE_LOAD_EXTENSION \
|
||||
-DSQLITE_ENABLE_JSON1 \
|
||||
-DSQLITE_LIKE_DOESNT_MATCH_BLOBS \
|
||||
-DSQLITE_THREADSAFE=1 \
|
||||
-DSQLITE_ENABLE_FTS3_TOKENIZER=1 \
|
||||
-DSQLITE_MAX_SCHEMA_RETRY=25 \
|
||||
-DSQLITE_ENABLE_PREUPDATE_HOOK \
|
||||
-DSQLITE_ENABLE_SESSION \
|
||||
-DSQLITE_ENABLE_STMTVTAB \
|
||||
-DSQLITE_MAX_VARIABLE_NUMBER=250000 \
|
||||
-fPIC")
|
||||
set(SQLITE_CONFIGURE_ENV ${SQLITE_CONFIGURE_ENV} && export LDFLAGS=${SQLITE_LDFLAGS} && export CFLAGS=${SQLITE_CFLAGS})
|
||||
set(SQLITE_CONFIGURATION_ARGS ${SQLITE_CONFIGURATION_ARGS} --enable-threadsafe --enable-load-extension --enable-json1 --enable-fts4 --enable-fts5
|
||||
--enable-shared=no)
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_sqlite
|
||||
URL ${SQLITE_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH SHA1=${SQLITE_HASH}
|
||||
PREFIX ${BUILD_DIR}/sqlite
|
||||
PATCH_COMMAND ${SQLITE_PATCH_CMD}
|
||||
CONFIGURE_COMMAND ${SQLITE_CONFIGURE_ENV} && cd ${BUILD_DIR}/sqlite/src/external_sqlite/ && ${CONFIGURE_COMMAND} --prefix=${LIBDIR}/sqlite ${SQLITE_CONFIGURATION_ARGS}
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/sqlite/src/external_sqlite/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/sqlite/src/external_sqlite/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/sqlite
|
||||
)
|
@@ -1,48 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(SSL_CONFIGURE_COMMAND ./Configure)
|
||||
set(SSL_PATCH_CMD echo .)
|
||||
|
||||
if(APPLE)
|
||||
set(SSL_OS_COMPILER "blender-darwin-x86_64")
|
||||
else()
|
||||
if("${CMAKE_SIZEOF_VOID_P}" EQUAL "8")
|
||||
set(SSL_EXTRA_ARGS enable-ec_nistp_64_gcc_128)
|
||||
set(SSL_OS_COMPILER "blender-linux-x86_64")
|
||||
else()
|
||||
set(SSL_OS_COMPILER "blender-linux-x86")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_ssl
|
||||
URL ${SSL_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH SHA256=${SSL_HASH}
|
||||
PREFIX ${BUILD_DIR}/ssl
|
||||
PATCH_COMMAND ${SSL_PATCH_CMD}
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/ssl/src/external_ssl/ && ${SSL_CONFIGURE_COMMAND} --prefix=${LIBDIR}/ssl
|
||||
--openssldir=${LIBDIR}/ssl
|
||||
no-shared
|
||||
no-idea no-mdc2 no-rc5 no-zlib no-ssl3 enable-unit-test no-ssl3-method enable-rfc3779 enable-cms
|
||||
--config=${CMAKE_CURRENT_SOURCE_DIR}/cmake/ssl.conf
|
||||
${SSL_OS_COMPILER}
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/ssl/src/external_ssl/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/ssl/src/external_ssl/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/ssl
|
||||
)
|
@@ -1,15 +0,0 @@
|
||||
%targets = (
|
||||
|
||||
"blender-linux-x86" => {
|
||||
inherit_from => [ "linux-x86" ],
|
||||
cflags => add("-fPIC"),
|
||||
},
|
||||
"blender-linux-x86_64" => {
|
||||
inherit_from => [ "linux-x86_64" ],
|
||||
cflags => add("-fPIC"),
|
||||
},
|
||||
"blender-darwin-x86_64" => {
|
||||
inherit_from => [ "darwin64-x86_64-cc" ],
|
||||
cflags => add("-fPIC"),
|
||||
},
|
||||
);
|
@@ -1,67 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
if(WIN32)
|
||||
set(TBB_EXTRA_ARGS
|
||||
-DTBB_BUILD_SHARED=On
|
||||
-DTBB_BUILD_TBBMALLOC=On
|
||||
-DTBB_BUILD_TBBMALLOC_PROXY=On
|
||||
-DTBB_BUILD_STATIC=On
|
||||
)
|
||||
else()
|
||||
set(TBB_EXTRA_ARGS
|
||||
-DTBB_BUILD_SHARED=Off
|
||||
-DTBB_BUILD_TBBMALLOC=On
|
||||
-DTBB_BUILD_TBBMALLOC_PROXY=Off
|
||||
-DTBB_BUILD_STATIC=On
|
||||
)
|
||||
endif()
|
||||
|
||||
# CMake script for TBB from https://github.com/wjakob/tbb/blob/master/CMakeLists.txt
|
||||
ExternalProject_Add(external_tbb
|
||||
URL ${TBB_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${TBB_HASH}
|
||||
PREFIX ${BUILD_DIR}/tbb
|
||||
PATCH_COMMAND COMMAND ${CMAKE_COMMAND} -E copy ${PATCH_DIR}/cmakelists_tbb.txt ${BUILD_DIR}/tbb/src/external_tbb/CMakeLists.txt &&
|
||||
${CMAKE_COMMAND} -E copy ${BUILD_DIR}/tbb/src/external_tbb/build/vs2013/version_string.ver ${BUILD_DIR}/tbb/src/external_tbb/src/tbb/version_string.ver
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/tbb ${DEFAULT_CMAKE_FLAGS} ${TBB_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/tbb
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_tbb after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/tbb/lib/tbb_static.lib ${HARVEST_TARGET}/tbb/lib/tbb.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/tbb/lib/tbbmalloc.lib ${HARVEST_TARGET}/tbb/lib/tbbmalloc.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/tbb/lib/tbbmalloc.dll ${HARVEST_TARGET}/tbb/lib/tbbmalloc.dll
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/tbb/lib/tbbmalloc_proxy.lib ${HARVEST_TARGET}/tbb/lib/tbbmalloc_proxy.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/tbb/lib/tbbmalloc_proxy.dll ${HARVEST_TARGET}/tbb/lib/tbbmalloc_proxy.dll
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/tbb/include/ ${HARVEST_TARGET}/tbb/include/
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
ExternalProject_Add_Step(external_tbb after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/tbb/lib/tbb_static.lib ${HARVEST_TARGET}/tbb/lib/tbb_debug.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/tbb/lib/tbbmalloc_proxy.lib ${HARVEST_TARGET}/tbb/lib/tbbmalloc_proxy_debug.lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/tbb/lib/tbbmalloc.dll ${HARVEST_TARGET}/tbb/lib/debug/tbbmalloc.dll
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/tbb/lib/tbbmalloc_proxy.dll ${HARVEST_TARGET}/tbb/lib/debug/tbbmalloc_proxy.dll
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
endif()
|
@@ -1,50 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(UNIX)
|
||||
set(THEORA_CONFIGURE_ENV ${CONFIGURE_ENV} && export HAVE_PDFLATEX=no)
|
||||
else()
|
||||
set(THEORA_CONFIGURE_ENV ${CONFIGURE_ENV})
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_theora
|
||||
URL ${THEORA_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH SHA256=${THEORA_HASH}
|
||||
PREFIX ${BUILD_DIR}/theora
|
||||
CONFIGURE_COMMAND ${THEORA_CONFIGURE_ENV} && cd ${BUILD_DIR}/theora/src/external_theora/ && ${CONFIGURE_COMMAND} --prefix=${LIBDIR}/theora
|
||||
--disable-shared
|
||||
--enable-static
|
||||
--with-pic
|
||||
--with-ogg=${LIBDIR}/ogg
|
||||
--with-vorbis=${LIBDIR}/vorbis
|
||||
--disable-examples
|
||||
BUILD_COMMAND ${THEORA_CONFIGURE_ENV} && cd ${BUILD_DIR}/theora/src/external_theora/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${THEORA_CONFIGURE_ENV} && cd ${BUILD_DIR}/theora/src/external_theora/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/theora
|
||||
)
|
||||
|
||||
add_dependencies(
|
||||
external_theora
|
||||
external_vorbis
|
||||
external_ogg
|
||||
)
|
||||
|
||||
if(MSVC)
|
||||
set_target_properties(external_theora PROPERTIES FOLDER Mingw)
|
||||
endif()
|
@@ -1,47 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(TIFF_EXTRA_ARGS
|
||||
-DZLIB_LIBRARY=${LIBDIR}/zlib/lib/${ZLIB_LIBRARY}
|
||||
-DZLIB_INCLUDE_DIR=${LIBDIR}/zlib/include
|
||||
-DPNG_STATIC=ON
|
||||
-DBUILD_SHARED_LIBS=OFF
|
||||
-Dlzma=OFF
|
||||
-Djbig=OFF
|
||||
)
|
||||
|
||||
ExternalProject_Add(external_tiff
|
||||
URL ${TIFF_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${TIFF_HASH}
|
||||
PREFIX ${BUILD_DIR}/tiff
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/tiff ${DEFAULT_CMAKE_FLAGS} ${TIFF_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/tiff
|
||||
)
|
||||
|
||||
add_dependencies(
|
||||
external_tiff
|
||||
external_zlib
|
||||
)
|
||||
|
||||
if(WIN32 AND BUILD_MODE STREQUAL Debug)
|
||||
ExternalProject_Add_Step(external_tiff after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/tiff/lib/tiffd${LIBEXT} ${LIBDIR}/tiff/lib/tiff${LIBEXT}
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
@@ -1,31 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(TINYXML_EXTRA_ARGS
|
||||
)
|
||||
|
||||
ExternalProject_Add(external_tinyxml
|
||||
URL ${TINYXML_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${TINYXML_HASH}
|
||||
PREFIX ${BUILD_DIR}/tinyxml
|
||||
# patch taken from ocio
|
||||
PATCH_COMMAND ${PATCH_CMD} -p 1 -N -d ${BUILD_DIR}/tinyxml/src/external_tinyxml < ${PATCH_DIR}/tinyxml.diff
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/tinyxml ${DEFAULT_CMAKE_FLAGS} ${TINYXML_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/tinyxml
|
||||
)
|
@@ -1,101 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(USD_EXTRA_ARGS
|
||||
-DBoost_COMPILER:STRING=${BOOST_COMPILER_STRING}
|
||||
-DBoost_USE_MULTITHREADED=ON
|
||||
-DBoost_USE_STATIC_LIBS=ON
|
||||
-DBoost_USE_STATIC_RUNTIME=OFF
|
||||
-DBOOST_ROOT=${LIBDIR}/boost
|
||||
-DTBB_INCLUDE_DIRS=${LIBDIR}/tbb/include
|
||||
-DTBB_LIBRARIES=${LIBDIR}/tbb/lib/${LIBPREFIX}tbb_static${LIBEXT}
|
||||
-DTbb_TBB_LIBRARY=${LIBDIR}/tbb/lib/${LIBPREFIX}tbb_static${LIBEXT}
|
||||
|
||||
# This is a preventative measure that avoids possible conflicts when add-ons
|
||||
# try to load another USD library into the same process space.
|
||||
-DPXR_SET_INTERNAL_NAMESPACE=usdBlender
|
||||
|
||||
-DPXR_ENABLE_PYTHON_SUPPORT=OFF
|
||||
-DPXR_BUILD_IMAGING=OFF
|
||||
-DPXR_BUILD_TESTS=OFF
|
||||
-DBUILD_SHARED_LIBS=OFF
|
||||
-DPYTHON_EXECUTABLE=${PYTHON_BINARY}
|
||||
-DPXR_BUILD_MONOLITHIC=ON
|
||||
|
||||
# The PXR_BUILD_USD_TOOLS argument is patched-in by usd.diff. An upstream pull request
|
||||
# can be found at https://github.com/PixarAnimationStudios/USD/pull/1048.
|
||||
-DPXR_BUILD_USD_TOOLS=OFF
|
||||
|
||||
-DCMAKE_DEBUG_POSTFIX=_d
|
||||
# USD is hellbound on making a shared lib, unless you point this variable to a valid cmake file
|
||||
# doesn't have to make sense, but as long as it points somewhere valid it will skip the shared lib.
|
||||
-DPXR_MONOLITHIC_IMPORT=${BUILD_DIR}/usd/src/external_usd/cmake/defaults/Version.cmake
|
||||
)
|
||||
|
||||
ExternalProject_Add(external_usd
|
||||
URL ${USD_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${USD_HASH}
|
||||
PREFIX ${BUILD_DIR}/usd
|
||||
PATCH_COMMAND ${PATCH_CMD} -p 1 -d ${BUILD_DIR}/usd/src/external_usd < ${PATCH_DIR}/usd.diff
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/usd -Wno-dev ${DEFAULT_CMAKE_FLAGS} ${USD_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/usd
|
||||
)
|
||||
|
||||
add_dependencies(
|
||||
external_usd
|
||||
external_tbb
|
||||
external_boost
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
# USD currently demands python be available at build time
|
||||
# and then proceeds not to use it, but still checks that the
|
||||
# version of the interpreter it is not going to use is atleast 2.7
|
||||
# so we need this dep currently since there is no system python
|
||||
# on windows.
|
||||
add_dependencies(
|
||||
external_usd
|
||||
external_python
|
||||
)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_usd after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/usd/ ${HARVEST_TARGET}/usd
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${BUILD_DIR}/usd/src/external_usd-build/pxr/Release/libusd_m.lib ${HARVEST_TARGET}/usd/lib/libusd_m.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
ExternalProject_Add_Step(external_usd after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/usd/lib ${HARVEST_TARGET}/usd/lib
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${BUILD_DIR}/usd/src/external_usd-build/pxr/Debug/libusd_m_d.lib ${HARVEST_TARGET}/usd/lib/libusd_m_d.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
else()
|
||||
# USD has two build options. The default build creates lots of small libraries,
|
||||
# whereas the 'monolithic' build produces only a single library. The latter
|
||||
# makes linking simpler, so that's what we use in Blender. However, running
|
||||
# 'make install' in the USD sources doesn't install the static library in that
|
||||
# case (only the shared library). As a result, we need to grab the `libusd_m.a`
|
||||
# file from the build directory instead of from the install directory.
|
||||
ExternalProject_Add_Step(external_usd after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${BUILD_DIR}/usd/src/external_usd-build/pxr/libusd_m.a ${HARVEST_TARGET}/usd/lib/libusd_m.a
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
@@ -1,324 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(ZLIB_VERSION 1.2.11)
|
||||
set(ZLIB_URI https://zlib.net/zlib-${ZLIB_VERSION}.tar.gz)
|
||||
set(ZLIB_HASH 1c9f62f0778697a09d36121ead88e08e)
|
||||
|
||||
set(OPENAL_VERSION 1.18.2)
|
||||
set(OPENAL_URI http://openal-soft.org/openal-releases/openal-soft-${OPENAL_VERSION}.tar.bz2)
|
||||
set(OPENAL_HASH d4eeb0889812e2fdeaa1843523d76190)
|
||||
|
||||
set(PNG_VERSION 1.6.35)
|
||||
set(PNG_URI http://prdownloads.sourceforge.net/libpng/libpng-${PNG_VERSION}.tar.xz)
|
||||
set(PNG_HASH 678b7e696a62a193ed3503b04bf449d6)
|
||||
|
||||
set(JPEG_VERSION 1.5.3)
|
||||
set(JPEG_URI https://github.com/libjpeg-turbo/libjpeg-turbo/archive/${JPEG_VERSION}.tar.gz)
|
||||
set(JPEG_HASH 5b7549d440b86c98a517355c102d155e)
|
||||
|
||||
set(BOOST_VERSION 1.70.0)
|
||||
set(BOOST_VERSION_NODOTS 1_70_0)
|
||||
set(BOOST_VERSION_NODOTS_SHORT 1_70)
|
||||
set(BOOST_URI https://dl.bintray.com/boostorg/release/${BOOST_VERSION}/source/boost_${BOOST_VERSION_NODOTS}.tar.gz)
|
||||
set(BOOST_HASH fea771fe8176828fabf9c09242ee8c26)
|
||||
|
||||
# Using old version as recommended by OpenVDB build documentation.
|
||||
set(BLOSC_VERSION 1.5.0)
|
||||
set(BLOSC_URI https://github.com/Blosc/c-blosc/archive/v${BLOSC_VERSION}.tar.gz)
|
||||
set(BLOSC_HASH 6e4a49c8c06f05aa543f3312cfce3d55)
|
||||
|
||||
set(PTHREADS_VERSION 3.0.0)
|
||||
set(PTHREADS_URI http://sourceforge.mirrorservice.org/p/pt/pthreads4w/pthreads4w-code-v${PTHREADS_VERSION}.zip)
|
||||
set(PTHREADS_HASH f3bf81bb395840b3446197bcf4ecd653)
|
||||
|
||||
set(OPENEXR_VERSION 2.4.0)
|
||||
set(OPENEXR_URI https://github.com/AcademySoftwareFoundation/openexr/archive/v${OPENEXR_VERSION}.tar.gz)
|
||||
set(OPENEXR_HASH 9e4d69cf2a12c6fb19b98af7c5e0eaee)
|
||||
if(WIN32)
|
||||
# Openexr started appending _d on its own so now
|
||||
# we need to tell the build the postfix is _s while
|
||||
# telling all other deps the postfix is _s_d
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
set(OPENEXR_VERSION_POSTFIX _s)
|
||||
set(OPENEXR_VERSION_BUILD_POSTFIX _s)
|
||||
else()
|
||||
set(OPENEXR_VERSION_POSTFIX _s_d)
|
||||
set(OPENEXR_VERSION_BUILD_POSTFIX _s)
|
||||
endif()
|
||||
else()
|
||||
set(OPENEXR_VERSION_BUILD_POSTFIX)
|
||||
set(OPENEXR_VERSION_POSTFIX)
|
||||
endif()
|
||||
|
||||
set(FREETYPE_VERSION 2.10.1)
|
||||
set(FREETYPE_URI http://prdownloads.sourceforge.net/freetype/freetype-${FREETYPE_VERSION}.tar.gz)
|
||||
set(FREETYPE_HASH c50a3c9e5e62bdc938a6e1598a782947)
|
||||
|
||||
set(GLEW_VERSION 1.13.0)
|
||||
set(GLEW_URI http://prdownloads.sourceforge.net/glew/glew/${GLEW_VERSION}/glew-${GLEW_VERSION}.tgz)
|
||||
set(GLEW_HASH 7cbada3166d2aadfc4169c4283701066)
|
||||
|
||||
set(FREEGLUT_VERSION 3.0.0)
|
||||
set(FREEGLUT_URI http://pilotfiber.dl.sourceforge.net/project/freeglut/freeglut/${FREEGLUT_VERSION}/freeglut-${FREEGLUT_VERSION}.tar.gz)
|
||||
set(FREEGLUT_HASH 90c3ca4dd9d51cf32276bc5344ec9754)
|
||||
|
||||
set(HDF5_VERSION 1.8.17)
|
||||
set(HDF5_URI https://support.hdfgroup.org/ftp/HDF5/releases/hdf5-1.8/hdf5-${HDF5_VERSION}/src/hdf5-${HDF5_VERSION}.tar.gz)
|
||||
set(HDF5_HASH 7d572f8f3b798a628b8245af0391a0ca)
|
||||
|
||||
set(ALEMBIC_VERSION 1.7.12)
|
||||
set(ALEMBIC_URI https://github.com/alembic/alembic/archive/${ALEMBIC_VERSION}.tar.gz)
|
||||
set(ALEMBIC_MD5 e2b3777f23c5c09481a008cc6f0f8a40)
|
||||
|
||||
# hash is for 3.1.2
|
||||
set(GLFW_GIT_UID 30306e54705c3adae9fe082c816a3be71963485c)
|
||||
set(GLFW_URI https://github.com/glfw/glfw/archive/${GLFW_GIT_UID}.zip)
|
||||
set(GLFW_HASH 20cacb1613da7eeb092f3ac4f6b2b3d0)
|
||||
|
||||
# latest uid in git as of 2016-04-01
|
||||
set(CLEW_GIT_UID 277db43f6cafe8b27c6f1055f69dc67da4aeb299)
|
||||
set(CLEW_URI https://github.com/OpenCLWrangler/clew/archive/${CLEW_GIT_UID}.zip)
|
||||
set(CLEW_HASH 2c699d10ed78362e71f56fae2a4c5f98)
|
||||
|
||||
# latest uid in git as of 2016-04-01
|
||||
set(CUEW_GIT_UID 1744972026de9cf27c8a7dc39cf39cd83d5f922f)
|
||||
set(CUEW_URI https://github.com/CudaWrangler/cuew/archive/${CUEW_GIT_UID}.zip)
|
||||
set(CUEW_HASH 86760d62978ebfd96cd93f5aa1abaf4a)
|
||||
|
||||
set(OPENSUBDIV_VERSION v3_4_0_RC2)
|
||||
set(OPENSUBDIV_Hash f6a10ba9efaa82fde86fe65aad346319)
|
||||
set(OPENSUBDIV_URI https://github.com/PixarAnimationStudios/OpenSubdiv/archive/${OPENSUBDIV_VERSION}.tar.gz)
|
||||
|
||||
set(SDL_VERSION 2.0.8)
|
||||
set(SDL_URI https://www.libsdl.org/release/SDL2-${SDL_VERSION}.tar.gz)
|
||||
set(SDL_HASH 3800d705cef742c6a634f202c37f263f)
|
||||
|
||||
set(OPENCOLLADA_VERSION v1.6.68)
|
||||
set(OPENCOLLADA_URI https://github.com/KhronosGroup/OpenCOLLADA/archive/${OPENCOLLADA_VERSION}.tar.gz)
|
||||
set(OPENCOLLADA_HASH ee7dae874019fea7be11613d07567493)
|
||||
|
||||
set(OPENCOLORIO_VERSION 1.1.0)
|
||||
set(OPENCOLORIO_URI https://github.com/imageworks/OpenColorIO/archive/v${OPENCOLORIO_VERSION}.tar.gz)
|
||||
set(OPENCOLORIO_HASH 802d8f5b1d1fe316ec5f76511aa611b8)
|
||||
|
||||
set(LLVM_VERSION 9.0.1)
|
||||
set(LLVM_URI https://github.com/llvm/llvm-project/releases/download/llvmorg-${LLVM_VERSION}/llvm-${LLVM_VERSION}.src.tar.xz)
|
||||
set(LLVM_HASH 31eb9ce73dd2a0f8dcab8319fb03f8fc)
|
||||
|
||||
set(CLANG_URI https://github.com/llvm/llvm-project/releases/download/llvmorg-${LLVM_VERSION}/clang-${LLVM_VERSION}.src.tar.xz)
|
||||
set(CLANG_HASH 13468e4a44940efef1b75e8641752f90)
|
||||
|
||||
set(OPENMP_URI https://github.com/llvm/llvm-project/releases/download/llvmorg-${LLVM_VERSION}/openmp-${LLVM_VERSION}.src.tar.xz)
|
||||
set(OPENMP_HASH 6eade16057edbdecb3c4eef9daa2bfcf)
|
||||
|
||||
set(OPENIMAGEIO_VERSION 1.8.13)
|
||||
set(OPENIMAGEIO_URI https://github.com/OpenImageIO/oiio/archive/Release-${OPENIMAGEIO_VERSION}.tar.gz)
|
||||
set(OPENIMAGEIO_HASH f5526c3c9878029ee900d84856683f93)
|
||||
|
||||
set(TIFF_VERSION 4.0.9)
|
||||
set(TIFF_URI http://download.osgeo.org/libtiff/tiff-${TIFF_VERSION}.tar.gz)
|
||||
set(TIFF_HASH 54bad211279cc93eb4fca31ba9bfdc79)
|
||||
|
||||
set(OSL_VERSION 1.10.9)
|
||||
set(OSL_URI https://github.com/imageworks/OpenShadingLanguage/archive/Release-${OSL_VERSION}.tar.gz)
|
||||
set(OSL_HASH a94f1e8506f7e8f5e993653de5c5fa00)
|
||||
|
||||
set(PYTHON_VERSION 3.7.4)
|
||||
set(PYTHON_SHORT_VERSION 3.7)
|
||||
set(PYTHON_SHORT_VERSION_NO_DOTS 37)
|
||||
set(PYTHON_URI https://www.python.org/ftp/python/${PYTHON_VERSION}/Python-${PYTHON_VERSION}.tar.xz)
|
||||
set(PYTHON_HASH d33e4aae66097051c2eca45ee3604803)
|
||||
|
||||
set(TBB_VERSION 2019_U9)
|
||||
set(TBB_URI https://github.com/oneapi-src/oneTBB/archive/${TBB_VERSION}.tar.gz)
|
||||
set(TBB_HASH 26263622e9187212ec240dcf01b66207)
|
||||
|
||||
set(OPENVDB_VERSION 7.0.0)
|
||||
set(OPENVDB_URI https://github.com/dreamworksanimation/openvdb/archive/v${OPENVDB_VERSION}.tar.gz)
|
||||
set(OPENVDB_HASH fd6c4f168282f7e0e494d290cd531fa8)
|
||||
|
||||
set(IDNA_VERSION 2.8)
|
||||
set(CHARDET_VERSION 3.0.4)
|
||||
set(URLLIB3_VERSION 1.25.3)
|
||||
set(CERTIFI_VERSION 2019.6.16)
|
||||
set(REQUESTS_VERSION 2.22.0)
|
||||
|
||||
set(NUMPY_VERSION v1.17.0)
|
||||
set(NUMPY_SHORT_VERSION 1.17)
|
||||
set(NUMPY_URI https://files.pythonhosted.org/packages/da/32/1b8f2bb5fb50e4db68543eb85ce37b9fa6660cd05b58bddfafafa7ed62da/numpy-1.17.0.zip)
|
||||
set(NUMPY_HASH aed49b31bcb44ec73b8155be78566135)
|
||||
|
||||
set(LAME_VERSION 3.100)
|
||||
set(LAME_URI http://downloads.sourceforge.net/project/lame/lame/3.100/lame-${LAME_VERSION}.tar.gz)
|
||||
set(LAME_HASH 83e260acbe4389b54fe08e0bdbf7cddb)
|
||||
|
||||
set(OGG_VERSION 1.3.3)
|
||||
set(OGG_URI http://downloads.xiph.org/releases/ogg/libogg-${OGG_VERSION}.tar.gz)
|
||||
set(OGG_HASH c2e8a485110b97550f453226ec644ebac6cb29d1caef2902c007edab4308d985)
|
||||
|
||||
set(VORBIS_VERSION 1.3.6)
|
||||
set(VORBIS_URI http://downloads.xiph.org/releases/vorbis/libvorbis-${VORBIS_VERSION}.tar.gz)
|
||||
set(VORBIS_HASH 6ed40e0241089a42c48604dc00e362beee00036af2d8b3f46338031c9e0351cb)
|
||||
|
||||
set(THEORA_VERSION 1.1.1)
|
||||
set(THEORA_URI http://downloads.xiph.org/releases/theora/libtheora-${THEORA_VERSION}.tar.bz2)
|
||||
set(THEORA_HASH b6ae1ee2fa3d42ac489287d3ec34c5885730b1296f0801ae577a35193d3affbc)
|
||||
|
||||
set(FLAC_VERSION 1.3.2)
|
||||
set(FLAC_URI http://downloads.xiph.org/releases/flac/flac-${FLAC_VERSION}.tar.xz)
|
||||
set(FLAC_HASH 91cfc3ed61dc40f47f050a109b08610667d73477af6ef36dcad31c31a4a8d53f)
|
||||
|
||||
set(VPX_VERSION 1.7.0)
|
||||
set(VPX_URI https://github.com/webmproject/libvpx/archive/v${VPX_VERSION}/libvpx-v${VPX_VERSION}.tar.gz)
|
||||
set(VPX_HASH 1fec931eb5c94279ad219a5b6e0202358e94a93a90cfb1603578c326abfc1238)
|
||||
|
||||
set(OPUS_VERSION 1.3.1)
|
||||
set(OPUS_URI https://archive.mozilla.org/pub/opus/opus-${OPUS_VERSION}.tar.gz)
|
||||
set(OPUS_HASH 65b58e1e25b2a114157014736a3d9dfeaad8d41be1c8179866f144a2fb44ff9d)
|
||||
|
||||
set(X264_URI http://download.videolan.org/pub/videolan/x264/snapshots/x264-snapshot-20180811-2245-stable.tar.bz2)
|
||||
set(X264_HASH ae8a868a0e236a348b35d79f3ee80294b169d1195408b689f9851383661ed7aa)
|
||||
|
||||
set(XVIDCORE_VERSION 1.3.5)
|
||||
set(XVIDCORE_URI http://downloads.xvid.org/downloads/xvidcore-${XVIDCORE_VERSION}.tar.gz)
|
||||
set(XVIDCORE_HASH 165ba6a2a447a8375f7b06db5a3c91810181f2898166e7c8137401d7fc894cf0)
|
||||
|
||||
# This has to be in sync with the version in blenders /extern folder.
|
||||
set(OPENJPEG_VERSION 2.3.0)
|
||||
set(OPENJPEG_SHORT_VERSION 2.3)
|
||||
# Use slightly newer commit after release which includes a cmake fix
|
||||
set(OPENJPEG_URI https://github.com/uclouvain/openjpeg/archive/66297f07a43.zip)
|
||||
set(OPENJPEG_HASH 8242b18d908c7c42174e4231a741cfa7ce7c26b6ed5c9644feb9df7b3054310b)
|
||||
|
||||
set(FAAD_VERSION 2-2.8.8)
|
||||
set(FAAD_URI http://downloads.sourceforge.net/faac/faad${FAAD_VERSION}.tar.gz)
|
||||
set(FAAD_HASH 28f6116efdbe9378269f8a6221767d1f)
|
||||
|
||||
set(FFMPEG_VERSION 4.0.2)
|
||||
set(FFMPEG_URI http://ffmpeg.org/releases/ffmpeg-${FFMPEG_VERSION}.tar.bz2)
|
||||
set(FFMPEG_HASH 5576e8a22f80b6a336db39808f427cfb)
|
||||
|
||||
set(FFTW_VERSION 3.3.8)
|
||||
set(FFTW_URI http://www.fftw.org/fftw-${FFTW_VERSION}.tar.gz)
|
||||
set(FFTW_HASH 8aac833c943d8e90d51b697b27d4384d)
|
||||
|
||||
set(ICONV_VERSION 1.15)
|
||||
set(ICONV_URI http://ftp.gnu.org/pub/gnu/libiconv/libiconv-${ICONV_VERSION}.tar.gz)
|
||||
set(ICONV_HASH ace8b5f2db42f7b3b3057585e80d9808)
|
||||
|
||||
set(LAPACK_VERSION 3.6.0)
|
||||
set(LAPACK_URI http://www.netlib.org/lapack/lapack-${LAPACK_VERSION}.tgz)
|
||||
set(LAPACK_HASH f2f6c67134e851fe189bb3ca1fbb5101)
|
||||
|
||||
set(SNDFILE_VERSION 1.0.28)
|
||||
set(SNDFILE_URI http://www.mega-nerd.com/libsndfile/files/libsndfile-${SNDFILE_VERSION}.tar.gz)
|
||||
set(SNDFILE_HASH 646b5f98ce89ac60cdb060fcd398247c)
|
||||
|
||||
# set(HIDAPI_VERSION 0.8.0-rc1)
|
||||
# set(HIDAPI_URI https://github.com/signal11/hidapi/archive/hidapi-${HIDAPI_VERSION}.tar.gz)
|
||||
# set(HIDAPI_HASH 069f9dd746edc37b6b6d0e3656f47199)
|
||||
|
||||
set(HIDAPI_UID 89a6c75dc6f45ecabd4ddfbd2bf5ba6ad8ba38b5)
|
||||
set(HIDAPI_URI https://github.com/TheOnlyJoey/hidapi/archive/${HIDAPI_UID}.zip)
|
||||
set(HIDAPI_HASH b6e22f6b514f8bcf594989f20ffc46fb)
|
||||
|
||||
set(WEBP_VERSION 0.6.1)
|
||||
set(WEBP_URI https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-${WEBP_VERSION}.tar.gz)
|
||||
set(WEBP_HASH b49ce9c3e3e9acae4d91bca44bb85a72)
|
||||
|
||||
set(SPNAV_VERSION 0.2.3)
|
||||
set(SPNAV_URI http://downloads.sourceforge.net/project/spacenav/spacenav%20library%20%28SDK%29/libspnav%20${SPNAV_VERSION}/libspnav-${SPNAV_VERSION}.tar.gz)
|
||||
set(SPNAV_HASH 44d840540d53326d4a119c0f1aa7bf0a)
|
||||
|
||||
set(JEMALLOC_VERSION 5.0.1)
|
||||
set(JEMALLOC_URI https://github.com/jemalloc/jemalloc/releases/download/${JEMALLOC_VERSION}/jemalloc-${JEMALLOC_VERSION}.tar.bz2)
|
||||
set(JEMALLOC_HASH 507f7b6b882d868730d644510491d18f)
|
||||
|
||||
set(XML2_VERSION 2.9.4)
|
||||
set(XML2_URI http://xmlsoft.org/sources/libxml2-${XML2_VERSION}.tar.gz)
|
||||
set(XML2_HASH ae249165c173b1ff386ee8ad676815f5)
|
||||
|
||||
set(TINYXML_VERSION 2_6_2)
|
||||
set(TINYXML_VERSION_DOTS 2.6.2)
|
||||
set(TINYXML_URI https://nchc.dl.sourceforge.net/project/tinyxml/tinyxml/${TINYXML_VERSION_DOTS}/tinyxml_${TINYXML_VERSION}.tar.gz)
|
||||
set(TINYXML_HASH c1b864c96804a10526540c664ade67f0)
|
||||
|
||||
set(YAMLCPP_VERSION 0.6.3)
|
||||
set(YAMLCPP_URI https://codeload.github.com/jbeder/yaml-cpp/tar.gz/yaml-cpp-${YAMLCPP_VERSION})
|
||||
set(YAMLCPP_HASH b45bf1089a382e81f6b661062c10d0c2)
|
||||
|
||||
set(LCMS_VERSION 2.9)
|
||||
set(LCMS_URI https://nchc.dl.sourceforge.net/project/lcms/lcms/${LCMS_VERSION}/lcms2-${LCMS_VERSION}.tar.gz)
|
||||
set(LCMS_HASH 8de1b7724f578d2995c8fdfa35c3ad0e)
|
||||
|
||||
set(PUGIXML_VERSION 1.9)
|
||||
set(PUGIXML_URI https://github.com/zeux/pugixml/archive/v1.9.tar.gz)
|
||||
set(PUGIXML_HASH 9346ca1dce2c48f1748c12fdac41a714)
|
||||
|
||||
set(FLEXBISON_VERSION 2.5.5)
|
||||
set(FLEXBISON_URI http://prdownloads.sourceforge.net/winflexbison//win_flex_bison-2.5.5.zip)
|
||||
set(FLEXBISON_HASH d87a3938194520d904013abef3df10ce)
|
||||
|
||||
# Libraries to keep Python modules static on Linux.
|
||||
|
||||
# NOTE: bzip.org domain does no longer belong to BZip 2 project, so we download
|
||||
# sources from Debian packaging.
|
||||
set(BZIP2_VERSION 1.0.6)
|
||||
set(BZIP2_URI http://http.debian.net/debian/pool/main/b/bzip2/bzip2_${BZIP2_VERSION}.orig.tar.bz2)
|
||||
set(BZIP2_HASH d70a9ccd8bdf47e302d96c69fecd54925f45d9c7b966bb4ef5f56b770960afa7)
|
||||
|
||||
set(FFI_VERSION 3.2.1)
|
||||
set(FFI_URI https://sourceware.org/pub/libffi/libffi-${FFI_VERSION}.tar.gz)
|
||||
set(FFI_HASH d06ebb8e1d9a22d19e38d63fdb83954253f39bedc5d46232a05645685722ca37)
|
||||
|
||||
set(LZMA_VERSION 5.2.4)
|
||||
set(LZMA_URI https://tukaani.org/xz/xz-${LZMA_VERSION}.tar.bz2)
|
||||
set(LZMA_HASH 3313fd2a95f43d88e44264e6b015e7d03053e681860b0d5d3f9baca79c57b7bf)
|
||||
|
||||
set(SSL_VERSION 1.1.0i)
|
||||
set(SSL_URI https://www.openssl.org/source/openssl-${SSL_VERSION}.tar.gz)
|
||||
set(SSL_HASH ebbfc844a8c8cc0ea5dc10b86c9ce97f401837f3fa08c17b2cdadc118253cf99)
|
||||
|
||||
set(SQLITE_VERSION 3.24.0)
|
||||
set(SQLITE_URI https://www.sqlite.org/2018/sqlite-src-3240000.zip)
|
||||
set(SQLITE_HASH fb558c49ee21a837713c4f1e7e413309aabdd9c7)
|
||||
|
||||
set(EMBREE_VERSION 3.8.0)
|
||||
set(EMBREE_URI https://github.com/embree/embree/archive/v${EMBREE_VERSION}.zip)
|
||||
set(EMBREE_HASH ac504d5426945fe25dec1267e0c39d52)
|
||||
|
||||
set(USD_VERSION 19.11)
|
||||
set(USD_URI https://github.com/PixarAnimationStudios/USD/archive/v${USD_VERSION}.tar.gz)
|
||||
set(USD_HASH 79ff176167b3fe85f4953abd6cc5e0cc)
|
||||
|
||||
set(OIDN_VERSION 1.0.0)
|
||||
set(OIDN_URI https://github.com/OpenImageDenoise/oidn/releases/download/v${OIDN_VERSION}/oidn-${OIDN_VERSION}.src.zip)
|
||||
set(OIDN_HASH 19fe67b0164e8f020ac8a4f520defe60)
|
||||
|
||||
set(LIBGLU_VERSION 9.0.1)
|
||||
set(LIBGLU_URI ftp://ftp.freedesktop.org/pub/mesa/glu/glu-${LIBGLU_VERSION}.tar.xz)
|
||||
set(LIBGLU_HASH 151aef599b8259efe9acd599c96ea2a3)
|
||||
|
||||
set(MESA_VERSION 18.3.1)
|
||||
set(MESA_URI ftp://ftp.freedesktop.org/pub/mesa//mesa-${MESA_VERSION}.tar.xz)
|
||||
set(MESA_HASH d60828056d77bfdbae0970f9b15fb1be)
|
||||
|
||||
set(XR_OPENXR_SDK_VERSION 1.0.6)
|
||||
set(XR_OPENXR_SDK_URI https://github.com/KhronosGroup/OpenXR-SDK/archive/release-${XR_OPENXR_SDK_VERSION}.tar.gz)
|
||||
set(XR_OPENXR_SDK_HASH 21daea7c3bfec365298d779a0e19caa1)
|
@@ -1,41 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
ExternalProject_Add(external_vorbis
|
||||
URL ${VORBIS_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH SHA256=${VORBIS_HASH}
|
||||
PREFIX ${BUILD_DIR}/vorbis
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/vorbis/src/external_vorbis/ && ${CONFIGURE_COMMAND} --prefix=${LIBDIR}/vorbis
|
||||
--disable-shared
|
||||
--enable-static
|
||||
--with-pic
|
||||
--with-ogg=${LIBDIR}/ogg
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/vorbis/src/external_vorbis/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/vorbis/src/external_vorbis/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/vorbis
|
||||
)
|
||||
|
||||
add_dependencies(
|
||||
external_vorbis
|
||||
external_ogg
|
||||
)
|
||||
|
||||
if(MSVC)
|
||||
set_target_properties(external_vorbis PROPERTIES FOLDER Mingw)
|
||||
endif()
|
@@ -1,62 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(WIN32)
|
||||
if("${CMAKE_SIZEOF_VOID_P}" EQUAL "8")
|
||||
set(VPX_EXTRA_FLAGS --target=x86_64-win64-gcc --disable-multithread)
|
||||
else()
|
||||
set(VPX_EXTRA_FLAGS --target=x86-win32-gcc --disable-multithread)
|
||||
endif()
|
||||
else()
|
||||
if(APPLE)
|
||||
set(VPX_EXTRA_FLAGS --target=x86_64-darwin13-gcc)
|
||||
else()
|
||||
set(VPX_EXTRA_FLAGS --target=generic-gnu)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_vpx
|
||||
URL ${VPX_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH SHA256=${VPX_HASH}
|
||||
PREFIX ${BUILD_DIR}/vpx
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} &&
|
||||
cd ${BUILD_DIR}/vpx/src/external_vpx/ &&
|
||||
${CONFIGURE_COMMAND_NO_TARGET} --prefix=${LIBDIR}/vpx
|
||||
--disable-shared
|
||||
--enable-static
|
||||
--disable-install-bins
|
||||
--disable-install-srcs
|
||||
--disable-sse4_1
|
||||
--disable-sse3
|
||||
--disable-ssse3
|
||||
--disable-avx
|
||||
--disable-avx2
|
||||
--disable-unit-tests
|
||||
--disable-examples
|
||||
--enable-vp8
|
||||
--enable-vp9
|
||||
${VPX_EXTRA_FLAGS}
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/vpx/src/external_vpx/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/vpx/src/external_vpx/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/vpx
|
||||
)
|
||||
|
||||
if(MSVC)
|
||||
set_target_properties(external_vpx PROPERTIES FOLDER Mingw)
|
||||
endif()
|
@@ -1,50 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
# Note the utility apps may use png/tiff/gif system libraries, but the
|
||||
# library itself does not depend on them, so should give no problems.
|
||||
|
||||
set(WEBP_EXTRA_ARGS
|
||||
-DWEBP_HAVE_SSE2=ON
|
||||
-DWEBP_HAVE_SSE41=OFF
|
||||
-DWEBP_HAVE_AVX2=OFF
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
set(WEBP_BUILD_DIR ${BUILD_MODE}/)
|
||||
else()
|
||||
set(WEBP_BUILD_DIR)
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_webp
|
||||
URL ${WEBP_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${WEBP_HASH}
|
||||
PREFIX ${BUILD_DIR}/webp
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/webp -Wno-dev ${DEFAULT_CMAKE_FLAGS} ${WEBP_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/webp
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_webp after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/webp ${HARVEST_TARGET}/webp
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
endif()
|
@@ -1,45 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(WIN32)
|
||||
set(X264_EXTRA_ARGS --enable-win32thread --cross-prefix=${MINGW_HOST}- --host=${MINGW_HOST})
|
||||
set(X264_PATCH_CMD ${PATCH_CMD} --verbose -p 1 -N -d ${BUILD_DIR}/x264/src/external_x264 < ${PATCH_DIR}/x264.diff)
|
||||
else()
|
||||
set(X264_PATCH_CMD echo .)
|
||||
endif()
|
||||
|
||||
|
||||
ExternalProject_Add(external_x264
|
||||
URL ${X264_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH SHA256=${X264_HASH}
|
||||
PREFIX ${BUILD_DIR}/x264
|
||||
PATCH_COMMAND ${X264_PATCH_CMD}
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/x264/src/external_x264/ && ${CONFIGURE_COMMAND} --prefix=${LIBDIR}/x264
|
||||
--enable-static
|
||||
--enable-pic
|
||||
--disable-lavf
|
||||
${X264_EXTRA_ARGS}
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/x264/src/external_x264/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/x264/src/external_x264/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/x264
|
||||
)
|
||||
|
||||
if(MSVC)
|
||||
set_target_properties(external_x264 PROPERTIES FOLDER Mingw)
|
||||
endif()
|
@@ -1,36 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
ExternalProject_Add(external_xml2
|
||||
URL ${XML2_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${XML2_HASH}
|
||||
PREFIX ${BUILD_DIR}/xml2
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/xml2/src/external_xml2/ && ${CONFIGURE_COMMAND}
|
||||
--prefix=${LIBDIR}/xml2
|
||||
--disable-shared
|
||||
--enable-static
|
||||
--with-pic
|
||||
--with-python=no
|
||||
--with-lzma=no
|
||||
--with-zlib=no
|
||||
--with-iconv=no
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/xml2/src/external_xml2/ && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/xml2/src/external_xml2/ && make install
|
||||
INSTALL_DIR ${LIBDIR}/xml2
|
||||
)
|
@@ -1,60 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
|
||||
# Keep flags in sync with install_deps.sh ones in compile_XR_OpenXR_SDK()
|
||||
set(XR_OPENXR_SDK_EXTRA_ARGS
|
||||
-DBUILD_FORCE_GENERATION=OFF
|
||||
-DBUILD_LOADER=ON
|
||||
-DDYNAMIC_LOADER=OFF
|
||||
)
|
||||
|
||||
if(UNIX AND NOT APPLE)
|
||||
list(APPEND XR_OPENXR_SDK_EXTRA_ARGS
|
||||
-DBUILD_WITH_WAYLAND_HEADERS=OFF
|
||||
-DBUILD_WITH_XCB_HEADERS=OFF
|
||||
-DBUILD_WITH_XLIB_HEADERS=ON
|
||||
-DBUILD_WITH_SYSTEM_JSONCPP=OFF
|
||||
-DCMAKE_CXX_FLAGS=-DDISABLE_STD_FILESYSTEM=1
|
||||
)
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_xr_openxr_sdk
|
||||
URL ${XR_OPENXR_SDK_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${XR_OPENXR_SDK_HASH}
|
||||
PREFIX ${BUILD_DIR}/xr_openxr_sdk
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/xr_openxr_sdk ${DEFAULT_CMAKE_FLAGS} ${XR_OPENXR_SDK_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/xr_openxr_sdk
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_xr_openxr_sdk after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/xr_openxr_sdk/include/openxr ${HARVEST_TARGET}/xr_openxr_sdk/include/openxr
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/xr_openxr_sdk/lib ${HARVEST_TARGET}/xr_openxr_sdk/lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
ExternalProject_Add_Step(external_xr_openxr_sdk after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/xr_openxr_sdk/lib/openxr_loader.lib ${HARVEST_TARGET}/xr_openxr_sdk/lib/openxr_loader_d.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
endif()
|
@@ -1,44 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
if(WIN32)
|
||||
set(XVIDCORE_EXTRA_ARGS --host=${MINGW_HOST})
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(external_xvidcore
|
||||
URL ${XVIDCORE_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH SHA256=${XVIDCORE_HASH}
|
||||
PREFIX ${BUILD_DIR}/xvidcore
|
||||
CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/xvidcore/src/external_xvidcore/build/generic && ${CONFIGURE_COMMAND} --prefix=${LIBDIR}/xvidcore ${XVIDCORE_EXTRA_ARGS}
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/xvidcore/src/external_xvidcore/build/generic && make -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND ${CONFIGURE_ENV} &&
|
||||
${CMAKE_COMMAND} -E remove ${LIBDIR}/xvidcore/lib/* && # clean because re-installing fails otherwise
|
||||
cd ${BUILD_DIR}/xvidcore/src/external_xvidcore/build/generic && make install
|
||||
INSTALL_DIR ${LIBDIR}/xvidcore
|
||||
)
|
||||
|
||||
ExternalProject_Add_Step(external_xvidcore after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E rename ${LIBDIR}/xvidcore/lib/xvidcore.a ${LIBDIR}/xvidcore/lib/libxvidcore.a || true
|
||||
COMMAND ${CMAKE_COMMAND} -E remove ${LIBDIR}/xvidcore/lib/xvidcore.dll.a
|
||||
DEPENDEES install
|
||||
)
|
||||
|
||||
if(MSVC)
|
||||
set_target_properties(external_xvidcore PROPERTIES FOLDER Mingw)
|
||||
endif()
|
@@ -1,34 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
set(YAMLCPP_EXTRA_ARGS
|
||||
-DBUILD_GMOCK=OFF
|
||||
-DYAML_CPP_BUILD_TESTS=OFF
|
||||
-DYAML_CPP_BUILD_TOOLS=OFF
|
||||
-DYAML_CPP_BUILD_CONTRIB=OFF
|
||||
-DYAML_MSVC_SHARED_RT=ON
|
||||
)
|
||||
|
||||
ExternalProject_Add(external_yamlcpp
|
||||
URL ${YAMLCPP_URI}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL_HASH MD5=${YAMLCPP_HASH}
|
||||
PREFIX ${BUILD_DIR}/yamlcpp
|
||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/yamlcpp ${DEFAULT_CMAKE_FLAGS} ${YAMLCPP_EXTRA_ARGS}
|
||||
INSTALL_DIR ${LIBDIR}/yamlcpp
|
||||
)
|
@@ -1,47 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
ExternalProject_Add(external_zlib
|
||||
URL ${ZLIB_URI}
|
||||
URL_HASH MD5=${ZLIB_HASH}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
PREFIX ${BUILD_DIR}/zlib
|
||||
CMAKE_ARGS -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_INSTALL_PREFIX=${LIBDIR}/zlib ${DEFAULT_CMAKE_FLAGS}
|
||||
INSTALL_DIR ${LIBDIR}/zlib
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_zlib after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/zlib/lib/zlibstatic${LIBEXT} ${HARVEST_TARGET}/zlib/lib/libz_st${LIBEXT}
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/zlib/include/ ${HARVEST_TARGET}/zlib/include/
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
if(BUILD_MODE STREQUAL Debug)
|
||||
ExternalProject_Add_Step(external_zlib after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/zlib/lib/zlibstaticd${LIBEXT} ${HARVEST_TARGET}/zlib/lib/libz_st_d${LIBEXT}
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
else()
|
||||
ExternalProject_Add_Step(external_zlib after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/zlib/lib/libz.a ${LIBDIR}/zlib/lib/libz_pic.a
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
@@ -1,39 +0,0 @@
|
||||
# ***** BEGIN GPL LICENSE BLOCK *****
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program 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 General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ***** END GPL LICENSE BLOCK *****
|
||||
|
||||
ExternalProject_Add(external_zlib_mingw
|
||||
URL ${ZLIB_URI}
|
||||
URL_HASH MD5=${ZLIB_HASH}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
PREFIX ${BUILD_DIR}/zlib_mingw
|
||||
CONFIGURE_COMMAND echo .
|
||||
BUILD_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/zlib_mingw/src/external_zlib_mingw/ && make -f win32/makefile.gcc -j${MAKE_THREADS}
|
||||
INSTALL_COMMAND echo .
|
||||
INSTALL_DIR ${LIBDIR}/zlib_mingw
|
||||
)
|
||||
|
||||
if(BUILD_MODE STREQUAL Release)
|
||||
ExternalProject_Add_Step(external_zlib_mingw after_install
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${BUILD_DIR}/zlib_mingw/src/external_zlib_mingw/libz.a ${LIBDIR}/zlib/lib/z.lib
|
||||
DEPENDEES install
|
||||
)
|
||||
endif()
|
||||
|
||||
if(MSVC)
|
||||
set_target_properties(external_zlib_mingw PROPERTIES FOLDER Mingw)
|
||||
endif()
|
@@ -1,100 +0,0 @@
|
||||
strict graph {
|
||||
graph[autosize = false, size = "25.7,8.3!", resolution = 300, overlap = false, splines = false, outputorder=edgesfirst ];
|
||||
node [style=filled fillcolor=white];
|
||||
external_alembic -- external_boost;
|
||||
external_alembic -- external_zlib;
|
||||
external_alembic -- external_openexr;
|
||||
external_blosc -- external_zlib;
|
||||
external_blosc -- external_pthreads;
|
||||
external_boost -- Make_Python_Environment;
|
||||
external_clang -- ll;
|
||||
external_ffmpeg -- external_zlib;
|
||||
external_ffmpeg -- external_faad;
|
||||
external_ffmpeg -- external_openjpeg;
|
||||
external_ffmpeg -- external_xvidcore;
|
||||
external_ffmpeg -- external_x264;
|
||||
external_ffmpeg -- external_vpx;
|
||||
external_ffmpeg -- external_theora;
|
||||
external_ffmpeg -- external_vorbis;
|
||||
external_ffmpeg -- external_ogg;
|
||||
external_ffmpeg -- external_lame;
|
||||
external_ffmpeg -- external_zlib_mingw;
|
||||
external_numpy -- Make_Python_Environment;
|
||||
external_opencollada -- external_xml2;
|
||||
external_opencolorio -- external_boost;
|
||||
external_opencolorio -- external_tinyxml;
|
||||
external_opencolorio -- external_yamlcpp;
|
||||
external_openexr -- external_zlib;
|
||||
external_openimageio -- external_png;
|
||||
external_openimageio -- external_zlib;
|
||||
external_openimageio -- external_openexr;
|
||||
external_openimageio -- external_openexr;
|
||||
external_openimageio -- external_jpeg;
|
||||
external_openimageio -- external_boost;
|
||||
external_openimageio -- external_tiff;
|
||||
external_openimageio -- external_opencolorio;
|
||||
external_openimageio -- external_openjpeg;
|
||||
external_openimageio -- external_webp;
|
||||
external_openimageio -- external_opencolorio_extra;
|
||||
external_openmp -- external_clang;
|
||||
external_opensubdiv -- external_glew;
|
||||
external_opensubdiv -- external_glfw;
|
||||
external_opensubdiv -- external_clew;
|
||||
external_opensubdiv -- external_cuew;
|
||||
external_opensubdiv -- external_tbb;
|
||||
openvdb -- external_tbb;
|
||||
openvdb -- external_boost;
|
||||
openvdb -- external_openexr;
|
||||
openvdb -- external_openexr;
|
||||
openvdb -- external_zlib;
|
||||
openvdb -- external_blosc;
|
||||
external_osl -- external_boost;
|
||||
external_osl -- ll;
|
||||
external_osl -- external_clang;
|
||||
external_osl -- external_openexr;
|
||||
external_osl -- external_openexr;
|
||||
external_osl -- external_zlib;
|
||||
external_osl -- external_flexbison;
|
||||
external_osl -- external_openimageio;
|
||||
external_osl -- external_pugixml;
|
||||
external_png -- external_zlib;
|
||||
external_python_site_packages -- Make_Python_Environment;
|
||||
external_sndfile -- external_ogg;
|
||||
external_sndfile -- external_vorbis;
|
||||
external_sndfile -- external_flac;
|
||||
external_theora -- external_vorbis;
|
||||
external_theora -- external_ogg;
|
||||
external_tiff -- external_zlib;
|
||||
external_vorbis -- external_ogg;
|
||||
blender-- external_ffmpeg;
|
||||
blender-- external_alembic;
|
||||
blender-- external_openjpeg;
|
||||
blender-- external_opencolorio;
|
||||
blender-- external_openexr;
|
||||
blender-- external_opensubdiv;
|
||||
blender-- openvdb;
|
||||
blender-- external_osl;
|
||||
blender-- external_boost;
|
||||
blender-- external_jpeg;
|
||||
blender-- external_png;
|
||||
blender-- external_python;
|
||||
blender-- external_sndfile;
|
||||
blender-- external_iconv;
|
||||
blender-- external_fftw3;
|
||||
external_python-- external_python_site_packages;
|
||||
external_python_site_packages-- requests;
|
||||
external_python_site_packages-- idna;
|
||||
external_python_site_packages-- chardet;
|
||||
external_python_site_packages-- urllib3;
|
||||
external_python_site_packages-- certifi;
|
||||
external_python-- external_numpy;
|
||||
external_usd-- external_boost;
|
||||
external_usd-- external_tbb;
|
||||
blender-- external_opencollada;
|
||||
blender-- external_sdl;
|
||||
blender-- external_freetype;
|
||||
blender-- external_pthreads;
|
||||
blender-- external_zlib;
|
||||
blender-- external_openal;
|
||||
blender-- external_usd;
|
||||
}
|
File diff suppressed because it is too large
Load Diff
@@ -1,2 +0,0 @@
|
||||
# Files contains mixed line endings, patch needs to preserve them to apply.
|
||||
opencollada.diff binary
|
@@ -1,93 +0,0 @@
|
||||
diff -Naur src/blosc/CMakeLists.txt external_blosc/blosc/CMakeLists.txt
|
||||
--- src/blosc/CMakeLists.txt 2016-02-03 10:26:28 -0700
|
||||
+++ external_blosc/blosc/CMakeLists.txt 2017-03-03 09:03:31 -0700
|
||||
@@ -61,6 +61,8 @@
|
||||
set(SOURCES ${SOURCES} win32/pthread.c)
|
||||
else(NOT Threads_FOUND)
|
||||
set(LIBS ${LIBS} ${CMAKE_THREAD_LIBS_INIT})
|
||||
+ set(LIBS ${LIBS} ${PTHREAD_LIBS})
|
||||
+ include_directories( ${PTHREAD_INCLUDE_DIR} )
|
||||
endif(NOT Threads_FOUND)
|
||||
else(WIN32)
|
||||
find_package(Threads REQUIRED)
|
||||
diff -Naur src/CMakeLists.txt external_blosc/CMakeLists.txt
|
||||
--- src/CMakeLists.txt 2016-02-03 10:26:28 -0700
|
||||
+++ external_blosc/CMakeLists.txt 2017-03-03 09:03:31 -0700
|
||||
@@ -17,8 +17,8 @@
|
||||
# do not include support for the Snappy library
|
||||
# DEACTIVATE_ZLIB: default OFF
|
||||
# do not include support for the Zlib library
|
||||
-# PREFER_EXTERNAL_COMPLIBS: default ON
|
||||
-# when found, use the installed compression libs instead of included sources
|
||||
+# PREFER_EXTERNAL_ZLIB: default ON
|
||||
+# when found, use the installed zlib instead of included sources
|
||||
# TEST_INCLUDE_BENCH_SINGLE_1: default ON
|
||||
# add a test that runs the benchmark program passing "single" with 1 thread
|
||||
# as first parameter
|
||||
@@ -80,29 +80,23 @@
|
||||
"Do not include support for the SNAPPY library." OFF)
|
||||
option(DEACTIVATE_ZLIB
|
||||
"Do not include support for the ZLIB library." OFF)
|
||||
-option(PREFER_EXTERNAL_COMPLIBS
|
||||
- "When found, use the installed compression libs instead of included sources." ON)
|
||||
+option(PREFER_EXTERNAL_ZLIB
|
||||
+ "When found, use the installed zlib instead of included sources." ON)
|
||||
|
||||
set(CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake")
|
||||
|
||||
-if(NOT PREFER_EXTERNAL_COMPLIBS)
|
||||
+if(NOT PREFER_EXTERNAL_ZLIB)
|
||||
message(STATUS "Finding external libraries disabled. Using internal sources.")
|
||||
-endif(NOT PREFER_EXTERNAL_COMPLIBS)
|
||||
+endif(NOT PREFER_EXTERNAL_ZLIB)
|
||||
|
||||
|
||||
if(NOT DEACTIVATE_LZ4)
|
||||
- if(PREFER_EXTERNAL_COMPLIBS)
|
||||
- find_package(LZ4)
|
||||
- endif(PREFER_EXTERNAL_COMPLIBS)
|
||||
# HAVE_LZ4 will be set to true because even if the library is
|
||||
# not found, we will use the included sources for it
|
||||
set(HAVE_LZ4 TRUE)
|
||||
endif(NOT DEACTIVATE_LZ4)
|
||||
|
||||
if(NOT DEACTIVATE_SNAPPY)
|
||||
- if(PREFER_EXTERNAL_COMPLIBS)
|
||||
- find_package(Snappy)
|
||||
- endif(PREFER_EXTERNAL_COMPLIBS)
|
||||
# HAVE_SNAPPY will be set to true because even if the library is not found,
|
||||
# we will use the included sources for it
|
||||
set(HAVE_SNAPPY TRUE)
|
||||
@@ -110,13 +104,13 @@
|
||||
|
||||
if(NOT DEACTIVATE_ZLIB)
|
||||
# import the ZLIB_ROOT environment variable to help finding the zlib library
|
||||
- if(PREFER_EXTERNAL_COMPLIBS)
|
||||
+ if(PREFER_EXTERNAL_ZLIB)
|
||||
set(ZLIB_ROOT $ENV{ZLIB_ROOT})
|
||||
find_package( ZLIB )
|
||||
if (NOT ZLIB_FOUND )
|
||||
message(STATUS "No zlib found. Using internal sources.")
|
||||
endif (NOT ZLIB_FOUND )
|
||||
- endif(PREFER_EXTERNAL_COMPLIBS)
|
||||
+ endif(PREFER_EXTERNAL_ZLIB)
|
||||
# HAVE_ZLIB will be set to true because even if the library is not found,
|
||||
# we will use the included sources for it
|
||||
set(HAVE_ZLIB TRUE)
|
||||
diff -Naur external_blosc.orig/blosc/blosc.c external_blosc/blosc/blosc.c
|
||||
--- external_blosc.orig/blosc/blosc.c 2018-07-30 04:56:38 -0600
|
||||
+++ external_blosc/blosc/blosc.c 2018-08-11 15:27:26 -0600
|
||||
@@ -41,12 +41,7 @@
|
||||
#include <inttypes.h>
|
||||
#endif /* _WIN32 */
|
||||
|
||||
-#if defined(_WIN32)
|
||||
- #include "win32/pthread.h"
|
||||
- #include "win32/pthread.c"
|
||||
-#else
|
||||
- #include <pthread.h>
|
||||
-#endif
|
||||
+#include <pthread.h>
|
||||
|
||||
|
||||
/* Some useful units */
|
@@ -1,69 +0,0 @@
|
||||
# - Find BLOSC library
|
||||
# Find the native BLOSC includes and library
|
||||
# This module defines
|
||||
# BLOSC_INCLUDE_DIRS, where to find blosc.h, Set when
|
||||
# BLOSC is found.
|
||||
# BLOSC_LIBRARIES, libraries to link against to use BLOSC.
|
||||
# BLOSC_ROOT_DIR, The base directory to search for BLOSC.
|
||||
# This can also be an environment variable.
|
||||
# BLOSC_FOUND, If false, do not try to use BLOSC.
|
||||
#
|
||||
# also defined, but not for general use are
|
||||
# BLOSC_LIBRARY, where to find the BLOSC library.
|
||||
|
||||
#=============================================================================
|
||||
# Copyright 2016 Blender Foundation.
|
||||
#
|
||||
# Distributed under the OSI-approved BSD License (the "License");
|
||||
# see accompanying file Copyright.txt for details.
|
||||
#
|
||||
# This software is distributed WITHOUT ANY WARRANTY; without even the
|
||||
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
# See the License for more information.
|
||||
#=============================================================================
|
||||
|
||||
# If BLOSC_ROOT_DIR was defined in the environment, use it.
|
||||
IF(NOT BLOSC_ROOT_DIR AND NOT $ENV{BLOSC_ROOT_DIR} STREQUAL "")
|
||||
SET(BLOSC_ROOT_DIR $ENV{BLOSC_ROOT_DIR})
|
||||
ENDIF()
|
||||
|
||||
SET(_blosc_SEARCH_DIRS
|
||||
${BLOSC_ROOT_DIR}
|
||||
/opt/lib/blosc
|
||||
)
|
||||
|
||||
FIND_PATH(BLOSC_INCLUDE_DIR
|
||||
NAMES
|
||||
blosc.h
|
||||
HINTS
|
||||
${_blosc_SEARCH_DIRS}
|
||||
PATH_SUFFIXES
|
||||
include
|
||||
)
|
||||
|
||||
FIND_LIBRARY(BLOSC_LIBRARY
|
||||
NAMES
|
||||
blosc
|
||||
HINTS
|
||||
${_blosc_SEARCH_DIRS}
|
||||
PATH_SUFFIXES
|
||||
lib64 lib
|
||||
)
|
||||
|
||||
# handle the QUIETLY and REQUIRED arguments and set BLOSC_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(BLOSC DEFAULT_MSG
|
||||
BLOSC_LIBRARY BLOSC_INCLUDE_DIR)
|
||||
|
||||
IF(BLOSC_FOUND)
|
||||
SET(BLOSC_LIBRARIES ${BLOSC_LIBRARY})
|
||||
SET(BLOSC_INCLUDE_DIRS ${BLOSC_INCLUDE_DIR})
|
||||
ELSE()
|
||||
SET(BLOSC_FOUND FALSE)
|
||||
ENDIF()
|
||||
|
||||
MARK_AS_ADVANCED(
|
||||
BLOSC_INCLUDE_DIR
|
||||
BLOSC_LIBRARY
|
||||
)
|
@@ -1,69 +0,0 @@
|
||||
# - Find CPPUNIT library
|
||||
# Find the native CPPUNIT includes and library
|
||||
# This module defines
|
||||
# CPPUNIT_INCLUDE_DIRS, where to find cppunit.h, Set when
|
||||
# CPPUNIT is found.
|
||||
# CPPUNIT_LIBRARIES, libraries to link against to use CPPUNIT.
|
||||
# CPPUNIT_ROOT_DIR, The base directory to search for CPPUNIT.
|
||||
# This can also be an environment variable.
|
||||
# CPPUNIT_FOUND, If false, do not try to use CPPUNIT.
|
||||
#
|
||||
# also defined, but not for general use are
|
||||
# CPPUNIT_LIBRARY, where to find the CPPUNIT library.
|
||||
|
||||
#=============================================================================
|
||||
# Copyright 2016 Blender Foundation.
|
||||
#
|
||||
# Distributed under the OSI-approved BSD License (the "License");
|
||||
# see accompanying file Copyright.txt for details.
|
||||
#
|
||||
# This software is distributed WITHOUT ANY WARRANTY; without even the
|
||||
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
# See the License for more information.
|
||||
#=============================================================================
|
||||
|
||||
# If CPPUNIT_ROOT_DIR was defined in the environment, use it.
|
||||
IF(NOT CPPUNIT_ROOT_DIR AND NOT $ENV{CPPUNIT_ROOT_DIR} STREQUAL "")
|
||||
SET(CPPUNIT_ROOT_DIR $ENV{CPPUNIT_ROOT_DIR})
|
||||
ENDIF()
|
||||
|
||||
SET(_cppunit_SEARCH_DIRS
|
||||
${CPPUNIT_ROOT_DIR}
|
||||
/opt/lib/cppunit
|
||||
)
|
||||
|
||||
FIND_PATH(CPPUNIT_INCLUDE_DIR
|
||||
NAMES
|
||||
cppunit/Test.h
|
||||
HINTS
|
||||
${_cppunit_SEARCH_DIRS}
|
||||
PATH_SUFFIXES
|
||||
include
|
||||
)
|
||||
|
||||
FIND_LIBRARY(CPPUNIT_LIBRARY
|
||||
NAMES
|
||||
cppunit
|
||||
HINTS
|
||||
${_cppunit_SEARCH_DIRS}
|
||||
PATH_SUFFIXES
|
||||
lib64 lib
|
||||
)
|
||||
|
||||
# handle the QUIETLY and REQUIRED arguments and set CPPUNIT_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(CPPUNIT DEFAULT_MSG
|
||||
CPPUNIT_LIBRARY CPPUNIT_INCLUDE_DIR)
|
||||
|
||||
IF(CPPUNIT_FOUND)
|
||||
SET(CPPUNIT_LIBRARIES ${CPPUNIT_LIBRARY})
|
||||
SET(CPPUNIT_INCLUDE_DIRS ${CPPUNIT_INCLUDE_DIR})
|
||||
ELSE()
|
||||
SET(CPPUNIT_FOUND FALSE)
|
||||
ENDIF()
|
||||
|
||||
MARK_AS_ADVANCED(
|
||||
CPPUNIT_INCLUDE_DIR
|
||||
CPPUNIT_LIBRARY
|
||||
)
|
@@ -1,262 +0,0 @@
|
||||
# Module to find IlmBase
|
||||
#
|
||||
# This module will first look into the directories defined by the variables:
|
||||
# - ILMBASE_HOME, ILMBASE_VERSION, ILMBASE_LIB_AREA
|
||||
#
|
||||
# It also supports non-standard names for the library components.
|
||||
#
|
||||
# To use a custom IlmBase:
|
||||
# - Set the variable ILMBASE_CUSTOM to True
|
||||
# - Set the variable ILMBASE_CUSTOM_LIBRARIES to a list of the libraries to
|
||||
# use, e.g. "SpiImath SpiHalf SpiIlmThread SpiIex"
|
||||
# - Optionally set the variable ILMBASE_CUSTOM_INCLUDE_DIR to any
|
||||
# particularly weird place that the OpenEXR/*.h files may be found
|
||||
# - Optionally set the variable ILMBASE_CUSTOM_LIB_DIR to any
|
||||
# particularly weird place that the libraries files may be found
|
||||
#
|
||||
# This module defines the following variables:
|
||||
#
|
||||
# ILMBASE_INCLUDE_DIR - where to find half.h, IlmBaseConfig.h, etc.
|
||||
# ILMBASE_LIBRARIES - list of libraries to link against when using IlmBase.
|
||||
# ILMBASE_FOUND - True if IlmBase was found.
|
||||
|
||||
# Other standarnd issue macros
|
||||
include(FindPackageHandleStandardArgs)
|
||||
include(FindPackageMessage)
|
||||
include(SelectLibraryConfigurations)
|
||||
|
||||
|
||||
if(ILMBASE_USE_STATIC_LIBS)
|
||||
set(_ilmbase_ORIG_CMAKE_FIND_LIBRARY_SUFFIXES ${CMAKE_FIND_LIBRARY_SUFFIXES})
|
||||
if(WIN32)
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES .lib .a ${CMAKE_FIND_LIBRARY_SUFFIXES})
|
||||
else()
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES .a )
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# Macro to assemble a helper state variable
|
||||
macro(SET_STATE_VAR varname)
|
||||
set(tmp_ilmbaselibs ${ILMBASE_CUSTOM_LIBRARIES})
|
||||
separate_arguments(tmp_ilmbaselibs)
|
||||
set(tmp_lst
|
||||
${ILMBASE_CUSTOM} | ${tmp_ilmbaselibs} |
|
||||
${ILMBASE_HOME} | ${ILMBASE_VERSION} | ${ILMBASE_LIB_AREA}
|
||||
)
|
||||
set(${varname} "${tmp_lst}")
|
||||
unset(tmp_ilmbaselibs)
|
||||
unset(tmp_lst)
|
||||
endmacro()
|
||||
|
||||
# To enforce that find_* functions do not use inadvertently existing versions
|
||||
if(ILMBASE_CUSTOM)
|
||||
set(ILMBASE_FIND_OPTIONS "NO_DEFAULT_PATH")
|
||||
endif()
|
||||
|
||||
# Macro to search for an include directory
|
||||
macro(PREFIX_FIND_INCLUDE_DIR prefix includefile libpath_var)
|
||||
string(TOUPPER ${prefix}_INCLUDE_DIR tmp_varname)
|
||||
find_path(${tmp_varname} ${includefile}
|
||||
HINTS ${${libpath_var}}
|
||||
PATH_SUFFIXES include
|
||||
${ILMBASE_FIND_OPTIONS}
|
||||
)
|
||||
if(${tmp_varname})
|
||||
mark_as_advanced(${tmp_varname})
|
||||
endif()
|
||||
unset(tmp_varname)
|
||||
endmacro()
|
||||
|
||||
|
||||
# Macro to search for the given library and adds the cached
|
||||
# variable names to the specified list
|
||||
macro(PREFIX_FIND_LIB prefix libname libpath_var liblist_var cachelist_var)
|
||||
string(TOUPPER ${prefix}_${libname} tmp_prefix)
|
||||
# Handle new library names for OpenEXR 2.1 build via cmake
|
||||
string(REPLACE "." "_" _ILMBASE_VERSION ${ILMBASE_VERSION})
|
||||
string(SUBSTRING ${_ILMBASE_VERSION} 0 3 _ILMBASE_VERSION )
|
||||
|
||||
find_library(${tmp_prefix}_LIBRARY_RELEASE
|
||||
NAMES ${libname} ${libname}-${_ILMBASE_VERSION}
|
||||
HINTS ${${libpath_var}}
|
||||
PATH_SUFFIXES lib
|
||||
${ILMBASE_FIND_OPTIONS}
|
||||
)
|
||||
find_library(${tmp_prefix}_LIBRARY_DEBUG
|
||||
NAMES ${libname}d ${libname}_d ${libname}debug ${libname}_debug
|
||||
HINTS ${${libpath_var}}
|
||||
PATH_SUFFIXES lib
|
||||
${ILMBASE_FIND_OPTIONS}
|
||||
)
|
||||
# Properly define ${tmp_prefix}_LIBRARY (cached) and ${tmp_prefix}_LIBRARIES
|
||||
select_library_configurations(${tmp_prefix})
|
||||
list(APPEND ${liblist_var} ${tmp_prefix}_LIBRARIES)
|
||||
|
||||
# Add to the list of variables which should be reset
|
||||
list(APPEND ${cachelist_var}
|
||||
${tmp_prefix}_LIBRARY
|
||||
${tmp_prefix}_LIBRARY_RELEASE
|
||||
${tmp_prefix}_LIBRARY_DEBUG)
|
||||
mark_as_advanced(
|
||||
${tmp_prefix}_LIBRARY
|
||||
${tmp_prefix}_LIBRARY_RELEASE
|
||||
${tmp_prefix}_LIBRARY_DEBUG)
|
||||
unset(tmp_prefix)
|
||||
endmacro()
|
||||
|
||||
|
||||
# Encode the current state of the external variables into a string
|
||||
SET_STATE_VAR(ILMBASE_CURRENT_STATE)
|
||||
|
||||
# If the state has changed, clear the cached variables
|
||||
if(ILMBASE_CACHED_STATE AND
|
||||
NOT ILMBASE_CACHED_STATE STREQUAL ILMBASE_CURRENT_STATE)
|
||||
|
||||
foreach(libvar ${ILMBASE_CACHED_VARS})
|
||||
unset(${libvar} CACHE)
|
||||
endforeach()
|
||||
endif()
|
||||
|
||||
|
||||
# Generic search paths
|
||||
set(IlmBase_generic_include_paths
|
||||
${ILMBASE_CUSTOM_INCLUDE_DIR}
|
||||
/usr/include
|
||||
/usr/include/${CMAKE_LIBRARY_ARCHITECTURE}
|
||||
/usr/local/include
|
||||
/opt/local/include
|
||||
)
|
||||
set(IlmBase_generic_library_paths
|
||||
${ILMBASE_CUSTOM_LIB_DIR}
|
||||
/usr/lib
|
||||
/usr/lib/${CMAKE_LIBRARY_ARCHITECTURE}
|
||||
/usr/local/lib
|
||||
/usr/local/lib/${CMAKE_LIBRARY_ARCHITECTURE}
|
||||
/opt/local/lib
|
||||
)
|
||||
|
||||
# Search paths for the IlmBase files
|
||||
if(ILMBASE_HOME)
|
||||
if(ILMBASE_VERSION)
|
||||
set(IlmBase_include_paths
|
||||
${ILMBASE_HOME}/ilmbase-${ILMBASE_VERSION}/include
|
||||
${ILMBASE_HOME}/include/ilmbase-${ILMBASE_VERSION}
|
||||
)
|
||||
set(IlmBase_library_paths
|
||||
${ILMBASE_HOME}/ilmbase-${ILMBASE_VERSION}/lib
|
||||
${ILMBASE_HOME}/lib/ilmbase-${ILMBASE_VERSION}
|
||||
)
|
||||
endif()
|
||||
list(APPEND IlmBase_include_paths ${ILMBASE_HOME}/include)
|
||||
set(IlmBase_library_paths
|
||||
${ILMBASE_HOME}/lib
|
||||
${ILMBASE_HOME}/lib64
|
||||
${ILMBASE_LIB_AREA}
|
||||
${IlmBase_library_paths})
|
||||
endif()
|
||||
list(APPEND IlmBase_include_paths ${IlmBase_generic_include_paths})
|
||||
list(APPEND IlmBase_library_paths ${IlmBase_generic_library_paths})
|
||||
|
||||
# Locate the header files
|
||||
PREFIX_FIND_INCLUDE_DIR(IlmBase
|
||||
OpenEXR/IlmBaseConfig.h IlmBase_include_paths)
|
||||
|
||||
if(ILMBASE_INCLUDE_DIR)
|
||||
# Get the version from config file, if not already set.
|
||||
if(NOT ILMBASE_VERSION)
|
||||
FILE(STRINGS "${ILMBASE_INCLUDE_DIR}/OpenEXR/IlmBaseConfig.h" ILMBASE_BUILD_SPECIFICATION
|
||||
REGEX "^[ \t]*#define[ \t]+ILMBASE_VERSION_STRING[ \t]+\"[.0-9]+\".*$")
|
||||
|
||||
if(ILMBASE_BUILD_SPECIFICATION)
|
||||
if(NOT IlmBase_FIND_QUIETLY)
|
||||
message(STATUS "${ILMBASE_BUILD_SPECIFICATION}")
|
||||
endif()
|
||||
string(REGEX REPLACE ".*#define[ \t]+ILMBASE_VERSION_STRING[ \t]+\"([.0-9]+)\".*"
|
||||
"\\1" XYZ ${ILMBASE_BUILD_SPECIFICATION})
|
||||
set("ILMBASE_VERSION" ${XYZ} CACHE STRING "Version of ILMBase lib")
|
||||
else()
|
||||
# Old versions (before 2.0?) do not have any version string, just assuming 2.0 should be fine though.
|
||||
message(WARNING "Could not determine ILMBase library version, assuming 2.0.")
|
||||
set("ILMBASE_VERSION" "2.0" CACHE STRING "Version of ILMBase lib")
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
||||
if(ILMBASE_CUSTOM)
|
||||
if(NOT ILMBASE_CUSTOM_LIBRARIES)
|
||||
message(FATAL_ERROR "Custom IlmBase libraries requested but ILMBASE_CUSTOM_LIBRARIES is not set.")
|
||||
endif()
|
||||
set(IlmBase_Libraries ${ILMBASE_CUSTOM_LIBRARIES})
|
||||
separate_arguments(IlmBase_Libraries)
|
||||
else()
|
||||
# elseif(${ILMBASE_VERSION} VERSION_LESS "2.1")
|
||||
set(IlmBase_Libraries Half Iex Imath IlmThread)
|
||||
# else()
|
||||
# string(REGEX REPLACE "([0-9]+)[.]([0-9]+).*" "\\1_\\2" _ilmbase_libs_ver ${ILMBASE_VERSION})
|
||||
# set(IlmBase_Libraries Half Iex-${_ilmbase_libs_ver} Imath-${_ilmbase_libs_ver} IlmThread-${_ilmbase_libs_ver})
|
||||
endif()
|
||||
|
||||
|
||||
# Locate the IlmBase libraries
|
||||
set(IlmBase_libvars "")
|
||||
set(IlmBase_cachevars "")
|
||||
foreach(ilmbase_lib ${IlmBase_Libraries})
|
||||
PREFIX_FIND_LIB(IlmBase ${ilmbase_lib}
|
||||
IlmBase_library_paths IlmBase_libvars IlmBase_cachevars)
|
||||
endforeach()
|
||||
# Create the list of variables that might need to be cleared
|
||||
set(ILMBASE_CACHED_VARS
|
||||
ILMBASE_INCLUDE_DIR ${IlmBase_cachevars}
|
||||
CACHE INTERNAL "Variables set by FindIlmBase.cmake" FORCE)
|
||||
|
||||
# Store the current state so that variables might be cleared if required
|
||||
set(ILMBASE_CACHED_STATE ${ILMBASE_CURRENT_STATE}
|
||||
CACHE INTERNAL "State last seen by FindIlmBase.cmake" FORCE)
|
||||
|
||||
# Link with pthreads if required
|
||||
if(NOT WIN32 AND EXISTS ${ILMBASE_INCLUDE_DIR}/OpenEXR/IlmBaseConfig.h)
|
||||
file(STRINGS ${ILMBASE_INCLUDE_DIR}/OpenEXR/IlmBaseConfig.h
|
||||
ILMBASE_HAVE_PTHREAD
|
||||
REGEX "^[ \\t]*#define[ \\t]+HAVE_PTHREAD[ \\t]1[ \\t]*\$"
|
||||
)
|
||||
if(ILMBASE_HAVE_PTHREAD)
|
||||
find_package(Threads)
|
||||
if(CMAKE_USE_PTHREADS_INIT)
|
||||
set(ILMBASE_PTHREADS ${CMAKE_THREAD_LIBS_INIT})
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# Use the standard function to handle ILMBASE_FOUND
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(IlmBase DEFAULT_MSG
|
||||
ILMBASE_INCLUDE_DIR ${IlmBase_libvars})
|
||||
|
||||
if(ILMBASE_FOUND)
|
||||
set(ILMBASE_LIBRARIES "")
|
||||
foreach(tmplib ${IlmBase_libvars})
|
||||
list(APPEND ILMBASE_LIBRARIES ${${tmplib}})
|
||||
endforeach()
|
||||
list(APPEND ILMBASE_LIBRARIES ${ILMBASE_PTHREADS})
|
||||
if(NOT IlmBase_FIND_QUIETLY)
|
||||
FIND_PACKAGE_MESSAGE(ILMBASE
|
||||
"Found IlmBase: ${ILMBASE_LIBRARIES}"
|
||||
"[${ILMBASE_INCLUDE_DIR}][${ILMBASE_LIBRARIES}][${ILMBASE_CURRENT_STATE}]"
|
||||
)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# Restore the original find library ordering
|
||||
if(ILMBASE_USE_STATIC_LIBS )
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES ${_ilmbase_ORIG_CMAKE_FIND_LIBRARY_SUFFIXES})
|
||||
endif()
|
||||
|
||||
# Unset the helper variables to avoid pollution
|
||||
unset(ILMBASE_CURRENT_STATE)
|
||||
unset(IlmBase_include_paths)
|
||||
unset(IlmBase_library_paths)
|
||||
unset(IlmBase_generic_include_paths)
|
||||
unset(IlmBase_generic_library_paths)
|
||||
unset(IlmBase_libvars)
|
||||
unset(IlmBase_cachevars)
|
||||
unset(ILMBASE_PTHREADS)
|
@@ -1,69 +0,0 @@
|
||||
# - Find LOGC4PLUS library
|
||||
# Find the native LOGC4PLUS includes and library
|
||||
# This module defines
|
||||
# LOGC4PLUS_INCLUDE_DIRS, where to find logc4plus.h, Set when
|
||||
# LOGC4PLUS is found.
|
||||
# LOGC4PLUS_LIBRARIES, libraries to link against to use LOGC4PLUS.
|
||||
# LOGC4PLUS_ROOT_DIR, The base directory to search for LOGC4PLUS.
|
||||
# This can also be an environment variable.
|
||||
# LOGC4PLUS_FOUND, If false, do not try to use LOGC4PLUS.
|
||||
#
|
||||
# also defined, but not for general use are
|
||||
# LOGC4PLUS_LIBRARY, where to find the LOGC4PLUS library.
|
||||
|
||||
#=============================================================================
|
||||
# Copyright 2016 Blender Foundation.
|
||||
#
|
||||
# Distributed under the OSI-approved BSD License (the "License");
|
||||
# see accompanying file Copyright.txt for details.
|
||||
#
|
||||
# This software is distributed WITHOUT ANY WARRANTY; without even the
|
||||
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
# See the License for more information.
|
||||
#=============================================================================
|
||||
|
||||
# If LOGC4PLUS_ROOT_DIR was defined in the environment, use it.
|
||||
IF(NOT LOGC4PLUS_ROOT_DIR AND NOT $ENV{LOGC4PLUS_ROOT_DIR} STREQUAL "")
|
||||
SET(LOGC4PLUS_ROOT_DIR $ENV{LOGC4PLUS_ROOT_DIR})
|
||||
ENDIF()
|
||||
|
||||
SET(_logc4plus_SEARCH_DIRS
|
||||
${LOGC4PLUS_ROOT_DIR}
|
||||
/opt/lib/logc4plus
|
||||
)
|
||||
|
||||
FIND_PATH(LOGC4PLUS_INCLUDE_DIR
|
||||
NAMES
|
||||
logc4plus.h
|
||||
HINTS
|
||||
${_logc4plus_SEARCH_DIRS}
|
||||
PATH_SUFFIXES
|
||||
include
|
||||
)
|
||||
|
||||
FIND_LIBRARY(LOGC4PLUS_LIBRARY
|
||||
NAMES
|
||||
logc4plus
|
||||
HINTS
|
||||
${_logc4plus_SEARCH_DIRS}
|
||||
PATH_SUFFIXES
|
||||
lib64 lib
|
||||
)
|
||||
|
||||
# handle the QUIETLY and REQUIRED arguments and set LOGC4PLUS_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(LOGC4PLUS DEFAULT_MSG
|
||||
LOGC4PLUS_LIBRARY LOGC4PLUS_INCLUDE_DIR)
|
||||
|
||||
IF(LOGC4PLUS_FOUND)
|
||||
SET(LOGC4PLUS_LIBRARIES ${LOGC4PLUS_LIBRARY})
|
||||
SET(LOGC4PLUS_INCLUDE_DIRS ${LOGC4PLUS_INCLUDE_DIR})
|
||||
ELSE()
|
||||
SET(LOGC4PLUS_LOGC4PLUS_FOUND FALSE)
|
||||
ENDIF()
|
||||
|
||||
MARK_AS_ADVANCED(
|
||||
LOGC4PLUS_INCLUDE_DIR
|
||||
LOGC4PLUS_LIBRARY
|
||||
)
|
@@ -1,244 +0,0 @@
|
||||
# Module to find OpenEXR.
|
||||
#
|
||||
# This module will first look into the directories defined by the variables:
|
||||
# - OPENEXR_HOME, OPENEXR_VERSION, OPENEXR_LIB_AREA
|
||||
#
|
||||
# It also supports non-standard names for the library components.
|
||||
#
|
||||
# To use a custom OpenEXR
|
||||
# - Set the variable OPENEXR_CUSTOM to True
|
||||
# - Set the variable OPENEXR_CUSTOM_LIBRARY to the name of the library to
|
||||
# use, e.g. "SpiIlmImf"
|
||||
# - Optionally set the variable OPENEXR_CUSTOM_INCLUDE_DIR to any
|
||||
# particularly weird place that the OpenEXR/*.h files may be found
|
||||
# - Optionally set the variable OPENEXR_CUSTOM_LIB_DIR to any
|
||||
# particularly weird place that the libraries files may be found
|
||||
#
|
||||
# This module defines the following variables:
|
||||
#
|
||||
# OPENEXR_INCLUDE_DIR - where to find ImfRgbaFile.h, OpenEXRConfig, etc.
|
||||
# OPENEXR_LIBRARIES - list of libraries to link against when using OpenEXR.
|
||||
# This list does NOT include the IlmBase libraries.
|
||||
# These are defined by the FindIlmBase module.
|
||||
# OPENEXR_FOUND - True if OpenEXR was found.
|
||||
|
||||
# Other standarnd issue macros
|
||||
include(SelectLibraryConfigurations)
|
||||
include(FindPackageHandleStandardArgs)
|
||||
include(FindPackageMessage)
|
||||
|
||||
if(OPENEXR_USE_STATIC_LIBS)
|
||||
set(_openexr_ORIG_CMAKE_FIND_LIBRARY_SUFFIXES ${CMAKE_FIND_LIBRARY_SUFFIXES})
|
||||
if(WIN32)
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES .lib .a ${CMAKE_FIND_LIBRARY_SUFFIXES})
|
||||
else()
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES .a )
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# Macro to assemble a helper state variable
|
||||
macro(SET_STATE_VAR varname)
|
||||
set(tmp_lst
|
||||
${OPENEXR_CUSTOM} | ${OPENEXR_CUSTOM_LIBRARY} |
|
||||
${OPENEXR_HOME} | ${OPENEXR_VERSION} | ${OPENEXR_LIB_AREA}
|
||||
)
|
||||
set(${varname} "${tmp_lst}")
|
||||
unset(tmp_lst)
|
||||
endmacro()
|
||||
|
||||
# To enforce that find_* functions do not use inadvertently existing versions
|
||||
if(OPENEXR_CUSTOM)
|
||||
set(OPENEXR_FIND_OPTIONS "NO_DEFAULT_PATH")
|
||||
endif()
|
||||
|
||||
# Macro to search for an include directory
|
||||
macro(PREFIX_FIND_INCLUDE_DIR prefix includefile libpath_var)
|
||||
string(TOUPPER ${prefix}_INCLUDE_DIR tmp_varname)
|
||||
find_path(${tmp_varname} ${includefile}
|
||||
HINTS ${${libpath_var}}
|
||||
PATH_SUFFIXES include
|
||||
${OPENEXR_FIND_OPTIONS}
|
||||
)
|
||||
if(${tmp_varname})
|
||||
mark_as_advanced(${tmp_varname})
|
||||
endif()
|
||||
unset(tmp_varname)
|
||||
endmacro()
|
||||
|
||||
|
||||
# Macro to search for the given library and adds the cached
|
||||
# variable names to the specified list
|
||||
macro(PREFIX_FIND_LIB prefix libname libpath_var liblist_var cachelist_var)
|
||||
string(TOUPPER ${prefix}_${libname} tmp_prefix)
|
||||
# Handle new library names for OpenEXR 2.1 build via cmake
|
||||
string(REPLACE "." "_" _ILMBASE_VERSION ${ILMBASE_VERSION})
|
||||
string(SUBSTRING ${_ILMBASE_VERSION} 0 3 _ILMBASE_VERSION )
|
||||
find_library(${tmp_prefix}_LIBRARY_RELEASE
|
||||
NAMES ${libname} ${libname}-${_ILMBASE_VERSION}
|
||||
HINTS ${${libpath_var}}
|
||||
PATH_SUFFIXES lib
|
||||
${OPENEXR_FIND_OPTIONS}
|
||||
)
|
||||
find_library(${tmp_prefix}_LIBRARY_DEBUG
|
||||
NAMES ${libname}d ${libname}_d ${libname}debug ${libname}_debug
|
||||
HINTS ${${libpath_var}}
|
||||
PATH_SUFFIXES lib
|
||||
${OPENEXR_FIND_OPTIONS}
|
||||
)
|
||||
# Properly define ${tmp_prefix}_LIBRARY (cached) and ${tmp_prefix}_LIBRARIES
|
||||
select_library_configurations(${tmp_prefix})
|
||||
list(APPEND ${liblist_var} ${tmp_prefix}_LIBRARIES)
|
||||
|
||||
# Add to the list of variables which should be reset
|
||||
list(APPEND ${cachelist_var}
|
||||
${tmp_prefix}_LIBRARY
|
||||
${tmp_prefix}_LIBRARY_RELEASE
|
||||
${tmp_prefix}_LIBRARY_DEBUG)
|
||||
mark_as_advanced(
|
||||
${tmp_prefix}_LIBRARY
|
||||
${tmp_prefix}_LIBRARY_RELEASE
|
||||
${tmp_prefix}_LIBRARY_DEBUG)
|
||||
unset(tmp_prefix)
|
||||
endmacro()
|
||||
|
||||
|
||||
# Encode the current state of the external variables into a string
|
||||
SET_STATE_VAR(OPENEXR_CURRENT_STATE)
|
||||
|
||||
# If the state has changed, clear the cached variables
|
||||
if(OPENEXR_CACHED_STATE AND
|
||||
NOT OPENEXR_CACHED_STATE STREQUAL OPENEXR_CURRENT_STATE)
|
||||
foreach(libvar ${OPENEXR_CACHED_VARS})
|
||||
unset(${libvar} CACHE)
|
||||
endforeach()
|
||||
endif()
|
||||
|
||||
# Generic search paths
|
||||
set(OpenEXR_generic_include_paths
|
||||
${OPENEXR_CUSTOM_INCLUDE_DIR}
|
||||
/usr/include
|
||||
/usr/include/${CMAKE_LIBRARY_ARCHITECTURE}
|
||||
/usr/local/include
|
||||
/opt/local/include
|
||||
)
|
||||
set(OpenEXR_generic_library_paths
|
||||
${OPENEXR_CUSTOM_LIB_DIR}
|
||||
/usr/lib
|
||||
/usr/lib/${CMAKE_LIBRARY_ARCHITECTURE}
|
||||
/usr/local/lib
|
||||
/usr/local/lib/${CMAKE_LIBRARY_ARCHITECTURE}
|
||||
/opt/local/lib
|
||||
)
|
||||
|
||||
# Search paths for the OpenEXR files
|
||||
if(OPENEXR_HOME)
|
||||
set(OpenEXR_library_paths
|
||||
${OPENEXR_HOME}/lib
|
||||
${OPENEXR_HOME}/lib64)
|
||||
if(OPENEXR_VERSION)
|
||||
set(OpenEXR_include_paths
|
||||
${OPENEXR_HOME}/openexr-${OPENEXR_VERSION}/include
|
||||
${OPENEXR_HOME}/include/openexr-${OPENEXR_VERSION})
|
||||
list(APPEND OpenEXR_library_paths
|
||||
${OPENEXR_HOME}/openexr-${OPENEXR_VERSION}/lib
|
||||
${OPENEXR_HOME}/lib/openexr-${OPENEXR_VERSION})
|
||||
endif()
|
||||
list(APPEND OpenEXR_include_paths ${OPENEXR_HOME}/include)
|
||||
if(OPENEXR_LIB_AREA)
|
||||
list(INSERT OpenEXR_library_paths 2 ${OPENEXR_LIB_AREA})
|
||||
endif()
|
||||
endif()
|
||||
if(ILMBASE_HOME AND OPENEXR_VERSION)
|
||||
list(APPEND OpenEXR_include_paths
|
||||
${ILMBASE_HOME}/include/openexr-${OPENEXR_VERSION})
|
||||
endif()
|
||||
list(APPEND OpenEXR_include_paths ${OpenEXR_generic_include_paths})
|
||||
list(APPEND OpenEXR_library_paths ${OpenEXR_generic_library_paths})
|
||||
|
||||
# Locate the header files
|
||||
PREFIX_FIND_INCLUDE_DIR(OpenEXR
|
||||
OpenEXR/ImfArray.h OpenEXR_include_paths)
|
||||
|
||||
if(OPENEXR_INCLUDE_DIR)
|
||||
# Get the version from config file, if not already set.
|
||||
if(NOT OPENEXR_VERSION)
|
||||
FILE(STRINGS "${OPENEXR_INCLUDE_DIR}/OpenEXR/OpenEXRConfig.h" OPENEXR_BUILD_SPECIFICATION
|
||||
REGEX "^[ \t]*#define[ \t]+OPENEXR_VERSION_STRING[ \t]+\"[.0-9]+\".*$")
|
||||
|
||||
if(OPENEXR_BUILD_SPECIFICATION)
|
||||
if(NOT OpenEXR_FIND_QUIETLY)
|
||||
message(STATUS "${OPENEXR_BUILD_SPECIFICATION}")
|
||||
endif()
|
||||
string(REGEX REPLACE ".*#define[ \t]+OPENEXR_VERSION_STRING[ \t]+\"([.0-9]+)\".*"
|
||||
"\\1" XYZ ${OPENEXR_BUILD_SPECIFICATION})
|
||||
set("OPENEXR_VERSION" ${XYZ} CACHE STRING "Version of OpenEXR lib")
|
||||
else()
|
||||
# Old versions (before 2.0?) do not have any version string, just assuming 2.0 should be fine though.
|
||||
message(WARNING "Could not determine ILMBase library version, assuming 2.0.")
|
||||
set("OPENEXR_VERSION" "2.0" CACHE STRING "Version of OpenEXR lib")
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(OPENEXR_CUSTOM)
|
||||
if(NOT OPENEXR_CUSTOM_LIBRARY)
|
||||
message(FATAL_ERROR "Custom OpenEXR library requested but OPENEXR_CUSTOM_LIBRARY is not set.")
|
||||
endif()
|
||||
set(OpenEXR_Library ${OPENEXR_CUSTOM_LIBRARY})
|
||||
else()
|
||||
# elseif(${OPENEXR_VERSION} VERSION_LESS "2.1")
|
||||
set(OpenEXR_Library IlmImf)
|
||||
# else()
|
||||
# string(REGEX REPLACE "([0-9]+)[.]([0-9]+).*" "\\1_\\2" _openexr_libs_ver ${OPENEXR_VERSION})
|
||||
# set(OpenEXR_Library IlmImf-${_openexr_libs_ver})
|
||||
endif()
|
||||
|
||||
# Locate the OpenEXR library
|
||||
set(OpenEXR_libvars "")
|
||||
set(OpenEXR_cachevars "")
|
||||
PREFIX_FIND_LIB(OpenEXR ${OpenEXR_Library}
|
||||
OpenEXR_library_paths OpenEXR_libvars OpenEXR_cachevars)
|
||||
|
||||
# Create the list of variables that might need to be cleared
|
||||
set(OPENEXR_CACHED_VARS
|
||||
OPENEXR_INCLUDE_DIR ${OpenEXR_cachevars}
|
||||
CACHE INTERNAL "Variables set by FindOpenEXR.cmake" FORCE)
|
||||
|
||||
# Store the current state so that variables might be cleared if required
|
||||
set(OPENEXR_CACHED_STATE ${OPENEXR_CURRENT_STATE}
|
||||
CACHE INTERNAL "State last seen by FindOpenEXR.cmake" FORCE)
|
||||
|
||||
# Always link explicitly with zlib
|
||||
set(OPENEXR_ZLIB ${ZLIB_LIBRARIES})
|
||||
|
||||
# Use the standard function to handle OPENEXR_FOUND
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OpenEXR DEFAULT_MSG
|
||||
OPENEXR_INCLUDE_DIR ${OpenEXR_libvars})
|
||||
|
||||
if(OPENEXR_FOUND)
|
||||
set(OPENEXR_LIBRARIES "")
|
||||
foreach(tmplib ${OpenEXR_libvars})
|
||||
list(APPEND OPENEXR_LIBRARIES ${${tmplib}})
|
||||
endforeach()
|
||||
list(APPEND OPENEXR_LIBRARIES ${ZLIB_LIBRARIES})
|
||||
if(NOT OpenEXR_FIND_QUIETLY)
|
||||
FIND_PACKAGE_MESSAGE(OPENEXR
|
||||
"Found OpenEXR: ${OPENEXR_LIBRARIES}"
|
||||
"[${OPENEXR_INCLUDE_DIR}][${OPENEXR_LIBRARIES}][${OPENEXR_CURRENT_STATE}]"
|
||||
)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# Restore the original find library ordering
|
||||
if(OPENEXR_USE_STATIC_LIBS )
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES ${_openexr_ORIG_CMAKE_FIND_LIBRARY_SUFFIXES})
|
||||
endif()
|
||||
|
||||
# Unset the helper variables to avoid pollution
|
||||
unset(OPENEXR_CURRENT_STATE)
|
||||
unset(OpenEXR_include_paths)
|
||||
unset(OpenEXR_library_paths)
|
||||
unset(OpenEXR_generic_include_paths)
|
||||
unset(OpenEXR_generic_library_paths)
|
||||
unset(OpenEXR_libvars)
|
||||
unset(OpenEXR_cachevars)
|
@@ -1,69 +0,0 @@
|
||||
# - Find TBB library
|
||||
# Find the native TBB includes and library
|
||||
# This module defines
|
||||
# TBB_INCLUDE_DIRS, where to find tbb.h, Set when
|
||||
# TBB is found.
|
||||
# TBB_LIBRARIES, libraries to link against to use TBB.
|
||||
# TBB_ROOT_DIR, The base directory to search for TBB.
|
||||
# This can also be an environment variable.
|
||||
# TBB_FOUND, If false, do not try to use TBB.
|
||||
#
|
||||
# also defined, but not for general use are
|
||||
# TBB_LIBRARY, where to find the TBB library.
|
||||
|
||||
#=============================================================================
|
||||
# Copyright 2016 Blender Foundation.
|
||||
#
|
||||
# Distributed under the OSI-approved BSD License (the "License");
|
||||
# see accompanying file Copyright.txt for details.
|
||||
#
|
||||
# This software is distributed WITHOUT ANY WARRANTY; without even the
|
||||
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
# See the License for more information.
|
||||
#=============================================================================
|
||||
|
||||
# If TBB_ROOT_DIR was defined in the environment, use it.
|
||||
IF(NOT TBB_ROOT_DIR AND NOT $ENV{TBB_ROOT_DIR} STREQUAL "")
|
||||
SET(TBB_ROOT_DIR $ENV{TBB_ROOT_DIR})
|
||||
ENDIF()
|
||||
|
||||
SET(_tbb_SEARCH_DIRS
|
||||
${TBB_ROOT_DIR}
|
||||
/opt/lib/tbb
|
||||
)
|
||||
|
||||
FIND_PATH(TBB_INCLUDE_DIR
|
||||
NAMES
|
||||
tbb/tbb.h
|
||||
HINTS
|
||||
${_tbb_SEARCH_DIRS}
|
||||
PATH_SUFFIXES
|
||||
include
|
||||
)
|
||||
|
||||
FIND_LIBRARY(TBB_LIBRARY
|
||||
NAMES
|
||||
tbb
|
||||
HINTS
|
||||
${_tbb_SEARCH_DIRS}
|
||||
PATH_SUFFIXES
|
||||
lib64 lib
|
||||
)
|
||||
|
||||
# handle the QUIETLY and REQUIRED arguments and set TBB_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(TBB DEFAULT_MSG
|
||||
TBB_LIBRARY TBB_INCLUDE_DIR)
|
||||
|
||||
IF(TBB_FOUND)
|
||||
SET(TBB_LIBRARIES ${TBB_LIBRARY})
|
||||
SET(TBB_INCLUDE_DIRS ${TBB_INCLUDE_DIR})
|
||||
ELSE()
|
||||
SET(TBB_TBB_FOUND FALSE)
|
||||
ENDIF()
|
||||
|
||||
MARK_AS_ADVANCED(
|
||||
TBB_INCLUDE_DIR
|
||||
TBB_LIBRARY
|
||||
)
|
@@ -1,81 +0,0 @@
|
||||
# select_library_configurations( basename )
|
||||
#
|
||||
# This macro takes a library base name as an argument, and will choose good
|
||||
# values for basename_LIBRARY, basename_LIBRARIES, basename_LIBRARY_DEBUG, and
|
||||
# basename_LIBRARY_RELEASE depending on what has been found and set. If only
|
||||
# basename_LIBRARY_RELEASE is defined, basename_LIBRARY, basename_LIBRARY_DEBUG,
|
||||
# and basename_LIBRARY_RELEASE will be set to the release value. If only
|
||||
# basename_LIBRARY_DEBUG is defined, then basename_LIBRARY,
|
||||
# basename_LIBRARY_DEBUG and basename_LIBRARY_RELEASE will take the debug value.
|
||||
#
|
||||
# If the generator supports configuration types, then basename_LIBRARY and
|
||||
# basename_LIBRARIES will be set with debug and optimized flags specifying the
|
||||
# library to be used for the given configuration. If no build type has been set
|
||||
# or the generator in use does not support configuration types, then
|
||||
# basename_LIBRARY and basename_LIBRARIES will take only the release values.
|
||||
|
||||
#=============================================================================
|
||||
# Copyright 2009 Kitware, Inc.
|
||||
# Copyright 2009 Will Dicharry <wdicharry@stellarscience.com>
|
||||
# Copyright 2005-2009 Kitware, Inc.
|
||||
#
|
||||
# Distributed under the OSI-approved BSD License (the "License");
|
||||
# see accompanying file Copyright.txt for details.
|
||||
#
|
||||
# This software is distributed WITHOUT ANY WARRANTY; without even the
|
||||
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
# See the License for more information.
|
||||
#=============================================================================
|
||||
# (To distribute this file outside of CMake, substitute the full
|
||||
# License text for the above reference.)
|
||||
|
||||
# This macro was adapted from the FindQt4 CMake module and is maintained by Will
|
||||
# Dicharry <wdicharry@stellarscience.com>.
|
||||
|
||||
# Utility macro to check if one variable exists while another doesn't, and set
|
||||
# one that doesn't exist to the one that exists.
|
||||
macro( _set_library_name basename GOOD BAD )
|
||||
if( ${basename}_LIBRARY_${GOOD} AND NOT ${basename}_LIBRARY_${BAD} )
|
||||
set( ${basename}_LIBRARY_${BAD} ${${basename}_LIBRARY_${GOOD}} )
|
||||
set( ${basename}_LIBRARY ${${basename}_LIBRARY_${GOOD}} )
|
||||
set( ${basename}_LIBRARIES ${${basename}_LIBRARY_${GOOD}} )
|
||||
endif( ${basename}_LIBRARY_${GOOD} AND NOT ${basename}_LIBRARY_${BAD} )
|
||||
endmacro( _set_library_name )
|
||||
|
||||
macro( select_library_configurations basename )
|
||||
# if only the release version was found, set the debug to be the release
|
||||
# version.
|
||||
_set_library_name( ${basename} RELEASE DEBUG )
|
||||
# if only the debug version was found, set the release value to be the
|
||||
# debug value.
|
||||
_set_library_name( ${basename} DEBUG RELEASE )
|
||||
if( ${basename}_LIBRARY_DEBUG AND ${basename}_LIBRARY_RELEASE )
|
||||
# if the generator supports configuration types or CMAKE_BUILD_TYPE
|
||||
# is set, then set optimized and debug options.
|
||||
if( CMAKE_CONFIGURATION_TYPES OR CMAKE_BUILD_TYPE )
|
||||
set( ${basename}_LIBRARY
|
||||
optimized ${${basename}_LIBRARY_RELEASE}
|
||||
debug ${${basename}_LIBRARY_DEBUG} )
|
||||
set( ${basename}_LIBRARIES
|
||||
optimized ${${basename}_LIBRARY_RELEASE}
|
||||
debug ${${basename}_LIBRARY_DEBUG} )
|
||||
else( CMAKE_CONFIGURATION_TYPES OR CMAKE_BUILD_TYPE )
|
||||
# If there are no configuration types or build type, just use
|
||||
# the release version
|
||||
set( ${basename}_LIBRARY ${${basename}_LIBRARY_RELEASE} )
|
||||
set( ${basename}_LIBRARIES ${${basename}_LIBRARY_RELEASE} )
|
||||
endif( CMAKE_CONFIGURATION_TYPES OR CMAKE_BUILD_TYPE )
|
||||
endif( ${basename}_LIBRARY_DEBUG AND ${basename}_LIBRARY_RELEASE )
|
||||
|
||||
set( ${basename}_LIBRARY ${${basename}_LIBRARY} CACHE FILEPATH
|
||||
"The ${basename} library" )
|
||||
|
||||
if( ${basename}_LIBRARY )
|
||||
set( ${basename}_FOUND TRUE )
|
||||
endif( ${basename}_LIBRARY )
|
||||
|
||||
mark_as_advanced( ${basename}_LIBRARY
|
||||
${basename}_LIBRARY_RELEASE
|
||||
${basename}_LIBRARY_DEBUG
|
||||
)
|
||||
endmacro( select_library_configurations )
|
@@ -1,2 +0,0 @@
|
||||
cmake_minimum_required (VERSION 2.4)
|
||||
add_subdirectory(build/cmake)
|
@@ -1,20 +0,0 @@
|
||||
cmake_minimum_required(VERSION 2.8)
|
||||
project(hidapi)
|
||||
|
||||
set(SRC_FILES
|
||||
windows/hid.c
|
||||
)
|
||||
|
||||
set(HEADER_FILES
|
||||
hidapi/hidapi.h
|
||||
)
|
||||
include_directories(hidapi)
|
||||
add_definitions(-DHID_API_STATIC)
|
||||
add_library(hidapi STATIC ${SRC_FILES} ${HEADER_FILES})
|
||||
|
||||
install(TARGETS hidapi DESTINATION lib)
|
||||
|
||||
INSTALL(FILES hidapi/hidapi.h
|
||||
DESTINATION "include"
|
||||
)
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user