iPhone Gets .Net App Development
snydeq writes "Novell has announced MonoTouch 1.0, a commercial SDK that allows developers to build iPhone apps using Microsoft's .Net Framework instead of the Apple-designated C or Objective-C languages. The SDK leverages Novell's Mono runtime for running Windows apps on non-Windows systems, allowing developers to utilize code and libraries written for .Net and programming languages like C#. With MonoTouch, the Mono runtime provides such developer services as garbage collection, thread management, type safety, and Web services, said Mono leader Miguel de Icaza."
Well how long does it take to load the whole Mono framework runtime because every second counts on the iPhone?
Anyone know why Apple would allow one and not the other? Does Mono not multitask or something?
Very often, people confuse simple with simplistic. The nuance is lost on most. - Clement Mok
I am pretty sure that adding your own runtime violates the developer agreement. The article didn't say if this "app" ever got approved but I highly doubt it would (this would also raise concern about the lack of Java on the iPhone).
Also, using C# is not THAT much better than the native objective-c. According to the article, it seems that "mono-touch" is really just C# bindings for cocoa-touch and I have had very bad experience using C# bindings for just about any kind of C code (allocated memory not getting garbage collected, bindings/function names being outdated, unmanged heap space limits, etc.). It sounds fun to play around with but I definitely wouldn't invest a large amount of time/money on it yet.
Unity, www.unity3d.com, which uses Mono, has been available on the iPhone for some now.
So...is this an alternative to Apple's iPhone SDK, or does it work with it? (in other words, could developers not have to pay the Apple tax to write iPhone apps?)
Isn't Mono the KISSing disease?
I think their groupies probably have worse diseases than mono...
Sorry, Wrong KISS.
Any insufficiently advanced magic is indistinguishable from technology.
Even before we get to the performance issue, there are at least two others that could run blocking. 1) I wonder if this is the sort of thing Apple would approve. Recent rants would seem to indicate if it allows any sort of a shell, no way. Otherwise, who knows? 2) Apple enforces it's look-and-feel rules religiously. Last I saw there was NOTHING .Net that looked at all Aqua. The stuff at unity3d.com looks cool, and would seem to *imply* Apple's OK with however their stuff looks, but I couldn't find a screen shot that showed me e.g. a typical config panel so I could compare it to iPhone's native bits.
âoeThe wall between art and engineering exists only in our minds.â -- Theo Jansen
Unless you write directly in machine code then you have no place to talk little nooblet.
MonoTouch is not a runtime or an "app", it's a library with which you compile your own apps. It's ahead-of-time compiled, so you end up with a binary that runs on the iPhone.
It opens up iPhone development for millions of .NET developers, many of which may not have any interest in Objective C. And as far as I can tell, C#/Mono is garbage collected, and Objective C (on the iPhone) is not. That alone would make me interested in checking it out.
If you're not interested, that's great, move along.
:P
.net runtime (mono) on the iPhone. Can we safely assume that the plethora of mono apps can be ported? (http://www.mono-project.com/Software)
Okay, so now we have a
Hmm - I could see playing Donkey.NET (http://www.microsoft.com/downloads/details.aspx?FamilyID=990D0EC1-23EA-4408-898D-1FD5727A8890&displaylang=en) playing on the iPhone.
The Kai's Semi-Updated Website Thingy
Managed Extensions to C++ is old. .NET have C++/CLI now.
Newer versions of
C++/CLI is great for interop with legacy applications that will not interop via web services or COM. .Net class libraries I wrote in C#. In this c++/CLI library, I exported functions as C functions using the stdlib calling convention. This allowed a lot of legacy applications on Windows to interop with .net libraries.
I created a wrapper library in C++/CLI that wrapped
I seem to recall that Mono is/was justified by Miguel de Icaza by virtue of .Nets inevitable popularity (Linux distros would _need_ it). When I read this article I can't help but think that the motivation here is to help make .Net more popular, and by extension, Mono more popular. I already abandoned Gnome, but I won't be surprised when I'm eventually trapped into installing Mono. .Net, C#, Java, I can't point to technical deficiencies and say "That's why I don't like them," but I have _never_ liked an app written in one of those languages. Buggy dependency ridden crapware has been my experience. I realize that an applications overall suckiness isn't necessarily a reflection of the language, but experience has set that expectation for me.
I really hope this project goes nowhere, because the last thing I want is more .Net apps in the world, on any platform.
Samsung took back my unlocked bootloader because Google wants me to rent movies. They're both evil.
Novell may have "announced" this, but I don't think there's much chance of it appearing on the iPhone anytime soon. Sun tried to write a JRE for the iPhone and Apple todl them outright there was no way it was going to allow it, so I seriously double they'd be fine with .Net
Correct me if I'm wrong, but although Mono is largely based around C# it does support other languages such as IronPython, VB.NET, and Boo, and the MonoTouch website implies that you can use other languages as well. That could potentially mean being able to use MonoTouch to write applications in these other languages, which could be handy.
I have had the JVM crap out on me multiple times when programming in JAVA- I have never encountered a failure or SINGLE runtime bug in .NET.
love is just extroverted narcissism
You still need a Mac with OSX and the iPhone SDK and be a registered iPhone developer in order to use Mono-Touch. So if anything, apple will be getting a larger developer base.
"I'm just exhausted 'cause I've been up all night drinking." - Peter Griffin
Haha! That's a good one. Although I'm sure the developers of the 250 games that have shipped with Unity probably care somewhat. :)
Are you being double-backwards redundantly hilarious? .Net and Microsoft are stable now. Let's see on what platforms the largest growth for remote exploits over the last year have been, shall we?
The advantage of mono-touch would be that it allows C# programmers to write iphone apps without having to learn objective C
That is not an advantage. Go native, or don't bother.
-jcr
The only title of honor that a tyrant can grant is "Enemy of the State."
I think you may be prejudiced by your previous experience.
If his position is based on experience, then by definition it's not prejudice.
-jcr
The only title of honor that a tyrant can grant is "Enemy of the State."
You said  C# and .NET which allows any language to compile to the CLI assembly are arguably even more powerful than Java right now Â
Wrong, "any" language can not compile to CLI. Any .net language flavor can. There is a huge difference, when you code VB on .net, this is no more VB but an ersatz of C# : same structure, same paradigms, same API. Same for Cobol.net ... this is not Cobol my friend ! By the way when working on .net everybody ends up doing C#. Like everybody does it on Windows thru the .net and not Mono ... and people ends up doing MS SQL Server sometimes ;)
About C# beeing "more powerfull", this remember a "I got a bigger one than yours" story so I am not even discussing the question. The question is not the size or power, but how clean it is and what you do with it. At the end of the day, most people think theirs are the more powerfull ;-)
About lang, there half a dozen of language that could blast C# and Java in each of their alleged "power" domains. But none are used and none have reached the masses.
If C# was not made by MS, it would have already died, because the clone is too close from the original to survive.
But fortunatly for you MS is still spending some cash and giving some to Novell to try to make people dream of an hypothethical .net outside an MS OS.
Guys, wake up : this will never happen for obious strategical reasons. Do you think that MS will kill windows biggest platform advantage for nothing ? C'm'on, MS does cool things but this whole .net story is realy a self-trap for MS : they did not managed to lock Java (remember the JDirect/RNI/WFC) and could not let it go alone or it could have swallow all their developers (do you liked MFC ?)... so they decided to go the dolly way : go & clone that thing :)
Now they are in a no-no situation : no, we can not make it really cross platform and no we can not get rid of it. Funny situation isn't it ?
I would really like to know how this would end : portability and windows killed or .net killed by MS to prevent harm to Windows... who knows ;)
I miss Explorer.exe and hdll so much...
I have been programming games in unity which uses mono for the iphone for over 6 mos now. Since it compiles to
native code it runs blistering fast and is very stable. No there is not a problem with violating the apple sdk requirements
as it is compiling to native code.
Got Code?
That's only one definition of prejudice. Another is: "Irrational suspicion or hatred of a particular group, race, or religion
Picking up on the context of the discussion at hand isn't your long suit, I take it?
-jcr
The only title of honor that a tyrant can grant is "Enemy of the State."
"Guys, if you need to make iPhone apps, you got to build it using ObjectiveC"
Those games I have been programming and distributing using mono C# in Unity for the last 6 mos must be a figment of my imagination.
Got Code?
That is not an advantage.
Yes it is.
Or do you want to have an actual discussion? Why isn't it an advantage?
Go native, or don't bother.
Why?
Don't thank God, thank a doctor!
They do not want third party apps using fourth party libraries using Nth party foo on their platform.
Uhm... Why not?
Code reuse and the deployment implementation are completely separate issues.
Except that they tend to avoid even apps which have had some of their code generated by a third-party tool, so it seems that "deployment implementation" or not, Apple's policy is effectively blocking some forms of code re-use, for no good reason.
Don't thank God, thank a doctor!
According to this http://monotouch.net/Documentation/Debugging There is virtually no debugging support for developing C# application on MAC OS X. No breakpoints and only Console.Writelines !!!!
Hey, if you want to use half-assed ports, knock yourself out.
-jcr
The only title of honor that a tyrant can grant is "Enemy of the State."
half-assed ports
And why does another implementation language automatically imply half-assed ports?
Your ignorance is showing.
Don't thank God, thank a doctor!
Uhm... Why not?
Because using application bundles avoids DLL hell.
They don't care if you use QT in your app. They just don't want people linking outside of their tree.
After all, I am strangely colored.
Because using application bundles avoids DLL hell.
There are other, more efficient ways to avoid DLL hell. And while that may make sense on a desktop, it seems truly moronic on a mobile platform, where space, bandwidth, and RAM are scarce.
They don't care if you use QT in your app.
Some of the rejection stories coming out suggest otherwise -- that they dislike any "external framework".
Don't thank God, thank a doctor!
Uhm... Why not?
Because that leads to dependency hell, and that leads to horrible user experience.
Apple doesn't really want a larger developer base. If they did, they'd release an SDK and allow development on Windows and Linux.
It's not a port. It's a language binding. There's really not much difference between this and calling your system's open() syscall from Ruby or Python. Also, quit being an asshole.
Mono has always been very up front about the incompatibilities that exist. And whenever you're building AOT applications you have to expect that certain features (like Reflection) will not work. So who cares? It's still a fantastic platform.
isn't this sort of like putting ketchup on chocolate cake?
"Yeah, but can it run Windows?"
"Most people, I think, don't even know what a rootkit is, so why should they care about it?"
Because that leads to dependency hell, and that leads to horrible user experience.
Hurry, better tell Valve! And maybe Microsoft, too, while you're at it! Or Apple, for that matter -- they love frameworks, as long as it's one they shipped with the OS.
Seriously, Linux has solved this dependency issue with package managers for decades. Contrary to popular belief, it's trivial to support multiple versions of a library. And with the App Store, no one can claim installation as a problem -- the App Store can easily be thought of as a package manager that only supports the official Apple repository.
Don't thank God, thank a doctor!
Let me clarify how this works:
1. Yes, it is compiled ahead-of-time so there is no violation of the iPhone Developer SDK ToS rules; this also means a lot of the powerful Reflection stuff doesn't work because you can't do runtime inquiry on a type and create an instance dynamically. It also means the DLR is unlikely to ever run on the iPhone.
2. Much of the types map to Objective-C types, UI Kit, etc, and so does the only GUI library. (Note that types like System.String map to NSString, etc as well.)
You actually still do your GUI in Interface Builder, but MonoDevelop picks up changes to the XIB and auto-generates partial classes to represent the XIB actions and outlets. This step alone eliminates a lot of the boilerplate crap you have to do with Xcode that we Visual Studio developers are used to having the computer take care of automatically. Events can be handled via the C# obj.Event += handler syntax, MonoTouch takes care of hooking it up behind the scenes.
3. You can import Apple frameworks with DllImport and call any of the Foundation functions. There are also helpers that take handles (pointers) from those functions to Objective-C objects.
4. Most of the glue is automatic by decorating your classes/methods with the proper attributes (eg: make a class implement a protocol, then mark the methods as to what message in the protocol it handles). It really is a very slick package and a joy to use.
5. Garbage Collection! This rocks, it was very disappointing to see Apple fail to bring their GC over to the iPhone.
6. Most of your libraries aren't going to work because they require reflection, framework classes, etc that don't exist or aren't statically linkable into your executable. Besides, that isn't the point. For me, the point is to use a language I am used to (avoiding the @synthesize, -/+, and [[[[[[[ crap that makes Objective-C annoying to use). It is impossible to overstate how much the automatic hookup with XIB files makes developing a GUI so much easier to do. I only wish IB would automatically make all controls Outlets, then I'd be set. I find that you spend way too much time spitting out boilerplate code and doing repetitive boilerplate actions in IB when the computer could just as easily figure all that out for me (like Visual Studio does with a WinForms app).
Natural != (nontoxic || beneficial)
And why does another implementation language automatically imply half-assed ports?
It shows that the implementor is unwilling to learn.
Your ignorance is showing.
No, that's my experience. I've seen quite a few half-assed ports to the Mac in my time, and I sure as hell don't want to see them on the iPhone.
-jcr
The only title of honor that a tyrant can grant is "Enemy of the State."
It's not a port. It's a language binding.
It's a language binding that will be used by people who are unwilling to write native iPhone apps. IOW, it will facilitate half-assed ports.
-jcr
The only title of honor that a tyrant can grant is "Enemy of the State."
OMG, no... Actually, C# is way more better than Objective-C by syntax. But I would be much more happy to see Java instead of Mono.
$399 and no trial version and even not Cocoa interface and no Cocoa result? How much does it takes memory? How much time it needs to start?..
Nah, no. I'd better continue with what I already have: Objective-C SDK from Apple.
All in all, I think this is rather nifty. I love C#. I wonder if Apple will allow these apps to be deployed through the app store? I wonder if the SDK has all of the available functionality that is exposed by Apple's SDK.
This comment is my opinion and does not represent an official position of Donald Trump or others I do not work for
Excuse me? C# and .NET take the same approach as Java which is to provide the most powerful general purpose programming language + massive class library of common functionality possible
NeXT was taking that same approach probably before you were even programming.
The Objective-C language itself is not quite as modern as newer languages (though I personally think with blocks and GC it's pretty much there, though those will take a bit to translate over to the iPhone). But Objective-C has a huge set of libraries as well.
I've done extensive Java development prior to switching to iPhone development full time. Really there's not anything missing when you look across the NS and CF class libraries - rich collection classes, string handling with deep unicode support, internationalization, complex date/time formatting, good tools for introspection, RegEx support, etc. etc. etc.
A few of the Mac frameworks are curiously missing for the iPhone (the most curious to me being the one supporting SOAP) but there are good quality third party wrappers that fill those gaps.
And then of course, Objective-C has really useful frameworks like CoreData, and CoreAnimation which are richer than what you can get with other platforms (party because CoreData does not make the pretense at being an OR mapper, just a tool for managing object graphs that happens to support a database as one kind of store). I would say the existence of some of these frameworks especially makes it more useful and productive for application development than either C# or Java currently - especially since after using decades of different UI coding models, Interface Builder is the first IDE GUI development tool it makes sense to use over hand coding elements.
"There is more worth loving than we have strength to love." - Brian Jay Stanley
But the problem is, Apple has explicitly disallowed "frameworks"
That is absurd. There are a ton of different frameworks in play today, from Cocos2D (game framework) to Unity (commercial game framework that supports scripting in Mono or Javascript) to even the C64 emulator...
Apple disallows interpreters, and even that they are somewhat relaxing with the C64 thing. But they've never disallowed Frameworks - that would be basically impossible since they just get an executable they test!
"There is more worth loving than we have strength to love." - Brian Jay Stanley
If this was an HTML5 target the app would not require Apple's approval to run on the iPhone, and it would also run on other platforms. This could be a target that makes an app to run on all smartphones, since they all have WebKit.
If these apps look generic they won't get approved for App Store. You have to design your way into app Store as well as engineer. With HTML5 you can do what you please.
There's no support yet.
Hmnn as a developer, which of these could you live without: Garbage collection or breakpoints? Wow, that sounds like the subject of a new geeky flamewar.
Copyright infringement is "piracy" in the same way DRM is "consumer rape"
Everything being an outlet sounds rather unpleasant to me. I almost never want outlets for controls because usually I'm just wiring actions to them. I need outlets for some elements to set values (like labels and so on) but I wouldn't want every container view to automatically have an outlet... it seems to me like you are programming against the model a bit there.
Making things easier is the presence of things like macros/user scripts in objective C that take care of boilerplate for you.
"There is more worth loving than we have strength to love." - Brian Jay Stanley
May I question why don't they use AOT for the Mono apps inside Linux distros?
Copyright infringement is "piracy" in the same way DRM is "consumer rape"
Would that be codefungus, the asshole?
Now wash your hands.
You still a Mac to develop this. It is very specific to the iPhone. The delegate model closely mimics the Objective C libraries. You still need to pay the Apple developer license for testing and deployment. It still uses XCode (which is free). It costs a few thousand dollars for the enterprise version in addition to the Apple fees.
He's the first person I've heard of bringing the old art of doublethink to perfection, being both a Microsoft shill and Linux developer...
Your posts are usually good, but here you're just trolling. It should be obvious even to you as an Mac developer that there are far more people developing in C# than in ObjC. The iPhone is becoming popular in large enterprises and some of those might like to develop in house apps, and not having to hire ObjC developers or retrain staff saves money, and in the current financial climate that is very important.
I don't think MonoTouch is meant for your average newbie with his first Mac and XCode in front of him. For one it's kind of expensive for that.
Stop fucking trolling, man. Really. You're just speculating and you're sounding scared, that's all.
[citation needed]
I can give you one reason to hate them - bloat. There was a recent case where VMWare changed their small, lightweight GUI console to a web-based one written in Java that required installation using Tomcat.
As people rightly pointed out, this thing took up 500Mb RAM, that's enough to run another VM guest. People were not happy. This is the reason I dislike those framework apps, there's too much required just to get the smallest little application running.
This doesn't count the actual memory usage of apps written in the languages, its not so much a language failing as a design intention. You have a GC, you're told (and the frameworks use it a lot) to use memory as much as you like, throw it away when you're finished with it and the framework will tidy up after you. Obviously this has the effect of requiring much more memory in use at any time. It may be easier to program in, but its not easier on the end-user computer.
There's a few more bits that relate to 'making things easier and safer' for the programmer, which end up costing CPU and RAM, which are equally good reasons to dislike the languages/frameworks.
'Suckiness' is just a common subjective view, the above is more objective reason to hate the useless crap :)
If you call compiled Objective-C interpreted... Monotouch will convert mono-style C# to Objective-C and then compile it.
If by "yet" you mean Mono released in 2004 and it still cannot be debugged on MAC OS X and lately iphone, you are correct Raj
Never, a Libertarian is just a greedball Republican who smokes pot.
Tired of all the isms, don't exploit people as an employer, or a government, mmmmK?
I think you may be prejudiced by your previous experience.
If his position is based on experience, then by definition it's not prejudice.
You are completely wrong. Prejudice is prejudging a person or thing. If I experience watching a news program where an african american punches a cop, and then the next time I meet an african american I conclude that african american is likely dangerous and violent, I've pre judged them by taking a correlation (well one data point) and assigning a causation.
An experience can lead to a person prejudging based upon illogical assumptions about said experience. Just because you've had an experience involving elm trees doesn't mean you can accurately predict everything that will happen around some other elm tree. That is prejudice based upon experience.
I remember listening to a podcast a few weeks ago where it was stated that the nature of the compilation is such that some of the more dynamic languages (like python) would not work using this system.
"There is more worth loving than we have strength to love." - Brian Jay Stanley
It shows that the implementor is unwilling to learn.
Wow. So you just admitted my other point, that is, that another implementation language automatically implies half-assed ports.
Is that really what you meant?
No, that's my experience.
In your experience, you've never seen a good port, or a good Mac app developed using a third-party framework?
I sure as hell don't want to see them on the iPhone.
You'd rather not have an app at all than have a half-assed port?
And I sure as hell prefer to have choices of implementation language, even if others might develop it, then be forced back a decade or so in language development to use Objective C when there are better choices available.
Don't thank God, thank a doctor!
I'm not sure what you're arguing against. Apps can include local copies of frameworks just fine on the app store, and the iPhone OS provides frameworks that apps use. It wouldn't work at all without those.
What is specifically not allowed is using external frameworks distributed separately, or internal OS frameworks.
 Mono has always been very up front about the incompatibilities that exist. Â
Having good will to follow a road runner does not mean are acutally catching it.
In other words, there are no proof that it is fully compatible.
IE, you can spend your hobby time on it but you'd better never bet a whole businessplan :(
This comment also applies to any other reimplementation without all the specs (think to Wine for instance).
As said on the original comment, it is MS choice not to have full open the platform but a core and not have brought a TCK. This is maybe their best strategical choice to prevent Windows to suffer from Mono ;)
external frameworks distributed separately,
Sounds like at least one very misleading rejection. The author I mentioned had an "it's an external framework" rejection about their generated app -- which very clearly wasn't relying on any external framework installed on the device, only one to use the generated code -- when what they meant was "you're using an internal framework."
Add to this the fact that they rejected an app that contained the name of the framework, but accepted the exact same app with that name replaced with something else.
Don't thank God, thank a doctor!
You'd rather not have an app at all than have a half-assed port?
Have you ever seen OpenOffice on the Mac? I rest my case.
-jcr
The only title of honor that a tyrant can grant is "Enemy of the State."
2. What developer in their right mind would write apps for the freaking iPhone?
Then we'll have to agree to disagree.
Back when I had a Mac, I much preferred having NeoOffice to having nothing but TextEdit. That's kind of a no-brainer.
Don't thank God, thank a doctor!
I went and bought Downhill Bowling which uses the unity 3D flavor of Mono, and the launch time is reasonably peppy at launch, taking 12 seconds on my iPhone 3G to the point at which I could press a button, which is about the same for the non-Mono Madden 2010..
Greetings Apple FUD machine!
For a site about things like basic rights, Slashdot users sure do like to censor "dissent".
Mac and former NeXT users completely ignoring all of Apple's failings
Excuse me? I've been very frank about Apple's failings. They kept Carbon going for way too long, for one.
-jcr
The only title of honor that a tyrant can grant is "Enemy of the State."
Taste isn't for everybody.
Nor is common courtesy, obviously.
There has never been a time when those were your only two options.
What would you suggest?
Don't thank God, thank a doctor!
Which makes me wonder even more where the $399 is going for the personal developer edition....unless they're offering updates and support en perpetuetum.... I could understand $99.......but $399.......what in the heck is De Icaza puffing ?
There are other, more efficient ways to avoid DLL hell. And while that may make sense on a desktop, it seems truly moronic on a mobile platform, where space, bandwidth, and RAM are scarce.
Space is scarce? Really? Do you think 80 or 100MB of QT are going to fill up a 16 GB drive? Do you think 30 or 50 QT applications are going to fill up a 16 GB drive, even if they all bring their own QT libs?
Apple has already chosen their way of avoiding DLL hell, and it doesn't include a package manager for dealing with random application libraries.
Some of the rejection stories coming out suggest otherwise -- that they dislike any "external framework".
It's not "external" if it's in your app. You can link to any library you want, as long as you include a copy of it in your application bundle.
After all, I am strangely colored.
Apple has already chosen their way of avoiding DLL hell,
It is, however, neither the only nor the most efficient way of avoiding DLL hell.
If nothing else, it's a bit more delay and an unnecessary waste of battery if those Qt libs have to be loaded from that drive with each app -- to say nothing of if Apple ever allowed background apps.
It's not "external" if it's in your app.
Better hope Apple interprets it the same way. Or, assume that the person Apple has reviewing your app interprets it the same way. Because they've definitely filtered out individual apps by targeting specific frameworks.
Don't thank God, thank a doctor!