-
Notifications
You must be signed in to change notification settings - Fork 74
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MacOS - Appears to have NW RFC Library available #58
Comments
Yes, as soon I get some free capacity. |
The experimental support is provided in @next 1.0.0-rc4 and perhaps someone could help clarify following. In which folder should SAP NW RFC Library be installed on MacOS ? Are there best practices, like where such libraries should/must be installed? After SAP NW RFC Library installed, the node-rfc should be able to find it and I am not sure about optimal solution here. Using DYLD* environment variables is inconvenient as MacOS SIP removes these variables from sub-processes context. That way, mocha for example, or any other node script with subprocess, is not any more able to find SAP NW RFC Library. This library can't be bundled and shipped with node-rfc and perhaps the prerequisite could be using fixed location (which one?), the same I am using on test/dev Mac ? Asked also here. Feedback/ideas from MacOS experts would be helpful. Here the current setup: |
Clarifications are still ongoing how SAP NW RFC SDK dylibs for MacOS should be best installed on MaOC system. MacOS bindings are provided as of prerelease 6 (just published). install_name_tool --rpath <old-path> <new-path> <file> |
The macOS section added to documentation and here are scripts to show and set remote macOS dylib paths, in SAP NW RFC SDK for macOS: show_paths.sh #!/bin/bash
ARG1=${1:--D}
for filename in lib/*.dylib; do
otool "$ARG1" $filename
printf "\n"
done
for filename in bin/*; do
otool "$ARG1" $filename
printf "\n"
done set_paths.sh #!/bin/bash
if [ -z "$SAPNWRFC_HOME" ]; then
echo "SAPNWRFC_HOME env variable not set. Should point to SAP NWRFC SDK library root"
exit 1
fi
#
# lib folder fix
#
cd lib
RPATH="$SAPNWRFC_HOME/lib"
for filename in *.dylib; do
# LC_RPATH
install_name_tool -add_rpath $RPATH $filename
# LC_ID_DYLIB
install_name_tool -id @rpath/$filename $filename
done
# LC_LOAD_DYLIB
install_name_tool -change libicuuc.50.dylib @rpath/libicuuc.50.dylib libicui18n.50.dylib
install_name_tool -change libicudata.50.dylib @rpath/libicudata.50.dylib libicui18n.50.dylib
install_name_tool -change libicudata.50.dylib @rpath/libicudata.50.dylib libicuuc.50.dylib
cd ..
#
# bin folder fix
#
cd bin
for filename in *; do
chmod +x $filename
# LC_RPATH
install_name_tool -add_rpath $RPATH $filename
# LC_ID_DYLIB
install_name_tool -id @rpath/$filename $filename
# LC_LOAD_DYLIB
install_name_tool -change @loader_path/libsapnwrfc.dylib @rpath/libsapnwrfc.dylib $filename
install_name_tool -change @loader_path/libsapucum.dylib @rpath/libsapucum.dylib $filename
done
cd .. Please feel free to try and let me know if works for you. |
"OS X and ARM platforms are currently not supported, as SAP NW RFC Library is not available for those platforms"
Could this be opened up to allow for MacOS development?
The text was updated successfully, but these errors were encountered: