12-15-2011 09:26 PM - edited 12-15-2011 09:33 PM
I'm trying to use the nativepackager to build the AccelerometerSampleMakefile project, however I keep getting this error about the entry point:
Error: Attribute Entry-Point: file cannot be found in the list of packaged files: AccelerometerSampleMakefile
I am parsing the bar-descriptor.xml to go through and copy the list of assets, and I am making sure to include the active configuration asset as well (which is just the binary). I copy all the assets into folder 'generated-resources' and then run this command:
blackberry-nativepackager -package AccelerometerSampleMakefi.bar bar-descriptor.xml -e generated-resources .
If I replace the "-e generated-resources ." with "-C generated-resources" I get this error:
Error: !Invalid asset path "NOTICE"!
The examples in the blackberry-nativepackager docs show the entry-point binary being listed first. If I do that nothing changes. Just to reiterate, the binary is under the generated-resources directory along with all the other assets listed in the bar-descriptor.xml.
(Sorry for any typos, I'm on a phone right now)
Solved! Go to Solution.
12-16-2011 10:39 AM
Can you give me full command line? -e option requires two arguments - local path then bar assest path.
When you specify entry point you specify it by bar asset path, if path does not match - it cannot find entry point
For example if you project looks like
You can package it like this
blackberry-nativepackager -package out.bar -devMode mydir/bar-descriptor.xml -C mydir/ -e mydir/arm/mybinary mybinary icon.png
Actually better to specify all your files in the xml
<asset path="arm/mybinary" entry="true">mybinary</asset>
Then just bar bar-descriptor.xml to the packager (assuming you curdir is mydir)
12-16-2011 12:19 PM - edited 12-16-2011 02:02 PM
The second argument for the -e is a period (.), which used to work when I originally used it with the airpackager, but maybe it has changed.
Regardless, I think the issue is that the assets are in the bar-descriptor.xml like you mentioned, however the bar-descriptor.xml is not in the same directory as the actual files. So if I understand correctly, anything listed as an asset in the bar-descriptor.xml will be automatically included, and I don't need to add them to the command line...
Edit: I can try this out later or tomorrow and report back.
12-17-2011 05:29 PM
When I don't include the files in the command line, I get this error:
Error: Unable to resolve path variable "QNX_TARGET"
The command line is:
blackberry-nativepackager -package target/AccelerometerSampleMakefi.bar bar-descriptor.xml
The issue is with this asset path:
Is there a way to pass variables into the nativepackager, or am I going to have to populate a copy of the bar-descriptor.xml myself?
12-19-2011 02:09 PM
K, I'll give that a shot.
How about selecting the active configuration through id or name?
<configuration id="com.qnx.qcc.toolChain.443564715" name="Default"> <platformArchitecture>armle-v7</platformArchitectu
re> <asset path="arm/o.le-v7-g/AccelerometerSampleMakefile" entry="true" type="Qnx/Elf">AccelerometerSampleMakefile</asset> </configuration> <configuration id="com.qnx.qcc.toolChain.1231044190" name="Device-Debug"> <platformArchitecture>armle-v7</platformArchitectu re> <asset path="arm/o.le-v7-g/AccelerometerSampleMakefile" entry="true" type="Qnx/Elf">AccelerometerSampleMakefile</asset> </configuration> <configuration id="com.qnx.qcc.toolChain.984880167" name="Device-Release"> <platformArchitecture>armle-v7</platformArchitectu re> <asset path="arm/o.le-v7/AccelerometerSampleMakefile" entry="true" type="Qnx/Elf">AccelerometerSampleMakefile</asset> </configuration> <configuration id="com.qnx.qcc.toolChain.2004874297" name="Simulator"> <platformArchitecture>x86</platformArchitecture> <asset path="x86/o-g/AccelerometerSampleMakefile" entry="true" type="Qnx/Elf">AccelerometerSampleMakefile</asset> </configuration>
12-19-2011 02:15 PM - edited 12-19-2011 02:15 PM
Normally I would just get all these settings from the Eclipse output... but I can't package the NDK samples in momentics. When i select export as a release build, I just get this error:
Export failed. java.lang.reflect.InvocationTargetException
12-19-2011 02:24 PM
to package specific configuration you add -configuration "Device-Debug"
or simimar to options list of packager
For the other error I don't have enought info, I would need full ide log (.log file in workspace)
12-19-2011 03:20 PM - edited 12-19-2011 09:39 PM
Oh you know what, all of these are under -help-advanced. I didn't notice there was a second level of hidden args available.
I'll try to add the other error to JIRA.
Edit: The -D and -configuration worked. Thanks again!
12-19-2011 09:35 PM - edited 12-19-2011 09:37 PM