Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
W
wasm-watermarker
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nagayama15
wasm-watermarker
Commits
d7efd018
Commit
d7efd018
authored
Mar 15, 2019
by
nagayama15
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
🚧
why error
parent
9cf35632
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
23 additions
and
27 deletions
+23
-27
binaryen.cmake
cmake/binaryen.cmake
+17
-13
fmt.cmake
cmake/fmt.cmake
+4
-4
CMakeLists.txt
src/CMakeLists.txt
+2
-10
No files found.
cmake/binaryen.cmake
View file @
d7efd018
ExternalProject_Add
(
binaryen
URL https://github.com/WebAssembly/binaryen/archive/
version_72.zip
URL https://github.com/WebAssembly/binaryen/archive/
1.38.29.tar.gz
PREFIX binaryen
INSTALL_COMMAND
""
TEST_COMMAND
""
CMAKE_ARGS
-DBUILD_STATIC_LIB=O
FF
-DBUILD_STATIC_LIB=O
N
-DCMAKE_BUILD_TYPE=Release
)
...
...
@@ -14,18 +14,22 @@ ExternalProject_Get_Property(binaryen binary_dir)
file
(
MAKE_DIRECTORY
${
source_dir
}
/src
)
add_library
(
libbinaryen SHARED
IMPORTED
)
add_dependencies
(
lib
binaryen binaryen
)
add_library
(
binaryen::binaryen STATIC
IMPORTED
)
add_dependencies
(
binaryen::
binaryen binaryen
)
if
(
WIN32
)
set
(
binaryen_SHARED_LIB
${
binary_dir
}
/bin/libbinaryen
${
CMAKE_SHARED_LIBRARY_SUFFIX
}
)
else
()
set
(
binaryen_SHARED_LIB
${
binary_dir
}
/lib/libbinaryen
${
CMAKE_SHARED_LIBRARY_SUFFIX
}
)
endif
()
set_target_properties
(
libbinaryen
set_target_properties
(
binaryen::binaryen
PROPERTIES
IMPORTED_LOCATION
${
binaryen_SHARED_LIB
}
IMPORTED_IMPLIB
${
binary_dir
}
/lib/libbinaryen.dll.a
IMPORTED_LOCATION
${
binary_dir
}
/lib/libpasses.a
INTERFACE_INCLUDE_DIRECTORIES
${
source_dir
}
/src
INTERFACE_LINK_LIBRARIES
"
${
binaryen_other_libraries
}
"
)
target_link_libraries
(
binaryen::binaryen INTERFACE
${
binary_dir
}
/lib/libwasm.a
${
binary_dir
}
/lib/libasmjs.a
${
binary_dir
}
/lib/libpasses.a
${
binary_dir
}
/lib/libcfg.a
${
binary_dir
}
/lib/libir.a
${
binary_dir
}
/lib/libemscripten-optimizer.a
${
binary_dir
}
/lib/libsupport.a
)
cmake/fmt.cmake
View file @
d7efd018
ExternalProject_Add
(
fmt
URL https://github.com/fmtlib/fmt/archive/5.3.0.
zip
URL https://github.com/fmtlib/fmt/archive/5.3.0.
tar.gz
PREFIX fmt
INSTALL_COMMAND
""
TEST_COMMAND
""
...
...
@@ -15,10 +15,10 @@ ExternalProject_Get_Property(fmt binary_dir)
file
(
MAKE_DIRECTORY
${
source_dir
}
/include
)
add_library
(
lib
fmt STATIC IMPORTED
)
add_dependencies
(
lib
fmt fmt
)
add_library
(
fmt::
fmt STATIC IMPORTED
)
add_dependencies
(
fmt::
fmt fmt
)
set_target_properties
(
lib
fmt
set_target_properties
(
fmt::
fmt
PROPERTIES
IMPORTED_LOCATION
${
binary_dir
}
/libfmt.a
INTERFACE_INCLUDE_DIRECTORIES
${
source_dir
}
/include
...
...
src/CMakeLists.txt
View file @
d7efd018
...
...
@@ -3,14 +3,6 @@ add_executable(kyut
)
target_link_libraries
(
kyut
lib
binaryen
lib
fmt
binaryen::
binaryen
fmt::
fmt
)
if
(
WIN32
)
add_custom_command
(
TARGET kyut POST_BUILD
COMMAND
${
CMAKE_COMMAND
}
-E copy_if_different
${
binaryen_SHARED_LIB
}
${
CMAKE_CURRENT_BINARY_DIR
}
)
endif
()
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment