Cramming PhysX in there
More PhysX work More PhysX work
This commit is contained in:
19
modules/PhysX/physx/physx-sys/make-sources.sh
Normal file
19
modules/PhysX/physx/physx-sys/make-sources.sh
Normal file
@@ -0,0 +1,19 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
# This script finds all of the cpp files in a <directory> and generates a rust
|
||||
# array of strings into physx-sys/sources/<name> that is used by the build script
|
||||
# to compile all of the source files when compiling physx-sys
|
||||
#
|
||||
# usage: make-sources.sh <physx c++ source directory path> <name>
|
||||
dir=$1
|
||||
file="$(dirname "$0")/sources/$2"
|
||||
|
||||
printf "[\n" > "$file"
|
||||
|
||||
for entry in "$dir"/*.cpp
|
||||
do
|
||||
printf " \"%s\",\n" "$(echo "$entry" | sed -r "s/.+\/(.+)\..+/\1/")" >> "$file"
|
||||
done
|
||||
|
||||
printf "]\n" >> "$file"
|
||||
Reference in New Issue
Block a user