Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » DSDP - Real-Time Software Components (RTSC) » prog.build.target.findSuffix(pkg) returns NULL!?
prog.build.target.findSuffix(pkg) returns NULL!? [message #529068] Thu, 22 April 2010 19:43 Go to next message
Patrick Geremia is currently offline Patrick GeremiaFriend
Messages: 79
Registered: July 2009
Member
All,

I got a weird problem with one of my packages. The line
var suffix = prog.build.target.findSuffix(pkg);
returns null. Is there any explanation?

------------------------------------------------------------ ------------
function getLibs( prog )
{
var pkg = this;
var Settings = pkg.Settings;

var suffix = prog.build.target.findSuffix(pkg); <---- returns NULL!?
var suffix = prog.build.target.suffix;
var assertFlag;
var debugFlag;
var traceFlag;
var racType;
......
------------------------------------------------------------ ------------

--
Patrick Geremia
Texas Instruments (http://www.ti.com)
Phone: +33 4 93 22 26 33
Email: p-geremia@ti.com
Availability: http://meetwith.me/patrickgeremia
Re: prog.build.target.findSuffix(pkg) returns NULL!? [message #529071 is a reply to message #529068] Thu, 22 April 2010 19:59 Go to previous messageGo to next message
Sasha Slijepcevic is currently offline Sasha SlijepcevicFriend
Messages: 115
Registered: July 2009
Senior Member
Here is the doc:
http://www.sanb.design.ti.com/iliad/webhome/xdoc/xdc/bld/ITa rget.html#find.Suffix

It returns null if the parameter 'pkg' does not support any target compatible with the build target.

Here is more info about how to write getLibs(), where findSuffix() is usually invoked:
http://rtsc.eclipse.org/docs-tip/Writing_getLibs%28%29
Re: prog.build.target.findSuffix(pkg) returns NULL!? [message #529160 is a reply to message #529071] Fri, 23 April 2010 08:49 Go to previous messageGo to next message
Patrick Geremia is currently offline Patrick GeremiaFriend
Messages: 79
Registered: July 2009
Member
This is a multi-part message in MIME format.
--------------080808020604000705080407
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit

-------- Original Message --------
Subject: Re: prog.build.target.findSuffix(pkg) returns NULL!?
From: Sasha Slijepcevic <sascha@ti.com>
To:
Date: Thu Apr 22 2010 21:59:32 GMT+0200 (CEST)

> Here is the doc:
> http://www.sanb.design.ti.com/iliad/webhome/xdoc/xdc/bld/ITa rget.html#find.Suffix
>
>
> It returns null if the parameter 'pkg' does not support any target
> compatible with the build target.
>
> Here is more info about how to write getLibs(), where findSuffix() is
> usually invoked:
> http://rtsc.eclipse.org/docs-tip/Writing_getLibs%28%29

I think I followed the documentation. What is weird is that it works
fine for other packages where the getLibs() implementation is exactly
the same.

I am attaching my package.xs file.



--------------080808020604000705080407
Content-Type: text/plain;
name="package.xs"
Content-Transfer-Encoding: base64
Content-Disposition: inline;
filename="package.xs"

ZnVuY3Rpb24gZ2V0TGlicyggcHJvZyApCnsKICAgIHZhciBwa2cgPSB0aGlz OwogICAgdmFy
IFNldHRpbmdzID0gcGtnLlNldHRpbmdzOwogCiAgICB2YXIgc3VmZml4ID0g cHJvZy5idWls
ZC50YXJnZXQuZmluZFN1ZmZpeChwa2cpOyAvKiByZXR1cm5zIE5VTEwgISEh ISEgV0hZICov
CiAgICBwcmludChzdWZmaXgpOwogICAgdmFyIHN1ZmZpeCA9IHByb2cuYnVp bGQudGFyZ2V0
LnN1ZmZpeDsgCiAgICBwcmludChzdWZmaXgpOwogICAgdmFyIGFzc2VydEZs YWc7CiAgICB2
YXIgZGVidWdGbGFnOwogICAgdmFyIHRyYWNlRmxhZzsKICAgIHZhciByYWNU eXBlOwogCiAg
ICBzd2l0Y2ggKFNldHRpbmdzLmFzc2VydEZsYWcpIAogICAgewogICAgICAg IGNhc2UgU2V0
dGluZ3MuQVNTRVJUX09OOgogICAgICAgICAgICBhc3NlcnRGbGFnID0gImFz c2VydF9vbiI7
CiAgICAgICAgICAgIGJyZWFrOwogICAgICAgIGNhc2UgU2V0dGluZ3MuQVNT RVJUX09GRjoK
ICAgICAgICAgICAgYXNzZXJ0RmxhZyA9ICJhc3NlcnRfb2ZmIjsKICAgICAg ICAgICAgYnJl
YWs7CiAgICB9CiAgICBzd2l0Y2ggKFNldHRpbmdzLnRyYWNlRmxhZykgCiAg ICB7CiAgICAg
ICAgY2FzZSBTZXR0aW5ncy5UUkFDRV9PTjoKICAgICAgICAgICAgdHJhY2VG bGFnID0gInRy
YWNlX29uIjsKICAgICAgICAgICAgYnJlYWs7CiAgICAgICAgY2FzZSBTZXR0 aW5ncy5UUkFD
RV9PRkY6CiAgICAgICAgICAgIHRyYWNlRmxhZyA9ICJ0cmFjZV9vZmYiOwog ICAgICAgICAg
ICBicmVhazsKICAgIH0KICAgIHN3aXRjaCAoU2V0dGluZ3MuZGVidWdGbGFn KSAKICAgIHsK
ICAgICAgICBjYXNlIFNldHRpbmdzLkRFQlVHOgogICAgICAgICAgICBkZWJ1 Z0ZsYWcgPSAi
ZGVidWciOwogICAgICAgICAgICBicmVhazsKICAgICAgICBjYXNlIFNldHRp bmdzLlJFTEVB
U0U6CiAgICAgICAgICAgIGRlYnVnRmxhZyA9ICJyZWxlYXNlIjsKICAgICAg ICAgICAgYnJl
YWs7CiAgICB9CiAgICBzd2l0Y2ggKFNldHRpbmdzLnJhY1R5cGUpIAogICAg ewogICAgICAg
IGNhc2UgU2V0dGluZ3MuRkFSQURBWToKICAgICAgICAgICAgcmFjVHlwZSA9 ICJmYXJhZGF5
IjsKICAgICAgICAgICAgYnJlYWs7CiAgICAgICAgY2FzZSBTZXR0aW5ncy5O WVFVSVNUOgog
ICAgICAgICAgICByYWNUeXBlID0gIm55cXVpc3QiOwogICAgICAgICAgICBi cmVhazsKICAg
IH0KCiAgICBpZiAoc3VmZml4KSAKICAgIHsKICAgICAgICByZXR1cm4gcGtn LiRuYW1lLnJl
cGxhY2UoL1wuL2csICJfIikgKyAiXyIgKyByYWNUeXBlICsgIl8iICsgYXNz ZXJ0RmxhZyAr
ICJfIiArIHRyYWNlRmxhZyArICJfIiArICBkZWJ1Z0ZsYWcgKyAgIl8iICsg c3VmZml4ICsg
Ii5hIiArIHN1ZmZpeDsKICAgIH0KICAgIGVsc2UgCiAgICB7CiAgICAgICAg cmV0dXJuIG51
bGw7CiAgICB9Cn0K
--------------080808020604000705080407--
Re: prog.build.target.findSuffix(pkg) returns NULL!? [message #529161 is a reply to message #529071] Fri, 23 April 2010 08:49 Go to previous message
Patrick Geremia is currently offline Patrick GeremiaFriend
Messages: 79
Registered: July 2009
Member
This is a multi-part message in MIME format.
--------------040200050507080604020908
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit

-------- Original Message --------
Subject: Re: prog.build.target.findSuffix(pkg) returns NULL!?
From: Sasha Slijepcevic <sascha@ti.com>
To:
Date: Thu Apr 22 2010 21:59:32 GMT+0200 (CEST)

> Here is the doc:
> http://www.sanb.design.ti.com/iliad/webhome/xdoc/xdc/bld/ITa rget.html#find.Suffix
>
>
> It returns null if the parameter 'pkg' does not support any target
> compatible with the build target.
>
> Here is more info about how to write getLibs(), where findSuffix() is
> usually invoked:
> http://rtsc.eclipse.org/docs-tip/Writing_getLibs%28%29

I think I followed the documentation. What is weird is that it works
fine for other packages where the getLibs() implementation is exactly
the same.

I am attaching my package.xs file.



--------------040200050507080604020908
Content-Type: text/plain;
name="package.xs"
Content-Transfer-Encoding: base64
Content-Disposition: inline;
filename="package.xs"

ZnVuY3Rpb24gZ2V0TGlicyggcHJvZyApCnsKICAgIHZhciBwa2cgPSB0aGlz OwogICAgdmFy
IFNldHRpbmdzID0gcGtnLlNldHRpbmdzOwogCiAgICB2YXIgc3VmZml4ID0g cHJvZy5idWls
ZC50YXJnZXQuZmluZFN1ZmZpeChwa2cpOyAvKiByZXR1cm5zIE5VTEwgISEh ISEgV0hZICov
CiAgICBwcmludChzdWZmaXgpOwogICAgdmFyIHN1ZmZpeCA9IHByb2cuYnVp bGQudGFyZ2V0
LnN1ZmZpeDsgCiAgICBwcmludChzdWZmaXgpOwogICAgdmFyIGFzc2VydEZs YWc7CiAgICB2
YXIgZGVidWdGbGFnOwogICAgdmFyIHRyYWNlRmxhZzsKICAgIHZhciByYWNU eXBlOwogCiAg
ICBzd2l0Y2ggKFNldHRpbmdzLmFzc2VydEZsYWcpIAogICAgewogICAgICAg IGNhc2UgU2V0
dGluZ3MuQVNTRVJUX09OOgogICAgICAgICAgICBhc3NlcnRGbGFnID0gImFz c2VydF9vbiI7
CiAgICAgICAgICAgIGJyZWFrOwogICAgICAgIGNhc2UgU2V0dGluZ3MuQVNT RVJUX09GRjoK
ICAgICAgICAgICAgYXNzZXJ0RmxhZyA9ICJhc3NlcnRfb2ZmIjsKICAgICAg ICAgICAgYnJl
YWs7CiAgICB9CiAgICBzd2l0Y2ggKFNldHRpbmdzLnRyYWNlRmxhZykgCiAg ICB7CiAgICAg
ICAgY2FzZSBTZXR0aW5ncy5UUkFDRV9PTjoKICAgICAgICAgICAgdHJhY2VG bGFnID0gInRy
YWNlX29uIjsKICAgICAgICAgICAgYnJlYWs7CiAgICAgICAgY2FzZSBTZXR0 aW5ncy5UUkFD
RV9PRkY6CiAgICAgICAgICAgIHRyYWNlRmxhZyA9ICJ0cmFjZV9vZmYiOwog ICAgICAgICAg
ICBicmVhazsKICAgIH0KICAgIHN3aXRjaCAoU2V0dGluZ3MuZGVidWdGbGFn KSAKICAgIHsK
ICAgICAgICBjYXNlIFNldHRpbmdzLkRFQlVHOgogICAgICAgICAgICBkZWJ1 Z0ZsYWcgPSAi
ZGVidWciOwogICAgICAgICAgICBicmVhazsKICAgICAgICBjYXNlIFNldHRp bmdzLlJFTEVB
U0U6CiAgICAgICAgICAgIGRlYnVnRmxhZyA9ICJyZWxlYXNlIjsKICAgICAg ICAgICAgYnJl
YWs7CiAgICB9CiAgICBzd2l0Y2ggKFNldHRpbmdzLnJhY1R5cGUpIAogICAg ewogICAgICAg
IGNhc2UgU2V0dGluZ3MuRkFSQURBWToKICAgICAgICAgICAgcmFjVHlwZSA9 ICJmYXJhZGF5
IjsKICAgICAgICAgICAgYnJlYWs7CiAgICAgICAgY2FzZSBTZXR0aW5ncy5O WVFVSVNUOgog
ICAgICAgICAgICByYWNUeXBlID0gIm55cXVpc3QiOwogICAgICAgICAgICBi cmVhazsKICAg
IH0KCiAgICBpZiAoc3VmZml4KSAKICAgIHsKICAgICAgICByZXR1cm4gcGtn LiRuYW1lLnJl
cGxhY2UoL1wuL2csICJfIikgKyAiXyIgKyByYWNUeXBlICsgIl8iICsgYXNz ZXJ0RmxhZyAr
ICJfIiArIHRyYWNlRmxhZyArICJfIiArICBkZWJ1Z0ZsYWcgKyAgIl8iICsg c3VmZml4ICsg
Ii5hIiArIHN1ZmZpeDsKICAgIH0KICAgIGVsc2UgCiAgICB7CiAgICAgICAg cmV0dXJuIG51
bGw7CiAgICB9Cn0K
--------------040200050507080604020908--
Previous Topic:Diags.setMaskMeta
Next Topic:not able to add an executable to a release
Goto Forum:
  


Current Time: Fri Mar 29 11:51:43 GMT 2024

Powered by FUDForum. Page generated in 0.02284 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top