Updating VLC To Play Youtube

When VLC was last updated for PowerPC it was possible to play Youtube links copied into it - alas that ability has long since expired but you can bring it back with a few updated components.

This only applies to the last PPC iteration of VLC, version 2.0.10 and also requires the ever wonderful PPCMC (for latest security certificates and curl.)

The following code copied into Terminal will do the following:

Make a directory in VLC preferences for the latest security certificates

Delete the old Youtube lua script from VLC

Create a symlink in VLC preferences of the security certificates in PPCMC (this will update when PPCMC is updated)

Finally, using curl, copy the latest Youtube lua script into VLC


mkdir -p ~/Library/Preferences/org.videolan.vlc/ssl/certs
rm -f /Applications/VLC.app/Contents/MacOS/share/lua/playlist/youtube.luac
ln -s /Applications/PPCMC.app/certs/cacert.pem ~/Library/Preferences/org.videolan.vlc/ssl/certs/ca-certificates.crt
/Applications/PPCMC.app/bin/curl --insecure https://raw.githubusercontent.com/videolan/vlc/master/share/lua/playlist/youtube.lua -o /Applications/VLC.app/Contents/MacOS/share/lua/playlist/youtube.lua


From the download here extract the compact Youtube browser, Choob and the VLC scripts, VLSEE and VLLISTEN into Applications and create shortcuts in the dock (right hand side for VLSEE/VLLISTEN as they are scripts.) Open VLC and in Preferences - /Input/Codecs change the Preferred video resolution to Standard and close.






Opening Choob, browse to your chosen video, right click to copy the link then click the VLSEE dock shortcut - VLC will open and quickly stream the video - quit VLC when finished.If you want to stream audio only then do the same but with VLLISTEN.




Virtual PC and Ancient IDEs: Part 1 - Setting up Virtual PC

As mentioned in my previous post I have set up a 17 inch PowerBook G4 for Python, Objective-C and C++ development. One of my newfound time-sinks-that-brings-me-joy is setting up old Windows environments and installing very old IDEs. Examples include Visual C++ 6, Borland Delphi 7 and most recently PalmOS IDEs. I thought to myself, why not set up VirtualPC on my PowerBook and see how viable it would be? That is what I will cover here in this post. My ultimate goal is to set up a Windows 98 virtual PC and a Windows 2000 virtual PC then set up the IDEs on both virtual PCs. This will be a good way to compare performance between the two OSs under Microsoft Virtual PC.

Setting up Microsoft Virtual PC was fairly straight forward. I grabbed the Virtual PC 7.02 installer, 7.03 updater and the modified networking kext from the Macintosh Garden. Installing Virtual PC 7.02 and then updating it to version 7.03 was a simple software install. Now onto the Now onto the quirk. As pointed out at the Macintosh Garden, if Virtual PC is left as is on Mac OS Leopard, a kext icon will appear on your dock and bounce up and down while Virtual PC is running. I copied over the modified kext to /Library/Extensions as instructed. When I opened Virtual PC after doing this, Virtual PC said "The software necessary to run Virtual PC for Mac is either missing or is installed incorrectly" and then repaired itself, reverting the kext at /Library/Extensions back to its original state. I opened the original and the modified kexts to see if I could see any differences between the two. I found that the modified kext's info.plist had two extra lines.

Here is the original info.plist...

<plist version="1.0"> <dict> <key>CFBundleDevelopmentRegion</key> <string>English</string> <key>CFBundleExecutable</key> <string>VirtualPCNetworking1040</string> <key>CFBundleGetInfoString</key> <string>7.0.3 (070613), &#169; 2005 Microsoft Corporation. All rights reserved.</string> <key>CFBundleIdentifier</key> <string>com.microsoft.VirtualPC.Networking.1040</string> <key>CFBundleInfoDictionaryVersion</key> <string>6.0</string> <key>CFBundleName</key> <string>Virtual PC Networking</string> <key>CFBundlePackageType</key> <string>KEXT</string> <key>CFBundleShortVersionString</key> <string>7.0.3</string> <key>CFBundleSignature</key> <string>????</string> <key>CFBundleVersion</key> <string>7.0.3</string> <key>OSBundleLibraries</key> <dict> <key>com.apple.kpi.bsd</key> <string>8.0.0b2</string> <key>com.apple.kpi.libkern</key> <string>8.0.0b2</string> <key>com.apple.kpi.mach</key> <string>8.0.0b2</string> </dict> </dict> </plist>

Here is the modified info.plist...

<plist version="1.0"> <dict> <key>CFBundleDevelopmentRegion</key> <string>English</string> <key>CFBundleExecutable</key> <string>VirtualPCNetworking1040</string> <key>CFBundleGetInfoString</key> <string>7.0.3 (070613), &#169; 2005 Microsoft Corporation. All rights reserved.</string> <key>CFBundleIdentifier</key> <string>com.microsoft.VirtualPC.Networking.1040</string> <key>CFBundleInfoDictionaryVersion</key> <string>6.0</string> <key>CFBundleName</key> <string>Virtual PC Networking</string> <key>CFBundlePackageType</key> <string>KEXT</string> <key>CFBundleShortVersionString</key> <string>7.0.3</string> <key>CFBundleSignature</key> <string>????</string> <key>CFBundleVersion</key> <string>7.0.3</string> <key>OSBundleLibraries</key> <dict> <key>com.apple.kpi.bsd</key> <string>8.0.0b2</string> <key>com.apple.kpi.libkern</key> <string>8.0.0b2</string> <key>com.apple.kpi.mach</key> <string>8.0.0b2</string> </dict> <key>LSUIElement</key> <string>1</string> </dict> </plist>

I opened the original kext in Text Wrangler, navigated to info.plist and added the two additional lines after the nested/inner dict block. Text Wrangler notified me that I did not have the privilege to modify this file. It asked for my password and saved the file after I authenticated. I was then able to open Virtual PC without being asked to repair my install or watch the white Lego jump up and down on the dock.

At this point I was able to make virtual PCs and install OSs on them. I made one for Windows 98 and Windows 2000. After the Windows installs completed, I installed the virtual PC additions for both virtual machines. This is done by clicking the PC menu then clicking the Install or Update Additions option.

This is a good stopping point. I wanted to share my experience with the kext quirk and what I had to do to fix it. As I set up the IDEs on these two virtual PCs I will share my findings and takes here.

As always, thank you for reading. Have fun!

TuneCatcher - A Youtube Audio Player

I've often heard people on the MacRumors PowerPC forum say that they like to use Youtube for audio playback only - listening to albums or gigs etc so don't really require all the CPU intensive donkey work of playing video.

With that in mind I've cobbled together TuneCatcher and TuneStreamer - scripts that play audio only and save on all important CPU cycles.

Included in the install is Choob - a TenFourFoxBox Youtube browser preloaded with a vintage Nokia N90 user agent (hence the groovy app icon) which eschews all the usual Youtube script clutter and allows you to browse for videos quickly and efficiently.

Download and unzip the installer dmg - once mounted there is a choice of two installers. Youtube-dl is a requirement for this package, so if you have it installed as normal or with PPCMC, choose the appropriate installer.





Incidentally, PPCMC is a must have application for any PowerPC Mac - apart from it's core functionality it's also a Swiss Army Knife of essential tools including Python, youtube-dl, ffmpeg, curl and soon, ffplay all in one package without the usual fuss of needing X11 and Macports.


The installer will create a TubeAudio folder in ~/Music and place Choob, mplayer, TuneCatcher and TuneStreamer in /Applications.

Use Choob to browse for your desired clip, right click and Copy Link Location, then click on TuneCatcher in the dock (assuming you made a shortcut earlier.)
The link is passed to youtube-dl, the m4a audio file is downloaded and opened by MPlayer where the normal keyboard shortcuts apply for playback control.
When the clip is finished (or stopped) it is moved to ~/Music/TubeAudio/Archive.




Note, the m4a encoding used on Youtube is problematic to PowerPC Macs - without conversion they'll need to be played in either MPlayer or VLC.

If the Youtube clip you want to play is of a length unreasonable to download, choose TuneStreamer instead but be aware this will not keep a copy of the clip.
Also because of piping the stream via stdin the normal MPlayer controls aren't available.

Download is available here.

Download the G3 compatible version here. Unfortunately, mplayer for G3 doesn't accommodate streaming or playing m4a audio, so using TuneCatcher, a standard 360P video is downloaded which mplayer plays without processing the video.

MPlayer keyboard shortcuts for reference:

Pause/Play.....Space
Left/Right.......Back/Forward 10 seconds
Up/Down........Back/Forward 1 minute
9/0................Volume -/+
[ ].................Decrease/Increase playback speed by 10%
ESC...............Stop and quit

Blogging Like It's 1999

Pardon the lazy Prince pun/reference but all will become clear...

While writing theses posts will always primarily be done in front of a Mac screen, it's nice to have the ability to write when out and about too - enter my pocket sized, vintage Oregon Scientific Osaris from 1999 - a budget copy of the mighty Psion Series 5 PDA.

Being an 18Mhz EPOC32 device, this thing only gently nibbles away on two AA batteries and saves files to a Compact Flash card - so even in the worst case scenario of the main and backup batteries failing, my data is safe.

 



Whilst working on a post it's no sweat to swap the Compact Flash card out of the Osaris and use an adaptor to share it with a Mac, however, I'm reluctant to place repetitive strain on the card hatch and connector on the Osaris - I'd rather use it's friction and fatigue free infrared port.

This is by necessity more than anything, as unfortunately, buying the Osaris secondhand, it didn't come supplied with the original serial connector lead so the only connectivity available is the infrared port and luckily, I do have an old USB infrared dongle - however, it only works with Windows 98/ME/XP.

At the moment I don't have a PC - old or otherwise - permanently setup but what I do have is Virtual PC 7 on my Powerbook.


So, after installing Windows 98SE to a 1Gb virtual drive, and doing a few optimisations to keep the CPU demands down, the workflow is as follows.


With the USB infrared dongle attached and in range of my Osaris with Desktop Link activated, I start Windows 98 and launch PsiWin (the connectivity manager designed for Psion PDAs but also fully compatible with the Osaris.)

Once the infrared serial connection is made, from PsiWin I can browse my Osaris and it's Compact Flash card and exchange files - in this instance, an EPOC Word document is imported and converted to a TXT file (MS Word and other options are available too.)

The same applies in reverse if I wanted to import a document to the Osaris with PsiWin converting the file to a native EPOC version.





Once within Windows, my document is readily accessible to OSX where I can work on it or share it to another device via WebDAV.


Virtual PC often gets a rough deal in the PowerPC sphere as being a poor substitute for Windows but I've had good use out of it - the key is to have reasonable expectations, use the oldest compatible version of Windows for your applications and to realise it's performance doesn't scale with the spec of your Mac.

wicknix

 In my two plus years away from this blog, I was also away from using PowerPC hardware most of the time.  So I hadn't been keeping up with the development of PowerPC software much.  Then I come back to find someone named wicknix who frequents the Mac Rumors PowerPC forum.  This guy has been very busy developing PowerPC and early Intel software, and he's done some pretty amazing work for Linux and Mac OS X users alike.  

He also has a blog called Random Mac Stuff where you can find all his software.

So I just wanted to help bring awareness to the amazing efforts this guy has made.  I have had written correspondence with him, and I can tell you he's extremely humble.  I was trying to recruit him to write here, but he's just too busy.  So thanks for all your work, wicknix!   


A list of everything he has done and/or contributed to:

Arctic Fox Browser for 10.6

InterWeb Browser for 10.6 & 10.7+

SpiderWeb Browser for 10.6 & 10.7+

Software for 10.4 - 10.7 and PowerPC Linux

Lubuntu PowerPC 12.04 & 16.04 Remix live DVD + installer

Debian Sid PowerPC Remix installer

How to install Fienix Soar on 32-bit PPC Macs

How to watch Twitch Streams on 10.3/10.4/10.5 (he contributed the twitch script)

Security of the mind

 Security is a very dynamic sort of thing quite often.  It changes a lot over time, but it also often stays the same in many ways.  For the average user out there, they only have the know-how to rely on the OS for all potential security threats.  We all have experience using the internet every single day, but some don't utilize the best security tool on earth...  your own sound judgment. But sound judgment often derives from experience.  From experience comes confidence, and from confidence comes a sound mind.  Confidence should never be cocky though, because that will get you into trouble eventually.

When you consider that Apple hasn't offered a security update for a PowerPC OS since 2009...  we really are on our own with OS X.  But that's okay, because we the users dictate how secure we are through our own habits online.  And I am guilty myself of not having the confidence in some to be their own best security in my past writing here.  I don't know if that ever hurt anyone's confidence back then, but I certainly didn't help it either.  This changes now to a personal policy of encouraging confidence once people are put on the right path.  I'm going to instill confidence rather than fear. 

We notice things much easier when of a calm mind, and awareness is very important with security.  

So the point here is don't allow the lack of security updates on OS X to ever stop you from using it online.  Look no further than TenFourFox for modern web compatibility and security.  We really owe so much to Cameron Kaiser, because he alone has kept Mac OS PowerPC a viable internet platform.  So let's give him the respect he deserves.

I have been away from PowerPC Linux for a few years now, and need to re familiarize myself with it again, so for the next few months at least, my writing will be Mac OS related, and to me that's a great place to start after a two year hiatus here.

So for the next few months I will be doing a series of writings on OS X PowerPC security in 2020/2021, and how to best protect yourself.  To instill in you what I have to offer in me to keep yourself safe on operating systems that are 11+ years old now.  Only now instead of a Sawtooth, I'm using a G4 mini that dual boots Tiger and Leopard.

You're all going to have hardened ceramic armour shells when I'm done with you!  I hope you all can deal with that!