« Back to Technical Questions

parser error during ../axp-sdk.1.6.1/tools/pkg_bundle.sh

Combination View Flat View Tree View
parser error during ../axp-sdk.1.6.1/tools/pkg_bundle.sh
bash pkg_build pkg_bundle pkg_info bundle package parse error
Answer
2/8/11 7:49 AM
I'm using AXP SDK 1.6.1 to bundle my application and facing the following issue.
 
[sangeeth@sangeeth-desktop bundle]$
[sangeeth@sangeeth-desktop bundle]$ ../axp-sdk.1.6.1/tools/pkg_bundle.sh \
> --project-dir   '/home/sangeeth/xxxxxxx/bundle' \
> --private-key   '/home/sangeeth/xxxxxxx/build/cert/private.key' \> --output        'sanapp-sre-bundle.1.0.pkg' \
> '/home/sangeeth/xxxxxxx/build/output/pkg/sanapp.1.0.pkg' \
> '/home/sangeeth/xxxxxxx/axp-k9.sme.1.6.1.tar.gz'
SLIM Bundling Utility. (C) 2007-2010 Cisco Systems, Inc
Checking dependencies...
Creating project directories...
Output files will be stored in: /home/sangeeth/xxxxxxx/bundle/pkg
Checking for duplicate applications and old AXP add-ons...
/home/sangeeth/xxxxxxx/axp-sdk.1.6.1/lib/pkg/scripts/readpkglist.sh: line 22: [: too many arguments
/home/sangeeth/xxxxxxx/axp-sdk.1.6.1/lib/pkg/scripts/readpkglist.sh: line 22: [: too many arguments
/home/sangeeth/xxxxxxx/axp-sdk.1.6.1/lib/pkg/scripts/readpkglist.sh: line 28: [: ?T?: binary operator expected
/home/sangeeth/xxxxxxx/axp-sdk.1.6.1/lib/pkg/scripts/readpkglist.sh: line 22: [: ???y¿m??¿?*Csw?X^u)G??1?@U??u?6`S,??'9hZRwN??L8?ZM??SY
                                                                                                                                         }D?¿¿??
?G?0?x??W???;1: binary operator expected
/home/sangeeth/xxxxxxx/axp-sdk.1.6.1/lib/pkg/scripts/readpkglist.sh: line 22: [: too many arguments
/home/sangeeth/xxxxxxx/axp-sdk.1.6.1/lib/pkg/scripts/readpkglist.sh: line 22: [: ???: binary operator expected
/home/sangeeth/xxxxxxx/axp-sdk.1.6.1/lib/pkg/scripts/extract_pkg_file.sh: line 69: [: ?T?: binary operator expected
pkg_bundle.sh: Invalid manifest file header. Tried to read () bytes of data
 
gzip: stdin: unexpected end of file
pkg_bundle.sh: Unable to extract XML data from /home/sangeeth/xxxxxxx/axp-k9.sme.1.6.1.tar.gz at index 1
-:1: parser error : Document is empty
 
^
-:1: parser error : Start tag expected, '<' not found
 
^
Extracting /home/sangeeth/xxxxxxx/build/output/pkg/sanapp.1.0.pkg to /home/sangeeth/xxxxxxx/bundle/tmp
pkg_bundle.sh: Cannot compare empty version numbers
[sangeeth@sangeeth-desktop bundle]$
[sangeeth@sangeeth-desktop bundle]$
[sangeeth@sangeeth-desktop bundle]$
[sangeeth@sangeeth-desktop bundle]$ ../axp-sdk.1.6.1/tools/pkg_info.sh ../build/output/pkg/sanapp.1.0.pkg
[sangeeth@sangeeth-desktop bundle]$
[sangeeth@sangeeth-desktop bundle]$
[sangeeth@sangeeth-desktop bundle]$ bash -version
GNU bash, version 4.0.38(1)-release (x86_64-redhat-linux-gnu)
Copyright (C) 2009 Free Software Foundation, Inc.License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software; you are free to change and redistribute it.There is NO WARRANTY, to the extent permitted by law.
[sangeeth@sangeeth-desktop bundle]$
[sangeeth@sangeeth-desktop bundle]$

First, I packaged my application using pkg_build.sh and then used pkg_bundle.sh to bundle it with AXP OS (axp-k9.sme.1.6.1.tar.gz). When I used pkg_info.sh on the package (/home/sangeeth/xxxxxxx/build/output/pkg/sanapp.1.0.pkg - output of pkg_build.sh), its showed nothing. Is this an issue?
 
Is there a possibility of corrupted axp-k9.sme.1.6.1.tar.gz? Could you please give me a pointer to the original md5sum for axp-k9.sme.1.6.1.tar.gz?
 
I went through few techinical queries in the AXP forum w.r.t pkg_build and pkg_bundle, I came to know that bash could be a problem. So FYI I'm using bash 4.0.38(1).

I packaged the hello world app using pkg_build.sh successfully and when tried bundling the hello world package using pkg_bundle.sh, I'm hitting the same issue. I browsed through the AXP forum and the AXP developer guide but couldn't find any relevant information about this issue. Could there be any issue with my development environment?
 
TIA

Hi Sangeeth,

please untar axp-k9.sme.1.6.1.tar.gz and provide axp-k9.sme.1.6.1.pkg path instead of '/home/sangeeth/xxxxxxx/axp-k9.sme.1.6.1.tar.gz' to your pkg_bundle.sh command and also make sure that following files are in same directory as axp-k9.sme.1.6.1.pkg file located.

1. axp-helper-k9.sme.1.6.1
2. axp-installer-k9.sme.1.6.1.prt1
3. axp-k9.sme.1.6.1.key
4. axp-k9.sme.1.6.1.pkg
5. axp-k9.sme.1.6.1.pkg.install.sre
6. axp-k9.sme.1.6.1.pkg.install.sre.header
7. axp-k9.sme.1.6.1.prt1
8. axp-timezone.sme.1.6.1.pkg
9. axp-timezone.sme.1.6.1.prt1


Thanks,
Raghavendra

Hi Sangeeth,

please cross check following md5sum values also with your values

f2b53f03fffb4589142a4f72895a119c axp-app-dev.sme.1.6.1.pkg
b32770406b5652f6c9325d74b7be48df axp-app-dev.sme.1.6.1.prt1
a30a4428c16abbaceee23c949e6cd000 axp-helper-k9.sme.1.6.1
436709c8f4b4b75e6aa640b6aa6f9a21 axp-installer-k9.sme.1.6.1.prt1
92cdbfbbcfa26b5a0eb6da32d8d45b22 axp-k9.sme.1.6.1.key
d1a64aae06b54b0411dc7b5ec1180f17 axp-k9.sme.1.6.1.pkg
88f03cfb619c2226780184662f6faf8c axp-k9.sme.1.6.1.pkg.install.sre
bc8b440dd3bd8e5df4dc0efcfda9d0f1 axp-k9.sme.1.6.1.pkg.install.sre.header
8b8fb91e4467c545809a569561999bf9 axp-k9.sme.1.6.1.prt1
1933e1bc0c9214bfcae17b48eb26dfb6 axp-timezone.sme.1.6.1.pkg
85d067746dc83897176432b36fce10f9 axp-timezone.sme.1.6.1.prt1

Thanks,
Raghavendra

Hi Raghavendra,
 
Your help on this is highly appreciated! 
 
I followed your instruction and it worked fine!
 
On a different note: would it be good to have an error flashed when we give axp-k9.sme.1.6.1.tar.gz instead of axp-k9.sme.1.6.1.pkg? Is there a way we can take this enhancement/input-validation request to the AXP team?

Thanks!

Hi Sangeeth,

thank you for your suggestion, we will forward your inputs to the team.

Thanks,
raghavendra