-bash : rvictl: command not found, Mac book pro OS X 10.7.5 & Xcode 4.6 - macos

I want to debug some network bug with my application ,I found a way to create rvi to trace, But I even can't finish step 1 :
rvictl -s
-bash : rvictl: command not found
what should I do ?
I follow the site:
https://developer.apple.com/library/mac/qa/qa1176/_index.html
help! thanks

Mavericks and beyond: You need to install XCode from the App Store, and then you need to launch XCode once, and accept installation of additional tools. Restart your terminal. Good to go.

I found the solution here.
In summary, the link above explains that the issue may stem from installing Xcode without installing the additional components.
Check rvictl is installed by looking for the /usr/bin/rvictl folder. If it does not exist, then rvictl is not installed. To install the packages, open your application folder through finder, right click on the Xcode app, and follow the path below to find the items which need to be installed manually:
Xcode.app/Contents/Resources/Packages/MobileDevice.pkg
Xcode.app/Contents/Resources/Packages/MobileDeviceDevelopment.pkg
Restart your terminal and.... Voila !! it should work now.
CATALINA UPDATE.
Based #KarthicRaghupathi's comments. the rvictl location was changed in Catalina. The rvictl file is now located at /Library/Apple/usr/bin.
The rest of the process stays the same as above.

I'm using macOS Catalina and Xcode 11, Could able to find rvictl file in /Library/Apple/usr/bin. but still got the same error
-bash : rvictl: command not found
Tried all provided solution nothing worked for me. Adding sudo saved me,
sudo rvictl -s [DEVICE UDID]
[or]
sudo /Library/Apple/usr/bin/rvictl -s [DEVICE UDID]
This may help some one.

You need to install the Command Line Tools for Xcode, available here:
https://developer.apple.com/downloads/index.action?name=for%20Xcode%20-#
That includes the rvictl program.

It seems like default location and installed location of rvictl on Catalina are different.
rvictl should be installed by Xcode. Look for it at path: /Library/Apple/usr/bin/rvictl. The default shell has /Library/Apple/usr/bin/ in its path, either customise it or provide full qualified path i.e
/Library/Apple/usr/bin/rvictl -s 00008020-XXXXXXXXXXXXXXXX
Source: https://forums.developer.apple.com/message/392193#392193

When you say: the command line tools for 10.10 apparently do not include the rvictl program - I get the error message: command not found
You need to see the comment above: Mavericks and beyond: You need to install XCode from the App Store, and then you need to launch XCode once, and accept installation of additional tools. Restart your terminal.
It will then appear.

Related

Where does xcode-select store information

I am writing a tool, that runs clang from Xcode path. This tool gets location of Xcode by running /usr/bin/xcode-select, but I want to remake it so that it reads Xcode location directly from disk instead of running xcode-select. I tried to debug xcode-select (which is a symlink to xcrun), but didn't manage to find how it stores/reads location of Xcode (does it stores it in environment or files?). If you know how to get location of Xcode without running xcode-select (and xcrun), please help! Thanks in advance!
As of Xcode 6, the location is a symlink at /var/db/xcode_select_link. You can output the target of the link to your terminal with the command readlink /var/db/xcode_select_link. If there is no link (eg, you run xcode-select --reset), the default xcode installation is used.
With NSWorkspace you can do a:
[NSWorkspace sharedWorkspace]fullPathForApplication:#"Xcode"];
which returns /Applications/Xcode.app when it's installed in the default location.
// …or, as I have seen in the documentation, there's also
- (NSURL *)URLForApplicationWithBundleIdentifier:(NSString *)bundleIdentifier
// which returns the URL for the application with the specified identifier.
Used dtruss command to print all open syscalls of xcode-select.
dtruss -f -t open xcode-select -print-path
Found at, that it tries to read /usr/share/xcode-select/xcode_dir_path and get Xcode location from there. If it does not exist, it takes the default Xcode location, which is /Applications/Xcode.app/.

Issue with uninstalling Xcode 3.2 on Mountain Lion

I just upgraded to Mountain Lion (from Snow Leopard) so as to take advantage of Xcode 4.
Before installing Xcode 4, I would like to remove Xcode 3 (not required, but want to clean up before moving on).
The standard method of removing Xcode 3 is:
$ sudo <Xcode>/Library/uninstall-devtools --mode=all
However, when I issue this command, even from within the /Library folder, the only thing that happens is I get a "command not found" after entering my password.
I can see uninstall-devtools in Finder, so I know it's there. I just can't execute it for some reason. I've tried every possible way of running the uninstall tools.
Assistance is greatly appreciated. Thanks.
If the file really is there, type sudo in the terminal window (with a trailing space), drag and drop the uninstall-devtools file on the window, then append --mode=all. That should clear any chance you have to make a typo or any other mistake.
Similarly to information I found in another SO article, my laptop's old XCode 3.2 didn't even have the uninstall-tools utility.
So it worked fine for me to simply delete the XCode.app folder.

How to build OpenCASCADE on MAC (Mountain Lion)

I am trying to build OpenCASCADE on Mac, but I am not having any luck.
I downloaded it from Github in tar.gz, but I am really new to Mac and I am stuck.
Can anybody explain what should be my next step?
(I found some terminal commands what I should use, but I am not familiar with them. So if it is the right way to build OpenCASCADE on Mac please write down the terminal commands with details. Thank you!)
EDIT:
I understood the command line commands now from the link below. I understood it before too, but I was mistaken, because my main problem was, that I didn't had gcc installed (XCode does not installs gcc automatically...). So anyways, now finally I can run the cmake command. It starts but it ends with this:
CMake Error at /Applications/CMake
2.8-9.app/Contents/share/cmake-2.8/Modules/FindX11.cmake:420 (MESSAGE): Could not find X11 Call Stack (most recent call first):
CMakeLists.txt:313 (FIND_PACKAGE)
Anybody have any idea what to do? I tryed to search this too here, and google...and I found some "solutions" but those didn't work for me.
EDIT EDIT:
The solution for the last edit is that Mountain Lion doesn't install X11. So open up an app that uses X11 or Xquartz and it will install automatically.
Unfortunetly it still doesn't work. My next error message is the following after the make command in terminal:
In file included from
/Users/davidbirkas/Documents/tpaviot-oce-6c9a06a/src/AlienImage/AlienImage_X11XWDAlienData.cxx:14:
/Users/davidbirkas/Documents/tpaviot-oce-6c9a06a/inc/Aspect_XWD.hxx:5:12:
fatal error:
'X11/XWDFile.h' file not found
# include
^ 1 error generated. make[2]: * [adm/cmake/TKService/CMakeFiles/TKService.dir/_/_/__/src/AlienImage/AlienImage_X11XWDAlienData.cxx.o]
Error 1 make1:
[adm/cmake/TKService/CMakeFiles/TKService.dir/all] Error 2 make: **
[all] Error 2
Any ideas how to fix this?
Ensure that, together with XCode, you also install the X11 support from Apple's Devtools. Your error message is indicating that it is missing.
FWIW, I have written a blog post about OCC and PythonOCC on Mac some time ago. Maybe you'll find some detailed info there.
http://cad-3d.blogspot.com/2011/10/pythonocc-open-source-interactive-cad.html
In this post, I still talk about using the binary installer, but recent updates to the OCE edition compile usually without problems out-of-the-box, also on OSX (that is NOT the case with the official OpenCASCADE release).
I spent a little time on this and I think I have it. Here is what I did step by step:
Preparation phase:
Installing Xcode (with command line tools) = Apple developer site
// If Xcode doesn't install gcc, than you can still download it from the developer site as Command Line Tools for Xcode.
Installing Cmake (with command line tools) = Google
// You can download it from the official site with a .dmg/.pkg file extension. Easy install.
X11 under Mountain Lion "changed" to Xquartz. Probably it is not installed by default, but it is easy to check it. Just go to the folder "Application" and start the X11 app. If X11/Xquartz is not installed than it will install automatically!
Installing FTGL = MacPorts = Google
// Download MacPorts from their official site, install it with the installer, than write this to the terminal:
sudo port install ftgl
Download OCE and extract it (.OCE-0.9.0.tar.gz file) = https://github.com/tpaviot/oce/wiki/Download
Installing phase:
I. Open Terminal.
II. Run this command
// This will set the proper PATH.
ln -s /opt/X11/include/X11 /usr/local/include/X11
III. Than from the Terminal go to the directory where you extracted the OCE file (the original extracted file name should be: tpaviot-oce-6c9a06a).
IV. Than write these commands:
// You make a build directory to the extracted OCE folder.
mkdir build
cd build
V. After this you give out the cmake command:
cmake -DOCE_INSTALL_PREFIX:PATH=$HOME/OCE \
-DOCE_WITH_FREEIMAGE:BOOL=ON \
-DOCE_WITH_GL2PS:BOOL=ON \
-DOCE_DRAW:BOOL=ON \
..
VI. And at the end the make commands:
make
make install/strip
If you did everything exactly like this, than it should work!
Give OCE a try. Compiling for osx is a walk in the park

XCode 4.3 Command Line Tools Package with Invalid Checksum

The package Apple provides to install the command line tools with Xcode 4.3 is corrupted, and I seem to need it because I'm developing some command line tools.
Has anybody found an alternative Command Line package for Xcode 4.3 from Apple that works or an workaround for the subject?
Xcode includes a new "Downloads" preference pane to install optional components such as command line tools, and previous iOS Simulators.
So, I found a way to do this correctly.
The problem is really in one of the European mirrors from Apple.
The workaround is to:
- Install Tor: https://www.torproject.org/
- Choose a Tor node in the USA
- Logging into your Apple Developer account and download the package
It now opens correctly without any checksum warning.
I solved my own problem of downloading/installing Xcode 4.3.1 "Command Line Tools" by getting them directly from the developer's webpage. The March version yielded a checksum error just like
the download from within Xcode 4.3.1, i.e. Xcode/Preferences/Downloads . But I did have success with the February version of CLT. I don't know why things were out-of-sync.
I had the same problem when trying to install the Command Line Tools from the Downloads tab in the XCode preferences (also downloading from Europe). I fixed it by clearing the dns cache on my system.
This is the Terminal command to clear the dns cache (OSX Lion):
dscacheutil -flushcache
Restart XCode after running this command, it may not fix the problem with the checksum until you do.
try:
defaults write com.apple.frameworks.diskimages skip-verify -bool true
Just add another mirror for the download site:
Use the following to determine a valid ip:
http://www.webmaster-toolkit.com/dns-query.shtml?address=adcdownload.apple.com
and add this to /etc/hosts:
adcdownload.apple.com
Example (ip might already have changed)
64.211.144.168 adcdownload.apple.com.
You can simply click skip while the disk image is verifying. I have installed from a dmg of CLT-4.3 with this problem and built an extensive amount of software with if successfully on my te

How to install native assembler for Mac OSX?

I am interested to know how can I install native assemblar (I think also known as AS) on Mac OSX Lion. Someone suggested that I can use the Xcode to do it but I didn't see any options.Terminal windows is not able to recognize AS as command right now. Can someone provide more insight on this ? I am new to Mac/Unix environment so please provide help accordingly.
If you have Xcode installed, then you have as.There is no option to install specific packages from the Xcode installer.
as should be in /usr/bin/:
ls -l /usr/bin/as
If not, you probably have a problem with your Xcode installation.
Otherwise, also check your PATH environment variable, to ensure /usr/bin/ is in the list.
echo $PATH
If you've installed Xcode 4.3, it doesn't install the command line tools anymore. To get them, you have to launch Xcode, go to Xcode > Preferences... > Downloads tab, then click the 'Download' button for 'Command Line Tools'. You'll need to sign in with an Apple Developer ID.
Using Xcode 4.6 with Command Line Utilities installed
export PATH=/Applications/Xcode.app/Contents/Developer/usr/bin:$PATH
as will execute along with the other command line utilities.

Resources