You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@trafficserver.apache.org by "Owens, Steve" <St...@disney.com> on 2013/01/18 21:09:56 UTC

Questions about tsxs

I am experiencing some confusing behaviors trying to use tsxs and the documentation on this tool does not seem to be very complete.

Here is what I am trying to do in a nutshell.

I have plugin file that I want to build and I want to be able to include files from a different directory into the header file such that:

When I put in my JsonPTransformationHandler.h file

#include <events/BaseEventHandler.h>

#include <TransactionData.h>


And I put this in my JsonPTransformationHandler.cc file:

#include "JsonPTransformationHandler.h"

#include <ApiMgmtUtil.h>


I have tried executing the build tool with the following command lines to no avail:

tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin/
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin/

Yet in each and every case when the tool runs it renders the following error messages:
JsonPTransformationHandler.h:13:37: error: events/BaseEventHandler.h: No such file or directory
JsonPTransformationHandler.h:14:29: error: TransactionData.h: No such file or directory
JsonPTransformationHandler.cc:9:25: error: ApiMgmtUtil.h: No such file or directory

Yet the following ls commands hold:
[sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/TransactionData.h
-rw-rw-r-- 1 sowens sowens 7736 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/TransactionData.h
[sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h
-rw-rw-r-- 1 sowens sowens 20232 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h
[sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h
-rw-rw-r-- 1 sowens sowens 1970 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h


So the files are there but tsxs cannot fine them.  Furthermore other than the limited help provided by the –h option on tsxs there is no examples in the ATS web documentation that talks about includes.  Does tsxs support include directories?


Re: Questions about tsxs

Posted by "Owens, Steve" <St...@disney.com>.
Thanks, I ended up doing something simpler  though I like your idea of using TSXS to do the installation.  Being able to write the make file may not fix the root problem but provides an out from not being able to build at all.



From: Geert Lugtenberg <ge...@poort80.nl>>
Reply-To: "users@trafficserver.apache.org<ma...@trafficserver.apache.org>" <us...@trafficserver.apache.org>>
Date: Mon, 21 Jan 2013 00:48:41 -0800
To: "users@trafficserver.apache.org<ma...@trafficserver.apache.org>" <us...@trafficserver.apache.org>>
Subject: RE: Questions about tsxs

How about the following Makefile:


TSXS?=tsxs

all: JsonPTransformationHandler.so

JsonPTransformationHandler: JsonPTransformationHandler.cc <any include files>
                g++ JsonPTransformationHandler.cc -o JsonPTransformationHandler.so –I/home/sowens/ApiMgmtPlugin –L<a library path> -l<a lib file>

install: all
                $(TSXS) -i -o JsonPTransformationHandler.so

clean:
                rm -f *.lo *.so *.o


Where a library path/file(s) are up to you if you need to use any. Does that work for you?

-Geert

From: Owens, Steve [mailto:Steve.Owens@disney.com]
Sent: vrijdag 18 januari 2013 21:37
To: users@trafficserver.apache.org<ma...@trafficserver.apache.org>
Subject: Re: Questions about tsxs

Given that tsxs is broken does anyone know what would be the sequence of commands that it would execute to build the plugin if it were working correctly given the following command line?

tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin


From: "Owens, Steve" <St...@disney.com>>
Reply-To: "users@trafficserver.apache.org<ma...@trafficserver.apache.org>" <us...@trafficserver.apache.org>>
Date: Fri, 18 Jan 2013 12:19:14 -0800
To: "users@trafficserver.apache.org<ma...@trafficserver.apache.org>" <us...@trafficserver.apache.org>>
Subject: Re: Questions about tsxs

Digging into this further I can see that when I invoke:
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin

Tsxs writes the following on the last line of output:
Compile failed: g++ -I/usr/local/include -g -pipe -Wall -Werror -O3 -feliminate-unused-debug-symbols -fno-strict-aliasing -Wno-invalid-offsetof -fpic -c JsonPTransformationHandler.cc -o JsonPTransformationHandler.lo

Yet when I do
tsxs -h

It outputs:
/usr/local/bin/tsxs : a tool to compile, link and install trafficserver plugins.

 compiling/linking:
                -c [ file1.c [ file2.c [ ... ] ] ]      ## compiles C files
                -C [ file1.cc [ file2.C [ ... ] ] ]     ## compiles C++ files
                -o modulename.so                        ## the name of the module
                -I include                              ## add -Iinclude to the compile
                -l lib                                  ## add -llib to the link

 installing:
                -o modulename.so                        ## the name of the module
                -i                                      ## install the object


So I am pretty sure there is a bug here since the –I /home/sowens/ApiMgmtPlugin didn't make it to the g++ command.


From: "Owens, Steve" <St...@disney.com>>
Reply-To: "users@trafficserver.apache.org<ma...@trafficserver.apache.org>" <us...@trafficserver.apache.org>>
Date: Fri, 18 Jan 2013 12:09:56 -0800
To: "users@trafficserver.apache.org<ma...@trafficserver.apache.org>" <us...@trafficserver.apache.org>>
Subject: Questions about tsxs

I am experiencing some confusing behaviors trying to use tsxs and the documentation on this tool does not seem to be very complete.

Here is what I am trying to do in a nutshell.

I have plugin file that I want to build and I want to be able to include files from a different directory into the header file such that:

When I put in my JsonPTransformationHandler.h file

#include <events/BaseEventHandler.h>

#include <TransactionData.h>



And I put this in my JsonPTransformationHandler.cc file:

#include "JsonPTransformationHandler.h"

#include <ApiMgmtUtil.h>



I have tried executing the build tool with the following command lines to no avail:

tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin/
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin/

Yet in each and every case when the tool runs it renders the following error messages:
JsonPTransformationHandler.h:13:37: error: events/BaseEventHandler.h: No such file or directory
JsonPTransformationHandler.h:14:29: error: TransactionData.h: No such file or directory
JsonPTransformationHandler.cc:9:25: error: ApiMgmtUtil.h: No such file or directory

Yet the following ls commands hold:
[sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/TransactionData.h
-rw-rw-r-- 1 sowens sowens 7736 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/TransactionData.h
[sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h
-rw-rw-r-- 1 sowens sowens 20232 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h
[sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h
-rw-rw-r-- 1 sowens sowens 1970 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h


So the files are there but tsxs cannot fine them.  Furthermore other than the limited help provided by the –h option on tsxs there is no examples in the ATS web documentation that talks about includes.  Does tsxs support include directories?


RE: Questions about tsxs

Posted by Geert Lugtenberg <ge...@poort80.nl>.
How about the following Makefile:


TSXS?=tsxs

all: JsonPTransformationHandler.so

JsonPTransformationHandler: JsonPTransformationHandler.cc <any include files>
                g++ JsonPTransformationHandler.cc -o JsonPTransformationHandler.so -I/home/sowens/ApiMgmtPlugin -L<a library path> -l<a lib file>

install: all
                $(TSXS) -i -o JsonPTransformationHandler.so

clean:
                rm -f *.lo *.so *.o


Where a library path/file(s) are up to you if you need to use any. Does that work for you?

-Geert

From: Owens, Steve [mailto:Steve.Owens@disney.com]
Sent: vrijdag 18 januari 2013 21:37
To: users@trafficserver.apache.org
Subject: Re: Questions about tsxs

Given that tsxs is broken does anyone know what would be the sequence of commands that it would execute to build the plugin if it were working correctly given the following command line?

tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin


From: "Owens, Steve" <St...@disney.com>>
Reply-To: "users@trafficserver.apache.org<ma...@trafficserver.apache.org>" <us...@trafficserver.apache.org>>
Date: Fri, 18 Jan 2013 12:19:14 -0800
To: "users@trafficserver.apache.org<ma...@trafficserver.apache.org>" <us...@trafficserver.apache.org>>
Subject: Re: Questions about tsxs

Digging into this further I can see that when I invoke:
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin

Tsxs writes the following on the last line of output:
Compile failed: g++ -I/usr/local/include -g -pipe -Wall -Werror -O3 -feliminate-unused-debug-symbols -fno-strict-aliasing -Wno-invalid-offsetof -fpic -c JsonPTransformationHandler.cc -o JsonPTransformationHandler.lo

Yet when I do
tsxs -h

It outputs:
/usr/local/bin/tsxs : a tool to compile, link and install trafficserver plugins.

 compiling/linking:
                -c [ file1.c [ file2.c [ ... ] ] ]      ## compiles C files
                -C [ file1.cc [ file2.C [ ... ] ] ]     ## compiles C++ files
                -o modulename.so                        ## the name of the module
                -I include                              ## add -Iinclude to the compile
                -l lib                                  ## add -llib to the link

 installing:
                -o modulename.so                        ## the name of the module
                -i                                      ## install the object


So I am pretty sure there is a bug here since the -I /home/sowens/ApiMgmtPlugin didn't make it to the g++ command.


From: "Owens, Steve" <St...@disney.com>>
Reply-To: "users@trafficserver.apache.org<ma...@trafficserver.apache.org>" <us...@trafficserver.apache.org>>
Date: Fri, 18 Jan 2013 12:09:56 -0800
To: "users@trafficserver.apache.org<ma...@trafficserver.apache.org>" <us...@trafficserver.apache.org>>
Subject: Questions about tsxs

I am experiencing some confusing behaviors trying to use tsxs and the documentation on this tool does not seem to be very complete.

Here is what I am trying to do in a nutshell.

I have plugin file that I want to build and I want to be able to include files from a different directory into the header file such that:

When I put in my JsonPTransformationHandler.h file

#include <events/BaseEventHandler.h>

#include <TransactionData.h>



And I put this in my JsonPTransformationHandler.cc file:

#include "JsonPTransformationHandler.h"

#include <ApiMgmtUtil.h>



I have tried executing the build tool with the following command lines to no avail:

tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin/
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin/

Yet in each and every case when the tool runs it renders the following error messages:
JsonPTransformationHandler.h:13:37: error: events/BaseEventHandler.h: No such file or directory
JsonPTransformationHandler.h:14:29: error: TransactionData.h: No such file or directory
JsonPTransformationHandler.cc:9:25: error: ApiMgmtUtil.h: No such file or directory

Yet the following ls commands hold:
[sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/TransactionData.h
-rw-rw-r-- 1 sowens sowens 7736 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/TransactionData.h
[sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h
-rw-rw-r-- 1 sowens sowens 20232 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h
[sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h
-rw-rw-r-- 1 sowens sowens 1970 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h


So the files are there but tsxs cannot fine them.  Furthermore other than the limited help provided by the -h option on tsxs there is no examples in the ATS web documentation that talks about includes.  Does tsxs support include directories?


Re: Questions about tsxs

Posted by James Peach <jp...@apache.org>.
On 22/01/2013, at 9:27 AM, "Owens, Steve" <St...@disney.com> wrote:

> Updating the "usage" as shown in the attached file should make things less
> confusing.

Steve, can you attach this change to a ticket at https://issues.apache.org/jira/browse/TS?

thanks!

> 
> On 1/22/13 9:17 AM, "Owens, Steve" <St...@disney.com> wrote:
> 
>> James, 
>> 
>> After examining the tsxs shell script it is now apparent to me why the
>> command didn't work.
>> 
>> This will not work as expected:
>> 
>> tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc
>> -I /home/sowens/ApiMgmtPlugin
>> 
>> 
>> I suspect that this WILL work as expected
>> 
>> tsxs  -I /home/sowens/ApiMgmtPlugin -o libJsonPTransformationHandler.so -C
>> JsonPTransformationHandler.cc
>> 
>> 
>> Apparently the command line parsing algorithm used isn't as robust as it
>> could be.
>> 
>> The inner loop in the argument parser:
>>       -C)
>>           shift
>>           while [ -r "$1" ]; do
>>              SRC=$1
>>              obj=`echo $SRC | sed -e 's/\.[a-z]*$/\.lo/g;'`
>>              echo "  compiling $SRC -> $obj"
>>              debug "$CXX $CPPFLAGS $CXXFLAGS $PICFLAGS -c $SRC -o $obj"
>>              $CXX $CPPFLAGS $CXXFLAGS $PICFLAGS -c $SRC -o $obj ||
>>              bail "Compile failed: $CXX $CPPFLAGS $CXXFLAGS $PICFLAGS -c
>> $SRC -o $obj"
>>              OBJS="$OBJS $obj"
>>              LD=$MODULELDXX
>>              BUILD=1
>>              shift
>>           done
>>           ;;
>> 
>> Seems to be eating arguments after the -C.
>> 
>> 
>> 
>> 
>> Once I get to a terminal I can try this out from I will follow up with
>> results.
>> 
>> Steve Owens
>> 
>> On 1/19/13 10:03 AM, "James Peach" <jp...@apache.org> wrote:
>> 
>>> On 18/01/2013, at 12:37 PM, "Owens, Steve" <St...@disney.com>
>>> wrote:
>>> 
>>>> Given that tsxs is broken does anyone know what would be the sequence
>>>> of commands that it would execute to build the plugin if it were working
>>>> correctly given the following command line?
>>>> 
>>>> tsxs -o libJsonPTransformationHandler.so -C
>>>> JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin
>>> 
>>> Here's an example (a bit Mac OS X specific):
>>> 	https://github.com/jpeach/spdy/blob/master/Makefile
>>> 
>>> You really only have to set the include path to $TS_ROOT/include and tell
>>> the linker to allow undefined symbols if that's necessary.
>>> 
>>> The -I option to tsxs looks reasonably implemented .. can you put a "set
>>> -x" at the top of tsxs and post the output somewhere?
>>> 
>>>> 
>>>> 
>>>> From: "Owens, Steve" <St...@disney.com>
>>>> Reply-To: "users@trafficserver.apache.org"
>>>> <us...@trafficserver.apache.org>
>>>> Date: Fri, 18 Jan 2013 12:19:14 -0800
>>>> To: "users@trafficserver.apache.org" <us...@trafficserver.apache.org>
>>>> Subject: Re: Questions about tsxs
>>>> 
>>>> Digging into this further I can see that when I invoke:
>>>> tsxs -o libJsonPTransformationHandler.so -C
>>>> JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin
>>>> 
>>>> Tsxs writes the following on the last line of output:
>>>> Compile failed: g++ -I/usr/local/include -g -pipe -Wall -Werror -O3
>>>> -feliminate-unused-debug-symbols -fno-strict-aliasing
>>>> -Wno-invalid-offsetof -fpic -c JsonPTransformationHandler.cc -o
>>>> JsonPTransformationHandler.lo
>>>> 
>>>> Yet when I do 
>>>> tsxs -h
>>>> 
>>>> It outputs:
>>>> /usr/local/bin/tsxs : a tool to compile, link and install trafficserver
>>>> plugins.
>>>> 
>>>> compiling/linking:
>>>> 	-c [ file1.c [ file2.c [ ... ] ] ]      ## compiles C files
>>>> 	-C [ file1.cc [ file2.C [ ... ] ] ]     ## compiles C++ files
>>>> 	-o modulename.so                        ## the name of the module
>>>> 	-I include                              ## add -Iinclude to the
>>>> compile
>>>> 	-l lib                                  ## add -llib to the link
>>>> 
>>>> installing:
>>>> 	-o modulename.so                        ## the name of the module
>>>> 	-i                                      ## install the object
>>>> 
>>>> 
>>>> So I am pretty sure there is a bug here since the ­I
>>>> /home/sowens/ApiMgmtPlugin didn't make it to the g++ command.
>>>> 
>>>> 
>>>> From: "Owens, Steve" <St...@disney.com>
>>>> Reply-To: "users@trafficserver.apache.org"
>>>> <us...@trafficserver.apache.org>
>>>> Date: Fri, 18 Jan 2013 12:09:56 -0800
>>>> To: "users@trafficserver.apache.org" <us...@trafficserver.apache.org>
>>>> Subject: Questions about tsxs
>>>> 
>>>> I am experiencing some confusing behaviors trying to use tsxs and the
>>>> documentation on this tool does not seem to be very complete.
>>>> 
>>>> Here is what I am trying to do in a nutshell.
>>>> 
>>>> I have plugin file that I want to build and I want to be able to
>>>> include files from a different directory into the header file such that:
>>>> 
>>>> When I put in my JsonPTransformationHandler.h file
>>>> #include <events/BaseEventHandler.h>
>>>> #include <TransactionData.h>
>>>> 
>>>> 
>>>> And I put this in my JsonPTransformationHandler.cc file:
>>>> #include "JsonPTransformationHandler.h"
>>>> #include <ApiMgmtUtil.h>
>>>> 
>>>> 
>>>> I have tried executing the build tool with the following command lines
>>>> to no avail:
>>>> 
>>>> tsxs -o libJsonPTransformationHandler.so -C
>>>> JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin
>>>> tsxs -o libJsonPTransformationHandler.so -C
>>>> JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin/
>>>> tsxs -o libJsonPTransformationHandler.so -C
>>>> JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin
>>>> tsxs -o libJsonPTransformationHandler.so -C
>>>> JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin/
>>>> 
>>>> Yet in each and every case when the tool runs it renders the following
>>>> error messages:
>>>> JsonPTransformationHandler.h:13:37: error: events/BaseEventHandler.h:
>>>> No such file or directory
>>>> JsonPTransformationHandler.h:14:29: error: TransactionData.h: No such
>>>> file or directory
>>>> JsonPTransformationHandler.cc:9:25: error: ApiMgmtUtil.h: No such file
>>>> or directory
>>>> 
>>>> Yet the following ls commands hold:
>>>> [sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l
>>>> /home/sowens/ApiMgmtPlugin/TransactionData.h
>>>> -rw-rw-r-- 1 sowens sowens 7736 Jan 18 11:22
>>>> /home/sowens/ApiMgmtPlugin/TransactionData.h
>>>> [sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l
>>>> /home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h
>>>> -rw-rw-r-- 1 sowens sowens 20232 Jan 18 11:22
>>>> /home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h
>>>> [sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l
>>>> /home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h
>>>> -rw-rw-r-- 1 sowens sowens 1970 Jan 18 11:22
>>>> /home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h
>>>> 
>>>> 
>>>> So the files are there but tsxs cannot fine them.  Furthermore other
>>>> than the limited help provided by the ­h option on tsxs there is no
>>>> examples in the ATS web documentation that talks about includes.  Does
>>>> tsxs support include directories?
>>>> 
>>> 
>> 
> 
> <tsxs.updated>


Re: Questions about tsxs

Posted by "Owens, Steve" <St...@disney.com>.
Updating the "usage" as shown in the attached file should make things less
confusing.

On 1/22/13 9:17 AM, "Owens, Steve" <St...@disney.com> wrote:

>James, 
>
>After examining the tsxs shell script it is now apparent to me why the
>command didn't work.
>
>This will not work as expected:
>
>tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc
>-I /home/sowens/ApiMgmtPlugin
>
>
>I suspect that this WILL work as expected
>
>tsxs  -I /home/sowens/ApiMgmtPlugin -o libJsonPTransformationHandler.so -C
>JsonPTransformationHandler.cc
> 
>
>Apparently the command line parsing algorithm used isn't as robust as it
>could be.
>
>The inner loop in the argument parser:
>        -C)
>            shift
>            while [ -r "$1" ]; do
>               SRC=$1
>               obj=`echo $SRC | sed -e 's/\.[a-z]*$/\.lo/g;'`
>               echo "  compiling $SRC -> $obj"
>               debug "$CXX $CPPFLAGS $CXXFLAGS $PICFLAGS -c $SRC -o $obj"
>               $CXX $CPPFLAGS $CXXFLAGS $PICFLAGS -c $SRC -o $obj ||
>               bail "Compile failed: $CXX $CPPFLAGS $CXXFLAGS $PICFLAGS -c
>$SRC -o $obj"
>               OBJS="$OBJS $obj"
>               LD=$MODULELDXX
>               BUILD=1
>               shift
>            done
>            ;;
>
>Seems to be eating arguments after the -C.
>
>
>
>
>Once I get to a terminal I can try this out from I will follow up with
>results.
>
>Steve Owens
>
>On 1/19/13 10:03 AM, "James Peach" <jp...@apache.org> wrote:
>
>>On 18/01/2013, at 12:37 PM, "Owens, Steve" <St...@disney.com>
>>wrote:
>>
>>> Given that tsxs is broken does anyone know what would be the sequence
>>>of commands that it would execute to build the plugin if it were working
>>>correctly given the following command line?
>>> 
>>> tsxs -o libJsonPTransformationHandler.so -C
>>>JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin
>>
>>Here's an example (a bit Mac OS X specific):
>>	https://github.com/jpeach/spdy/blob/master/Makefile
>>
>>You really only have to set the include path to $TS_ROOT/include and tell
>>the linker to allow undefined symbols if that's necessary.
>>
>>The -I option to tsxs looks reasonably implemented .. can you put a "set
>>-x" at the top of tsxs and post the output somewhere?
>>
>>> 
>>> 
>>> From: "Owens, Steve" <St...@disney.com>
>>> Reply-To: "users@trafficserver.apache.org"
>>><us...@trafficserver.apache.org>
>>> Date: Fri, 18 Jan 2013 12:19:14 -0800
>>> To: "users@trafficserver.apache.org" <us...@trafficserver.apache.org>
>>> Subject: Re: Questions about tsxs
>>> 
>>> Digging into this further I can see that when I invoke:
>>> tsxs -o libJsonPTransformationHandler.so -C
>>>JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin
>>> 
>>> Tsxs writes the following on the last line of output:
>>> Compile failed: g++ -I/usr/local/include -g -pipe -Wall -Werror -O3
>>>-feliminate-unused-debug-symbols -fno-strict-aliasing
>>>-Wno-invalid-offsetof -fpic -c JsonPTransformationHandler.cc -o
>>>JsonPTransformationHandler.lo
>>> 
>>> Yet when I do 
>>> tsxs -h
>>> 
>>> It outputs:
>>> /usr/local/bin/tsxs : a tool to compile, link and install trafficserver
>>>plugins.
>>> 
>>>  compiling/linking:
>>> 	-c [ file1.c [ file2.c [ ... ] ] ]      ## compiles C files
>>> 	-C [ file1.cc [ file2.C [ ... ] ] ]     ## compiles C++ files
>>> 	-o modulename.so                        ## the name of the module
>>> 	-I include                              ## add -Iinclude to the
>>>compile
>>> 	-l lib                                  ## add -llib to the link
>>> 
>>>  installing:
>>> 	-o modulename.so                        ## the name of the module
>>> 	-i                                      ## install the object
>>> 
>>> 
>>> So I am pretty sure there is a bug here since the ­I
>>>/home/sowens/ApiMgmtPlugin didn't make it to the g++ command.
>>> 
>>> 
>>> From: "Owens, Steve" <St...@disney.com>
>>> Reply-To: "users@trafficserver.apache.org"
>>><us...@trafficserver.apache.org>
>>> Date: Fri, 18 Jan 2013 12:09:56 -0800
>>> To: "users@trafficserver.apache.org" <us...@trafficserver.apache.org>
>>> Subject: Questions about tsxs
>>> 
>>> I am experiencing some confusing behaviors trying to use tsxs and the
>>>documentation on this tool does not seem to be very complete.
>>> 
>>> Here is what I am trying to do in a nutshell.
>>> 
>>> I have plugin file that I want to build and I want to be able to
>>>include files from a different directory into the header file such that:
>>> 
>>> When I put in my JsonPTransformationHandler.h file
>>> #include <events/BaseEventHandler.h>
>>> #include <TransactionData.h>
>>> 
>>> 
>>> And I put this in my JsonPTransformationHandler.cc file:
>>> #include "JsonPTransformationHandler.h"
>>> #include <ApiMgmtUtil.h>
>>> 
>>> 
>>> I have tried executing the build tool with the following command lines
>>>to no avail:
>>> 
>>> tsxs -o libJsonPTransformationHandler.so -C
>>>JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin
>>> tsxs -o libJsonPTransformationHandler.so -C
>>>JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin/
>>> tsxs -o libJsonPTransformationHandler.so -C
>>>JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin
>>> tsxs -o libJsonPTransformationHandler.so -C
>>>JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin/
>>> 
>>> Yet in each and every case when the tool runs it renders the following
>>>error messages:
>>> JsonPTransformationHandler.h:13:37: error: events/BaseEventHandler.h:
>>>No such file or directory
>>> JsonPTransformationHandler.h:14:29: error: TransactionData.h: No such
>>>file or directory
>>> JsonPTransformationHandler.cc:9:25: error: ApiMgmtUtil.h: No such file
>>>or directory
>>> 
>>> Yet the following ls commands hold:
>>> [sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l
>>>/home/sowens/ApiMgmtPlugin/TransactionData.h
>>> -rw-rw-r-- 1 sowens sowens 7736 Jan 18 11:22
>>>/home/sowens/ApiMgmtPlugin/TransactionData.h
>>> [sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l
>>>/home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h
>>> -rw-rw-r-- 1 sowens sowens 20232 Jan 18 11:22
>>>/home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h
>>> [sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l
>>>/home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h
>>> -rw-rw-r-- 1 sowens sowens 1970 Jan 18 11:22
>>>/home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h
>>> 
>>> 
>>> So the files are there but tsxs cannot fine them.  Furthermore other
>>>than the limited help provided by the ­h option on tsxs there is no
>>>examples in the ATS web documentation that talks about includes.  Does
>>>tsxs support include directories?
>>> 
>>
>


Re: Questions about tsxs

Posted by "Owens, Steve" <St...@disney.com>.
James, 

After examining the tsxs shell script it is now apparent to me why the
command didn't work.

This will not work as expected:

tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc
-I /home/sowens/ApiMgmtPlugin


I suspect that this WILL work as expected

tsxs  -I /home/sowens/ApiMgmtPlugin -o libJsonPTransformationHandler.so -C
JsonPTransformationHandler.cc
 

Apparently the command line parsing algorithm used isn't as robust as it
could be.

The inner loop in the argument parser:
        -C)
            shift
            while [ -r "$1" ]; do
               SRC=$1
               obj=`echo $SRC | sed -e 's/\.[a-z]*$/\.lo/g;'`
               echo "  compiling $SRC -> $obj"
               debug "$CXX $CPPFLAGS $CXXFLAGS $PICFLAGS -c $SRC -o $obj"
               $CXX $CPPFLAGS $CXXFLAGS $PICFLAGS -c $SRC -o $obj ||
               bail "Compile failed: $CXX $CPPFLAGS $CXXFLAGS $PICFLAGS -c
$SRC -o $obj"
               OBJS="$OBJS $obj"
               LD=$MODULELDXX
               BUILD=1
               shift
            done
            ;;

Seems to be eating arguments after the -C.




Once I get to a terminal I can try this out from I will follow up with
results.

Steve Owens

On 1/19/13 10:03 AM, "James Peach" <jp...@apache.org> wrote:

>On 18/01/2013, at 12:37 PM, "Owens, Steve" <St...@disney.com> wrote:
>
>> Given that tsxs is broken does anyone know what would be the sequence
>>of commands that it would execute to build the plugin if it were working
>>correctly given the following command line?
>> 
>> tsxs -o libJsonPTransformationHandler.so -C
>>JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin
>
>Here's an example (a bit Mac OS X specific):
>	https://github.com/jpeach/spdy/blob/master/Makefile
>
>You really only have to set the include path to $TS_ROOT/include and tell
>the linker to allow undefined symbols if that's necessary.
>
>The -I option to tsxs looks reasonably implemented .. can you put a "set
>-x" at the top of tsxs and post the output somewhere?
>
>> 
>> 
>> From: "Owens, Steve" <St...@disney.com>
>> Reply-To: "users@trafficserver.apache.org"
>><us...@trafficserver.apache.org>
>> Date: Fri, 18 Jan 2013 12:19:14 -0800
>> To: "users@trafficserver.apache.org" <us...@trafficserver.apache.org>
>> Subject: Re: Questions about tsxs
>> 
>> Digging into this further I can see that when I invoke:
>> tsxs -o libJsonPTransformationHandler.so -C
>>JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin
>> 
>> Tsxs writes the following on the last line of output:
>> Compile failed: g++ -I/usr/local/include -g -pipe -Wall -Werror -O3
>>-feliminate-unused-debug-symbols -fno-strict-aliasing
>>-Wno-invalid-offsetof -fpic -c JsonPTransformationHandler.cc -o
>>JsonPTransformationHandler.lo
>> 
>> Yet when I do 
>> tsxs -h
>> 
>> It outputs:
>> /usr/local/bin/tsxs : a tool to compile, link and install trafficserver
>>plugins.
>> 
>>  compiling/linking:
>> 	-c [ file1.c [ file2.c [ ... ] ] ]      ## compiles C files
>> 	-C [ file1.cc [ file2.C [ ... ] ] ]     ## compiles C++ files
>> 	-o modulename.so                        ## the name of the module
>> 	-I include                              ## add -Iinclude to the compile
>> 	-l lib                                  ## add -llib to the link
>> 
>>  installing:
>> 	-o modulename.so                        ## the name of the module
>> 	-i                                      ## install the object
>> 
>> 
>> So I am pretty sure there is a bug here since the ­I
>>/home/sowens/ApiMgmtPlugin didn't make it to the g++ command.
>> 
>> 
>> From: "Owens, Steve" <St...@disney.com>
>> Reply-To: "users@trafficserver.apache.org"
>><us...@trafficserver.apache.org>
>> Date: Fri, 18 Jan 2013 12:09:56 -0800
>> To: "users@trafficserver.apache.org" <us...@trafficserver.apache.org>
>> Subject: Questions about tsxs
>> 
>> I am experiencing some confusing behaviors trying to use tsxs and the
>>documentation on this tool does not seem to be very complete.
>> 
>> Here is what I am trying to do in a nutshell.
>> 
>> I have plugin file that I want to build and I want to be able to
>>include files from a different directory into the header file such that:
>> 
>> When I put in my JsonPTransformationHandler.h file
>> #include <events/BaseEventHandler.h>
>> #include <TransactionData.h>
>> 
>> 
>> And I put this in my JsonPTransformationHandler.cc file:
>> #include "JsonPTransformationHandler.h"
>> #include <ApiMgmtUtil.h>
>> 
>> 
>> I have tried executing the build tool with the following command lines
>>to no avail:
>> 
>> tsxs -o libJsonPTransformationHandler.so -C
>>JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin
>> tsxs -o libJsonPTransformationHandler.so -C
>>JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin/
>> tsxs -o libJsonPTransformationHandler.so -C
>>JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin
>> tsxs -o libJsonPTransformationHandler.so -C
>>JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin/
>> 
>> Yet in each and every case when the tool runs it renders the following
>>error messages:
>> JsonPTransformationHandler.h:13:37: error: events/BaseEventHandler.h:
>>No such file or directory
>> JsonPTransformationHandler.h:14:29: error: TransactionData.h: No such
>>file or directory
>> JsonPTransformationHandler.cc:9:25: error: ApiMgmtUtil.h: No such file
>>or directory
>> 
>> Yet the following ls commands hold:
>> [sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l
>>/home/sowens/ApiMgmtPlugin/TransactionData.h
>> -rw-rw-r-- 1 sowens sowens 7736 Jan 18 11:22
>>/home/sowens/ApiMgmtPlugin/TransactionData.h
>> [sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l
>>/home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h
>> -rw-rw-r-- 1 sowens sowens 20232 Jan 18 11:22
>>/home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h
>> [sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l
>>/home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h
>> -rw-rw-r-- 1 sowens sowens 1970 Jan 18 11:22
>>/home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h
>> 
>> 
>> So the files are there but tsxs cannot fine them.  Furthermore other
>>than the limited help provided by the ­h option on tsxs there is no
>>examples in the ATS web documentation that talks about includes.  Does
>>tsxs support include directories?
>> 
>


Re: Questions about tsxs

Posted by James Peach <jp...@apache.org>.
On 18/01/2013, at 12:37 PM, "Owens, Steve" <St...@disney.com> wrote:

> Given that tsxs is broken does anyone know what would be the sequence of commands that it would execute to build the plugin if it were working correctly given the following command line?
> 
> tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin

Here's an example (a bit Mac OS X specific):
	https://github.com/jpeach/spdy/blob/master/Makefile

You really only have to set the include path to $TS_ROOT/include and tell the linker to allow undefined symbols if that's necessary.

The -I option to tsxs looks reasonably implemented .. can you put a "set -x" at the top of tsxs and post the output somewhere?

> 
> 
> From: "Owens, Steve" <St...@disney.com>
> Reply-To: "users@trafficserver.apache.org" <us...@trafficserver.apache.org>
> Date: Fri, 18 Jan 2013 12:19:14 -0800
> To: "users@trafficserver.apache.org" <us...@trafficserver.apache.org>
> Subject: Re: Questions about tsxs
> 
> Digging into this further I can see that when I invoke:
> tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin
> 
> Tsxs writes the following on the last line of output:
> Compile failed: g++ -I/usr/local/include -g -pipe -Wall -Werror -O3 -feliminate-unused-debug-symbols -fno-strict-aliasing -Wno-invalid-offsetof -fpic -c JsonPTransformationHandler.cc -o JsonPTransformationHandler.lo
> 
> Yet when I do 
> tsxs -h
> 
> It outputs:
> /usr/local/bin/tsxs : a tool to compile, link and install trafficserver plugins.
> 
>  compiling/linking:
> 	-c [ file1.c [ file2.c [ ... ] ] ]      ## compiles C files
> 	-C [ file1.cc [ file2.C [ ... ] ] ]     ## compiles C++ files
> 	-o modulename.so                        ## the name of the module
> 	-I include                              ## add -Iinclude to the compile
> 	-l lib                                  ## add -llib to the link
> 
>  installing:
> 	-o modulename.so                        ## the name of the module
> 	-i                                      ## install the object
> 
> 
> So I am pretty sure there is a bug here since the –I /home/sowens/ApiMgmtPlugin didn't make it to the g++ command.
> 
> 
> From: "Owens, Steve" <St...@disney.com>
> Reply-To: "users@trafficserver.apache.org" <us...@trafficserver.apache.org>
> Date: Fri, 18 Jan 2013 12:09:56 -0800
> To: "users@trafficserver.apache.org" <us...@trafficserver.apache.org>
> Subject: Questions about tsxs
> 
> I am experiencing some confusing behaviors trying to use tsxs and the documentation on this tool does not seem to be very complete.
> 
> Here is what I am trying to do in a nutshell.
> 
> I have plugin file that I want to build and I want to be able to include files from a different directory into the header file such that:
> 
> When I put in my JsonPTransformationHandler.h file
> #include <events/BaseEventHandler.h>
> #include <TransactionData.h>
> 
> 
> And I put this in my JsonPTransformationHandler.cc file:
> #include "JsonPTransformationHandler.h"
> #include <ApiMgmtUtil.h>
> 
> 
> I have tried executing the build tool with the following command lines to no avail:
> 
> tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin
> tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin/
> tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin
> tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin/
> 
> Yet in each and every case when the tool runs it renders the following error messages:
> JsonPTransformationHandler.h:13:37: error: events/BaseEventHandler.h: No such file or directory
> JsonPTransformationHandler.h:14:29: error: TransactionData.h: No such file or directory
> JsonPTransformationHandler.cc:9:25: error: ApiMgmtUtil.h: No such file or directory
> 
> Yet the following ls commands hold:
> [sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/TransactionData.h
> -rw-rw-r-- 1 sowens sowens 7736 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/TransactionData.h
> [sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h 
> -rw-rw-r-- 1 sowens sowens 20232 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h
> [sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h 
> -rw-rw-r-- 1 sowens sowens 1970 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h
> 
> 
> So the files are there but tsxs cannot fine them.  Furthermore other than the limited help provided by the –h option on tsxs there is no examples in the ATS web documentation that talks about includes.  Does tsxs support include directories?
> 


Re: Questions about tsxs

Posted by "Owens, Steve" <St...@disney.com>.
Given that tsxs is broken does anyone know what would be the sequence of commands that it would execute to build the plugin if it were working correctly given the following command line?

tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin


From: "Owens, Steve" <St...@disney.com>>
Reply-To: "users@trafficserver.apache.org<ma...@trafficserver.apache.org>" <us...@trafficserver.apache.org>>
Date: Fri, 18 Jan 2013 12:19:14 -0800
To: "users@trafficserver.apache.org<ma...@trafficserver.apache.org>" <us...@trafficserver.apache.org>>
Subject: Re: Questions about tsxs

Digging into this further I can see that when I invoke:
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin

Tsxs writes the following on the last line of output:
Compile failed: g++ -I/usr/local/include -g -pipe -Wall -Werror -O3 -feliminate-unused-debug-symbols -fno-strict-aliasing -Wno-invalid-offsetof -fpic -c JsonPTransformationHandler.cc -o JsonPTransformationHandler.lo

Yet when I do
tsxs -h

It outputs:
/usr/local/bin/tsxs : a tool to compile, link and install trafficserver plugins.

 compiling/linking:
-c [ file1.c [ file2.c [ ... ] ] ]      ## compiles C files
-C [ file1.cc [ file2.C [ ... ] ] ]     ## compiles C++ files
-o modulename.so                        ## the name of the module
-I include                              ## add -Iinclude to the compile
-l lib                                  ## add -llib to the link

 installing:
-o modulename.so                        ## the name of the module
-i                                      ## install the object


So I am pretty sure there is a bug here since the –I /home/sowens/ApiMgmtPlugin didn't make it to the g++ command.


From: "Owens, Steve" <St...@disney.com>>
Reply-To: "users@trafficserver.apache.org<ma...@trafficserver.apache.org>" <us...@trafficserver.apache.org>>
Date: Fri, 18 Jan 2013 12:09:56 -0800
To: "users@trafficserver.apache.org<ma...@trafficserver.apache.org>" <us...@trafficserver.apache.org>>
Subject: Questions about tsxs

I am experiencing some confusing behaviors trying to use tsxs and the documentation on this tool does not seem to be very complete.

Here is what I am trying to do in a nutshell.

I have plugin file that I want to build and I want to be able to include files from a different directory into the header file such that:

When I put in my JsonPTransformationHandler.h file

#include <events/BaseEventHandler.h>

#include <TransactionData.h>


And I put this in my JsonPTransformationHandler.cc file:

#include "JsonPTransformationHandler.h"

#include <ApiMgmtUtil.h>


I have tried executing the build tool with the following command lines to no avail:

tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin/
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin/

Yet in each and every case when the tool runs it renders the following error messages:
JsonPTransformationHandler.h:13:37: error: events/BaseEventHandler.h: No such file or directory
JsonPTransformationHandler.h:14:29: error: TransactionData.h: No such file or directory
JsonPTransformationHandler.cc:9:25: error: ApiMgmtUtil.h: No such file or directory

Yet the following ls commands hold:
[sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/TransactionData.h
-rw-rw-r-- 1 sowens sowens 7736 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/TransactionData.h
[sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h
-rw-rw-r-- 1 sowens sowens 20232 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h
[sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h
-rw-rw-r-- 1 sowens sowens 1970 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h


So the files are there but tsxs cannot fine them.  Furthermore other than the limited help provided by the –h option on tsxs there is no examples in the ATS web documentation that talks about includes.  Does tsxs support include directories?


Re: Questions about tsxs

Posted by "Owens, Steve" <St...@disney.com>.
Digging into this further I can see that when I invoke:
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin

Tsxs writes the following on the last line of output:
Compile failed: g++ -I/usr/local/include -g -pipe -Wall -Werror -O3 -feliminate-unused-debug-symbols -fno-strict-aliasing -Wno-invalid-offsetof -fpic -c JsonPTransformationHandler.cc -o JsonPTransformationHandler.lo

Yet when I do
tsxs -h

It outputs:
/usr/local/bin/tsxs : a tool to compile, link and install trafficserver plugins.

 compiling/linking:
-c [ file1.c [ file2.c [ ... ] ] ]      ## compiles C files
-C [ file1.cc [ file2.C [ ... ] ] ]     ## compiles C++ files
-o modulename.so                        ## the name of the module
-I include                              ## add -Iinclude to the compile
-l lib                                  ## add -llib to the link

 installing:
-o modulename.so                        ## the name of the module
-i                                      ## install the object


So I am pretty sure there is a bug here since the –I /home/sowens/ApiMgmtPlugin didn't make it to the g++ command.


From: "Owens, Steve" <St...@disney.com>>
Reply-To: "users@trafficserver.apache.org<ma...@trafficserver.apache.org>" <us...@trafficserver.apache.org>>
Date: Fri, 18 Jan 2013 12:09:56 -0800
To: "users@trafficserver.apache.org<ma...@trafficserver.apache.org>" <us...@trafficserver.apache.org>>
Subject: Questions about tsxs

I am experiencing some confusing behaviors trying to use tsxs and the documentation on this tool does not seem to be very complete.

Here is what I am trying to do in a nutshell.

I have plugin file that I want to build and I want to be able to include files from a different directory into the header file such that:

When I put in my JsonPTransformationHandler.h file

#include <events/BaseEventHandler.h>

#include <TransactionData.h>


And I put this in my JsonPTransformationHandler.cc file:

#include "JsonPTransformationHandler.h"

#include <ApiMgmtUtil.h>


I have tried executing the build tool with the following command lines to no avail:

tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I/home/sowens/ApiMgmtPlugin/
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin
tsxs -o libJsonPTransformationHandler.so -C JsonPTransformationHandler.cc -I /home/sowens/ApiMgmtPlugin/

Yet in each and every case when the tool runs it renders the following error messages:
JsonPTransformationHandler.h:13:37: error: events/BaseEventHandler.h: No such file or directory
JsonPTransformationHandler.h:14:29: error: TransactionData.h: No such file or directory
JsonPTransformationHandler.cc:9:25: error: ApiMgmtUtil.h: No such file or directory

Yet the following ls commands hold:
[sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/TransactionData.h
-rw-rw-r-- 1 sowens sowens 7736 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/TransactionData.h
[sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h
-rw-rw-r-- 1 sowens sowens 20232 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/ApiMgmtUtil.h
[sowens@d4mftapp11 JsonPTransformationHandlerPlugin]$ ls -l /home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h
-rw-rw-r-- 1 sowens sowens 1970 Jan 18 11:22 /home/sowens/ApiMgmtPlugin/events/BaseEventHandler.h


So the files are there but tsxs cannot fine them.  Furthermore other than the limited help provided by the –h option on tsxs there is no examples in the ATS web documentation that talks about includes.  Does tsxs support include directories?