Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
terasakisatoshi committed May 6, 2024
1 parent 91494f1 commit 925e537
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 7 deletions.
16 changes: 15 additions & 1 deletion cxxwrap1/Manifest.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

julia_version = "1.10.3"
manifest_format = "2.0"
project_hash = "1b0a6b6d81b3045788b43b329bfad98437353c80"
project_hash = "3cef41461bc070f5890a35a6516e3e4c0caa014a"

[[deps.Artifacts]]
uuid = "56f22d72-fd6d-98f1-02f0-08ddc0907c33"
Expand All @@ -20,6 +20,10 @@ version = "0.15.1"
deps = ["Printf"]
uuid = "ade2ca70-3891-5945-98fb-dc099432e06a"

[[deps.InteractiveUtils]]
deps = ["Markdown"]
uuid = "b77e0a4c-d291-57a0-90e8-8db25a27a240"

[[deps.JLLWrappers]]
deps = ["Artifacts", "Preferences"]
git-tree-sha1 = "7e5d6779a1e09a36db2a7b6cff50942a0a7d0fca"
Expand All @@ -29,6 +33,9 @@ version = "1.5.0"
[[deps.Libdl]]
uuid = "8f399da3-3557-5675-b5ff-fb832c97cbdb"

[[deps.Logging]]
uuid = "56ddb016-857b-54e1-b83d-db4d58db5568"

[[deps.MacroTools]]
deps = ["Markdown", "Random"]
git-tree-sha1 = "2fa9ee3e63fd3a4f7a9a4f4744a52f4856de82df"
Expand Down Expand Up @@ -57,11 +64,18 @@ uuid = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
uuid = "ea8e919c-243c-51af-8825-aaa63cd721ce"
version = "0.7.0"

[[deps.Serialization]]
uuid = "9e88b42a-f829-5b0c-bbe9-9e923198166b"

[[deps.TOML]]
deps = ["Dates"]
uuid = "fa267f1f-6049-4f14-aa54-33bafae1ed76"
version = "1.0.3"

[[deps.Test]]
deps = ["InteractiveUtils", "Logging", "Random", "Serialization"]
uuid = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

[[deps.Unicode]]
uuid = "4ec0a83e-493e-50e2-b9ac-8f72acf5a8f5"

Expand Down
2 changes: 2 additions & 0 deletions cxxwrap1/Project.toml
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
[deps]
CxxWrap = "1f15a43c-97ca-5a2a-ae31-89f07a497df4"
Libdl = "8f399da3-3557-5675-b5ff-fb832c97cbdb"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
18 changes: 12 additions & 6 deletions cxxwrap1/callcxx.jl
Original file line number Diff line number Diff line change
@@ -1,12 +1,18 @@
using Test

# Load the module and generate the functions
module CppHello
using CxxWrap
@wrapmodule(()->joinpath(".","libhello.so"))
using Libdl: dlext

using CxxWrap
@wrapmodule(() -> joinpath(".", "libhello.$(dlext)"))

function __init__()
function __init__()
@initcxx
end
end
end

# Call greet and show the result
@show CppHello.greet("Hello World")
@testset "greet" begin
# Call greet and show the result
@test CppHello.greet("Hello World") == "Hello World"
end

0 comments on commit 925e537

Please sign in to comment.