Archive for the ‘Apple’ Category

A world of ebooks

Ноябрь 28th, 2010
ebooks I am a bibliophile, or, to say it in plain English, a book lover. I have been collecting books since I was in first grade. I read books at high speed, which is both a blessing and a curse. A blessing, because I can squeeze useful information out of a book very quickly, and that's useful for my job, and for some of my hobbies. A curse, because when I travel one book is usually not enough to keep me busy for the whole travel, and I need to carry or buy more, with negative effects on the weight of my luggage and my on my back. Ten years ago I had a brief but intense experience with electronic books in a Palm hand held device. It didn't last long, though. The quality of ebooks and readers in that period was less than optimal, and I have left the matter rest for a while.
In the meantime, I kept collecting electronic books, mostly PDF editions of technical books that I keep in my laptop for quick reference. Reading them from cover to cover, though, is not a pleasant experience in a laptop. Ditto for reading fiction or essays. The laptop screen is not comfortable for such exercise.
Then, last year, I bough an ebook reader.
That changed the whole business. Reading ebooks became very similar to reading paper books. The size of the screen and the ability of increasing font size makes your reading a pleasure. As for my back and luggage problems, that's solved hands down. The weight of the device is the same, no matter if I carry one ebook or one hundred.
Suddenly, the dozen of ebooks that I had kept idle in my laptop sprang to life, and I was able to read them like a paper book, easily, comfortably, and with pleasure.
I started buying more ebooks, both of fiction and of technical matters. The latter are especially welcome. Whenever I travel to conferences, I am tempted to buy some useful book, and then I regret when it burdens my backpack during the trip home, and fights for room on my overcrowded book shelves. No more of this. Now, when I visit a book booth at a conference, I simply take note of the interesting titles, and then I buy the ebooks at the publisher's site directly. If there is no ebook, I can easily convince me that the book is not really needed.
A few months ago there was some new development. My ebook reader's screen was faulty. It was showing a few unwanted lines at the bottom and the top of the screen, making it difficult to read menus. No big deal. I sent it to the manufacturer, which replaced the screen for free. The only trouble was that the replacement took three months! During that period, I experienced reading ebooks (to which I was by then addicted) with my Android phone, using a wonderful application named Aldiko. The user friendliness of this app more than compensated for the smaller screen size, and I was able to read technical and fiction books with little problem. But I was missing the big screen. So the delay of the back shipment was partially responsible for the lowering of my defenses, when I entered an Apple store and I couldn't leave without a new iPad.
I felt guilty for a while, but the guilt disappeared in a matter of hours, when I loaded all my ebooks in the iPad, and saw what a difference a bigger and colorful screen does. Compared to the six inches of my ebook reader, the iPad is huge, and the reading is even easier and more pleasurable. I was hooked.
Since then, my personal library of ebooks has grown rapidly. I have bought 90 (yes, ninety) books from O'Reilly, including many that I had already bought on paper, and now I am giving away to friends and libraries.
I need to spend a few words of praise for O'Reilly. In the jungle of book publishing, O'Reilly is the best and more user friendly publisher available. The quality of its books is excellent, the choice of catalog vast and modern, the service impeccable. There are other publishers that offer comparable quality (e.g. the Pragmatic bookshelf or Manning) but not the same rich catalog, or a similarly vast catalog (e.g. Packt Publishing) but not the same quality.
If I have to note any negative points about O'Reilly, is that there is no wish list in their shop. So, for now, I am restricting my wishes to my list on Amazon.

PlanetMySQL Voting: Vote UP / Vote DOWN

Developer Week in Review

Ноябрь 3rd, 2010

Here's your weekly helping of developer info:

The sudden but inevitable Apple news

Several pieces of news on the Apple front this week. First up: the Gold Master seed (which either sounds like something you plant to get nice apples, or something out of a bad SF eugenics novel) for iOS 4.2 dropped, signaling the green light for iPad/iPhone/iPod developers to submit 4.2-ready applications to the App Store. Traditionally, the pre-release to developers is followed about a week later by the general release, and is identical.

Meanwhile, continuing to muddy the waters about what is and isn't allowed on the iPhone, Adobe gave a sneak peak of a tool that converts Flash movies into standard HTML5 movies, thus making them viewable on iOS devices (and HTML5 browsers without Flash installed.)

And evidently the iPhone will be coming to Verizon in 2011. I'm sure you've already heard about it, I just didn't want to be the last journalist on the planet to report it. Is there such a thing as a secret at Apple anymore? At this point, if Apple had been in charge of the D-Day invasion, the Germans would have been waiting on the beach with gift baskets.

Motivations behind Oracle's Sun acquisition get clearer

So far this year, Oracle has sued Google over Java on the Android and pretty much killed off OpenSolaris. So what's next for Larry & Co.?

The answer came when 33 contributors from the OpenOffice project jumped ship for LibreOffice. Evidently, Oracle appeared to have little interest in putting much effort into OpenOffice. Decoding the corporate-speak from Oracle's PR department, the reaction to the defections so far might best be summed up as "Don't let the door hit your butt on the way out."

As former Sun projects acquired by Oracle drop like flies, it becomes possible to deduce what Oracle really bought Sun for simply by listing what's left: mainly MySQL and Sun's hardware business. Bets, anyone?

Is IE slowly heading toward minority status?

No one browser can take the credit, but Microsoft's Internet Explorer continues to slowly lose traffic share to Firefox, Chrome, and the other hungry young punks nipping at its heals. Now down to 59.25 percent of total browser usage, IE is a far cry from the heady days of 90-plus percent dominance. For all you AJAX and HTML5 developers out there, it should serve as a signal that the days of "This website requires Internet Explorer" need to be laid to rest for good, unless you like alienating 40 percent of your potential user base.

Another week, another platform

So, you say that developing for OS X, Windows, Linux, iOS, J2ME, HTML5 and Android isn't enough diversity to keep your mind occupied. Now you can add Chrome OS to that list. Vendors will soon release an onslaught of Chrome-powered netbooks, smartbooks and notebooks. Conventional wisdom is that the world doesn't need another notebook operating system, but conventional wisdom said the same thing about Android, and now everybody laughs at him at the water cooler at work. In other words, ignore Google at your peril.

That's it for this week. Suggestions are always welcome, so please send tips or news here.



PlanetMySQL Voting: Vote UP / Vote DOWN

Cloud, SaaS and The Consumerization of IT

Ноябрь 1st, 2010

Gigaom_logo

I wrote a guest column for GigaOm on how open source software, cloud and software as a service are helping to bring about the consumerization of IT: namely bringing simplicity where complexity reigned.  I cited some examples including New Relic, Box.net and Apple.

Open source has gone a long way toward putting power back in the hands of developers, who can download, install and deploy software without having to go through any kind of convoluted sales or budget approval process.  You want MySQL?  You can download and install in 15 minutes, and you don’t have to talk to anyone to do it.

Software as a service (SaaS) takes this to an even broader audience, enabling employees to get the kind of lightweight, consumer, self-serve capabilities in their job without even having to run their own servers.  Platforms like Amazon AWS, Heroku, Makara, RightScale and others put this same kind of SaaS power in the hands of developers...

My view: ease of use trumps a long feature list any day of the week. There are both techological reasons as well as sociological and economic reasons for why organizations are seeking greater simplicity.  Part of this stems from the fact that complex enterprise applications grew beyond the ability of most organizations to successfully adopt.  

Head over to GigaOm for the full post.


PlanetMySQL Voting: Vote UP / Vote DOWN

Four short links: 21 October 2010

Октябрь 21st, 2010

  1. Using MysQL as NoSQL -- 750,000+ qps on a commodity MySQL/InnoDB 5.1 server from remote web clients.
  2. Making an SLR Camera from Scratch -- amazing piece of hardware devotion. (via hackaday.com)
  3. Mac App Store Guidelines -- Apple announce an app store for the Macintosh, similar to its app store for iPhones and iPads. "Mac App" no longer means generic "program", it has a new and specific meaning, a program that must be installed through the App store and which has limited functionality (only one can run at a time, it's full-screen, etc.). The list of guidelines for what kinds of programs you can't sell through the App Store is interesting. Many have good reasons to be, but It creates a store inside itself for selling or distributing other software (i.e., an audio plug-in store in an audio app) is pure greed. Some are afeared that the next step is to make the App store the only way to install apps on a Mac, a move that would drive me away. It would be a sad day for Mac-lovers if Microsoft were to be the more open solution than Apple. cf the Owner's Manifesto.
  4. Privacy Aspects of Data Mining -- CFP for an IEEE workshop in December. (via jschneider on Twitter)


PlanetMySQL Voting: Vote UP / Vote DOWN

CAOS Theory Podcast 2010.02.19

Февраль 20th, 2010

Topics for this podcast:

*Jacobsen v. Katzer and open source impact
*Intel, Nokia team up for MeeGo open source OS
*Open source continues in embedded space
*MongoDB and the advent of the NoSQL databases
*Copyrights, complexities, control and conflict

iTunes or direct download (21:48, 6.07 MB)


PlanetMySQL Voting: Vote UP / Vote DOWN

CAOS Theory Podcast 2010.02.05

Февраль 5th, 2010

Topics for this podcast:

*Matt Asay moves from Alfresco to Canonical
*GPL fade fuels heated discussion
*Apple’s iPad and its enterprise and open source impact
*Open source in data warehousing and storage
*Our perspective on Oracle’s plans for Sun open source

iTunes or direct download (32:50, 9.2 MB)


PlanetMySQL Voting: Vote UP / Vote DOWN

Linux/OSX: find out what network ports are in use

Январь 5th, 2010

To get a quick idea of what ports you have open on your local box, you can use nmap.

~ jhaddad$ nmap localhost
Starting Nmap 5.00 ( http://nmap.org ) at 2010-01-05 11:06 PST
Interesting ports on localhost (127.0.0.1):
Not shown: 499 closed ports, 492 filtered ports
PORT STATE SERVICE
80/tcp open http
88/tcp open kerberos-sec
548/tcp open afp
631/tcp open ipp
3306/tcp open mysql
3325/tcp open unknown
5900/tcp open vnc
9000/tcp open cslistener
10000/tcp open snet-sensor-mgmt

For more detailed information, try netstat:

netstat -an

You’ll get a breakdown of every socket open on your machine – useful for figuring out who’s connected and from where.

The OSX version of netstat lacks a few options – such as the useful ‘-p’ option to display the process id (PID) – which can be useful combined with kill to get rid of unwanted connections – for instance,an SSH tunnel accidentally left open.


PlanetMySQL Voting: Vote UP / Vote DOWN

MySQL 5.1.42 available for MacOS X 10.6 (Snow Leopard)

Январь 4th, 2010

A few days ago MySQL 5.1.42 got released and it is now available with builds for MacOS X 10.6 (Snow Leopard)! The download website doesn't show it yet, but if you are burning to try, you can get it from the mirror-picking-website.

As usual, don't forget to checkout the changelog before upgrading!

If you want to compile it yourself, and need a universal binary, you could try my how-to find earlier on my blog.


PlanetMySQL Voting: Vote UP / Vote DOWN

Building MySQL universal binaries using MacOS X 10.6 (Snow Leopard)

Декабрь 31st, 2009

On the eve of 2010.. and your boss wants to stick to these MacOS X 10.5 machines, too stubborn or chicken to upgrade. Some developers still have their old PowerBook laptops and they need MySQL flying on PowerPC machines. To top it all, one guy said he wanted to have 32 and 64-bit in one bite. *Sigh* .. But there is an easy way out! A universal binary!

This post shows you a way to create MySQL universal binaries using MacOS X 10.6 so you can run them on MacOS X 10.5/10.6 whether it is PowerPC or Intel, or 32bit or 64bit.

However, if you need libmysqld (Embedded MySQL), this post will not work for you.

Requirements:

  • You have MacOS X 10.6 with latest Xcode (fully) installed.
  • The MySQL source unpacked somewhere. Get it on the MySQL download website under Source Downloads, package named Compressed GNU TAR archive (tar.gz).
  • And some nerves for when the build process fails.

Most complete Universal Binary

First, here is away to build MySQL so it runs on MacOS X 10.5 Intel/PowerPC and 10.6 32 or 64-bit.

Here is the source of the build script names build.sh. Executed it while located inside the source directory of MySQL.


#!/bin/bash

SDK="-isysroot /Developer/SDKs/MacOSX10.5.sdk"
SDKLIB="-Wl,-syslibroot,/Developer/SDKs/MacOSX10.5.sdk"
export MACOSX_DEPLOYMENT_TARGET="10.5"
PREFIX=/opt/mysql/mysql-5.1.42-universal-macosx-10.5

ARCH="-arch i386 -arch x86_64 -arch ppc"

export CFLAGS="-O2 -fPIC $ARCH $SDK"
export CXXFLAGS="-O2 -fPIC $ARCH $SDK"
export LDFLAGS="$ARCH $SDKLIB"

CC="/usr/bin/gcc-4.2"
CXX="/usr/bin/g++-4.2"
OBJC="/usr/bin/gcc-4.2"

INSTALL="/usr/bin/install -c"


./configure --prefix=$PREFIX \
--disable-dependency-tracking \
--mandir=$PREFIX/share/man --infodir=$PREFIX/share/info \
--localstatedir=$PREFIX/var/ --libdir=$PREFIX/lib \
--bindir=$PREFIX/bin --libexecdir=$PREFIX/bin \
--includedir=$PREFIX/include \
--datadir=$PREFIX/share/ --sysconfdir=$PREFIX/etc \
--with-extra-charsets=complex \
--with-mysqld-user=mysql \
--without-docs \
--with-plugins=all \
--enable-thread-safe-client --without-embedded-server \
--with-pic --with-libedit

if [ $? -eq 0 ]; then
make clean
time make -j 2
fi

Here is what file shows for the mysqld binary:


Black:mysql-5.1.42 geert$ file sql/mysqld
sql/mysqld: Mach-O universal binary with 3 architectures
sql/mysqld (for architecture i386): Mach-O executable i386
sql/mysqld (for architecture x86_64): Mach-O 64-bit executable x86_64
sql/mysqld (for architecture ppc7400): Mach-O executable ppc

These binaries were tested and work on MacOS X 10.6 Intel and MacOS X 10.5 PowerPC.

32/64-bit Universal binaries for MacOS X 10.6

Same as above, but with the following changes:


SDK="-isysroot /Developer/SDKs/MacOSX10.6.sdk"
SDKLIB="-Wl,-syslibroot,/Developer/SDKs/MacOSX10.6.sdk"
export MACOSX_DEPLOYMENT_TARGET="10.6"
PREFIX=/opt/mysql/mysql-5.1.42-universal-macosx-10.6

Setting the above is probably not needed when you are already on a Mac running 10.6, but it doesn't hurt to be explicit.

Need it for MacOS X 10.4?

I gave this a spin:


SDK="-isysroot /Developer/SDKs/MacOSX10.4u.sdk"
SDKLIB="-Wl,-syslibroot,/Developer/SDKs/MacOSX10.4u.sdk"
export MACOSX_DEPLOYMENT_TARGET="10.4"
ARCH="-arch i386 -arch ppc"

But it failed with


/Developer/SDKs/MacOSX10.4u.sdk/usr/include/stdarg.h:4:25:
error: stdarg.h: No such file or directory

.. but I lack intrest making stuff for MacOS X 10.4 (Tiger). Consider this your homework!


PlanetMySQL Voting: Vote UP / Vote DOWN

Snow Leopard blues

Сентябрь 13th, 2009

Apple Snow Leopard blues

On Friday afternoon, I went to give a presentation about MySQL advanced features at the Sardegna Ricerche technology park. The presentation included a quick introduction to MySQL Sandbox, something that I have been doing for years, and I thought I could do blindfold, if required. However, something didn't go as expected.
Just when I was showing off how easy is it to install a MySQL sandbox from a tarball, I was faced by an unexpected error. The tar application was not among the recognized ones. As soon as I saw the error, I immediately knew what had happened. That morning I upgraded my Mac OSX to Snow Leopard. And, unknown to me, Apple has changed the default tar, which is not a symlink to the GNU tar, but points at bsdtar. Not a difficult fix (I released a new version of MySQL Sandbox this morning) but not something that you want to deal with during a live demo either.
Apart from that, Snow Leopard seems to behave nicely. Somebody else had nasty compatibility problems but so far I have been spared.
One annoying problem is that Safari crashes with Java applications, because of the faulty Java 1.6 package released with Snow Leopard. Apparently, Java 1.5 and 1.6 both point at the same binaries, on the grounds that 1.6 is backward compatible. Well, it is, but it crashes the browser, so I looked around for a remedy, and I found out that someone else has fixed the issue and shared the recipe. Thanks, folks. It worded for me as well.

PlanetMySQL Voting: Vote UP / Vote DOWN