SDK 1.5 - create aidl preprocess file for parcelable

Common bugs/problems with the Android SDK the Emulator and the ADT-Plugin.

SDK 1.5 - create aidl preprocess file for parcelable

Postby puppetmaster » Tue Apr 14, 2009 8:36 am

Hello android developers,

yesterday the early look Android SDK 1.5 has released and i tried to import an "old" project using eclipse. There are some datatypes which has been made parcelable in order to use the datatypes in the aidl. However setting up eclipse for SDK 1.1 gives me the facility to create aidl preprocess file for parcelable. In the new plugin for eclipse i couldn't find this function-call and that seems to be the issue to take if i would like to compile my project (and i will). Could anybody tell me what i am doing wrong or what i have to do to create aidl preprocess file for parcelable. Thanks a lot for your help and hope your egg-hunting on eastern was successful and is delicious..

Posts: 3
Joined: Mon Feb 16, 2009 4:48 pm


Postby Xav » Thu Apr 16, 2009 1:02 am

We've removed the ability to create a single import file for all the parcelable classes you implement in order to make projects compatible with Ant (so that a team of people working both in ADT and Ant can work together).

You will now need to create an aidl file for each class you've created that implements Parcelable.
Placed next to the java class, it should contain the following lines:
Code: Select all
package com.mycompany.myapp;
parcelable MyParcelableClass;

More information available at: ... /aidl.html
(Just ignore the special cases when using ADT as this doc still refers to the old version. The new version behaves like Ant)

Warning: Since releasing 1.5, we have discovered the following issues:
  • Editing an aidl file defining a parcelable does not trigger the recompilation of other aidl files importing this class. You may want to touch those files to force recompiling.
  • The files generated by aild are located in a new source folder called "gen". For aidl files not located inside the default application package, the folders are not properly created and aidl will complain, stopping the build. Create the packages manually under gen/ and it'll work.

We've already fixed both issues and the fixes will be in the final release of ADT 0.9

Android Engineer, Google Inc.
User avatar
Junior Developer
Junior Developer
Posts: 11
Joined: Fri Dec 14, 2007 3:09 am
Location: Mountain View, CA


Return to SDK/ADT/Emulator Problems

Who is online

Users browsing this forum: No registered users and 4 guests