Skip to content

Commit

Permalink
Fix way to copy libs.
Browse files Browse the repository at this point in the history
  • Loading branch information
ippee committed Jul 16, 2021
1 parent 8f2eef4 commit a15a079
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 5 deletions.
7 changes: 2 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,8 @@ cargo build
# on Windows
cp ./target/debug/libclipboard.dll ../../

# on macOS
cp ./target/debug/libclipboard.dylib ../../

# on Linux
cp ./target/debug/libclipboard.so ../../
# on macOS/Linux
bash ./copy_lib.sh
```

### Case B: Use the existing build files
Expand Down
12 changes: 12 additions & 0 deletions copy_lib.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#!/bin/sh

dylib="./target/debug/liblibclipboard.dylib"
so="./target/debug/liblibclipboard.so"

if [ -e $dylib ]; then
cp $dylib ../../libclipboard.dylib
fi

if [ -e $so ]; then
cp $so ../../libclipboard.so
fi

0 comments on commit a15a079

Please sign in to comment.