From: Jeff S. <jef...@gm...> - 2007-05-15 01:51:52
|
When compiling lirc I run into the following error lirc_client.c: In function 'lirc_send_command': lirc_client.c:1887: error: impossible constraint in 'asm' make[2]: *** [lirc_client.lo] Error 1 make[2]: Leaving directory `/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/lirc-0.8.1/tools' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/lirc-0.8.1' make: *** [all] Error 2 looking into it I keep finding reference that I am pointing to the wrong header or that the headers are buggy do I need to change some headers someplace? here is what I used so far export \ CC=/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/staging_dir/bin/arm-linux-gcc ./configure \ --host=arm \ --prefix=/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/root/ \ --with-driver=iguanaIR then make I installed the iguanaIR and its header file and it links some of the binaries with it :-) So I know some of the stuff is working. Line 1887 of lirc_client.c is a FD_ZERO macro I'll have to digg to see where its located and throw in a "#warning you are here" to make sure im in the right file |
From: Jeff S. <jef...@gm...> - 2007-05-15 05:07:04
|
code in question #undef __FD_ZERO #define __FD_ZERO(fdsetp) \ (memset (fdsetp, 0, sizeof (*(fd_set *)(fdsetp)))) #endif On 5/14/07, Jeff Sadowski <jef...@gm...> wrote: > When compiling lirc I run into the following error > > lirc_client.c: In function 'lirc_send_command': > lirc_client.c:1887: error: impossible constraint in 'asm' > make[2]: *** [lirc_client.lo] Error 1 > make[2]: Leaving directory > `/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/lirc-0.8.1/tools' > make[1]: *** [all-recursive] Error 1 > make[1]: Leaving directory > `/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/lirc-0.8.1' > make: *** [all] Error 2 > > looking into it I keep finding reference that I am pointing to the > wrong header or that the headers are buggy > > do I need to change some headers someplace? > > here is what I used so far > > export \ > CC=/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/staging_dir/bin/arm-linux-gcc > > ./configure \ > --host=arm \ > --prefix=/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/root/ \ > --with-driver=iguanaIR > > then make > > I installed the iguanaIR and its header file and it links some of the > binaries with it :-) > So I know some of the stuff is working. > > Line 1887 of lirc_client.c is a > FD_ZERO macro I'll have to digg to see where its located and throw in > a "#warning you are here" to make sure im in the right file > |
From: Jeff S. <jef...@gm...> - 2007-05-15 15:03:10
|
I was looking in /root/gumstix-verdex-buildroot-1370/build_arm_nofpu/linux-2.6.18gum/include/asm/posix_types.h but I put warnings in it and its not even getting to the file :-/ On 5/14/07, Jeff Sadowski <jef...@gm...> wrote: > code in question > > #undef __FD_ZERO > #define __FD_ZERO(fdsetp) \ > (memset (fdsetp, 0, sizeof (*(fd_set *)(fdsetp)))) > > #endif > > > On 5/14/07, Jeff Sadowski <jef...@gm...> wrote: > > When compiling lirc I run into the following error > > > > lirc_client.c: In function 'lirc_send_command': > > lirc_client.c:1887: error: impossible constraint in 'asm' > > make[2]: *** [lirc_client.lo] Error 1 > > make[2]: Leaving directory > > `/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/lirc-0.8.1/tools' > > make[1]: *** [all-recursive] Error 1 > > make[1]: Leaving directory > > `/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/lirc-0.8.1' > > make: *** [all] Error 2 > > > > looking into it I keep finding reference that I am pointing to the > > wrong header or that the headers are buggy > > > > do I need to change some headers someplace? > > > > here is what I used so far > > > > export \ > > CC=/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/staging_dir/bin/arm-linux-gcc > > > > ./configure \ > > --host=arm \ > > --prefix=/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/root/ \ > > --with-driver=iguanaIR > > > > then make > > > > I installed the iguanaIR and its header file and it links some of the > > binaries with it :-) > > So I know some of the stuff is working. > > > > Line 1887 of lirc_client.c is a > > FD_ZERO macro I'll have to digg to see where its located and throw in > > a "#warning you are here" to make sure im in the right file > > > |
From: Jeff S. <jef...@gm...> - 2007-05-15 15:49:24
|
after all the includes I included this #define __KERNEL__ #include <asm-arm/posix_types.h> so that I know I have the right definitions for FD_ZERO which actually took me further now I get another error that im afraid im stuck on lirc_client.c: In function 'lirc_read_string': lirc_client.c:1891: error: 'fd_set' has no member named 'fds_bits' make[2]: *** [lirc_client.lo] Error 1 make[2]: Leaving directory `/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/lirc-0.8.1/tools' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/lirc-0.8.1' make: *** [all] Error 2 looking into it I'm afraid that the fd_set in uclib doesn't have a full set of things I need for lirc_client is there a way around this On 5/14/07, Jeff Sadowski <jef...@gm...> wrote: > When compiling lirc I run into the following error > > lirc_client.c: In function 'lirc_send_command': > lirc_client.c:1887: error: impossible constraint in 'asm' > make[2]: *** [lirc_client.lo] Error 1 > make[2]: Leaving directory > `/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/lirc-0.8.1/tools' > make[1]: *** [all-recursive] Error 1 > make[1]: Leaving directory > `/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/lirc-0.8.1' > make: *** [all] Error 2 > > looking into it I keep finding reference that I am pointing to the > wrong header or that the headers are buggy > > do I need to change some headers someplace? > > here is what I used so far > > export \ > CC=/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/staging_dir/bin/arm-linux-gcc > > ./configure \ > --host=arm \ > --prefix=/root/gumstix-verdex-buildroot-1370/build_arm_nofpu/root/ \ > --with-driver=iguanaIR > > then make > > I installed the iguanaIR and its header file and it links some of the > binaries with it :-) > So I know some of the stuff is working. > > Line 1887 of lirc_client.c is a > FD_ZERO macro I'll have to digg to see where its located and throw in > a "#warning you are here" to make sure im in the right file > |
From: Dave H. <dhy...@gm...> - 2007-05-15 15:49:33
|
Hi Jeff, On 5/15/07, Jeff Sadowski <jef...@gm...> wrote: > I was looking in > /root/gumstix-verdex-buildroot-1370/build_arm_nofpu/linux-2.6.18gum/include/asm/posix_types.h > but I put warnings in it and its not even getting to the file :-/ So, the files in the build_arm_nofpu/linux-2.6.18gum/include directory are normally only included when you're building the kernel itself or a kernel module. They're not used for building user mode programs, which use the build_arm_nofpu/staging_dir/include tree. To see which file is actually being included, I generally take the command used to compile the source, cd into the same directory that make would be in when it executes the command and replace the -c on the command line with -E and if there is a -o option then I change the extension from .o to .pp. I also add a -Wp,-dD (note the comma separating -Wp and -dD and also note that there should be no spaces around the comma). This will produce a preprocessed file which contains the #define's and you can look for the #line directives (which are often shortened to be just # linenumber filename to see which file is actually being included/ -- Dave Hylands Vancouver, BC, Canada http://www.DaveHylands.com/ |
From: Jeff S. <jef...@gm...> - 2007-05-15 15:59:59
|
thanks this will give me something to look at I just found out that the definitions in the kernel hearders don't even match the fd_set structure anyways It looks like im looking for something in uclib On 5/15/07, Dave Hylands <dhy...@gm...> wrote: > Hi Jeff, > > On 5/15/07, Jeff Sadowski <jef...@gm...> wrote: > > I was looking in > > /root/gumstix-verdex-buildroot-1370/build_arm_nofpu/linux-2.6.18gum/include/asm/posix_types.h > > but I put warnings in it and its not even getting to the file :-/ > > So, the files in the build_arm_nofpu/linux-2.6.18gum/include directory > are normally only included when you're building the kernel itself or a > kernel module. They're not used for building user mode programs, which > use the build_arm_nofpu/staging_dir/include tree. > > To see which file is actually being included, I generally take the > command used to compile the source, cd into the same directory that > make would be in when it executes the command and replace the -c on > the command line with -E and if there is a -o option then I change the > extension from .o to .pp. I also add a -Wp,-dD (note the comma > separating -Wp and -dD and also note that there should be no spaces > around the comma). > > This will produce a preprocessed file which contains the #define's and > you can look for the #line directives (which are often shortened to be > just # linenumber filename to see which file is actually being > included/ > > -- > Dave Hylands > Vancouver, BC, Canada > http://www.DaveHylands.com/ > > ------------------------------------------------------------------------- > This SF.net email is sponsored by DB2 Express > Download DB2 Express C - the FREE version of DB2 express and take > control of your XML. No limits. Just data. Click to get it now. > http://sourceforge.net/powerbar/db2/ > _______________________________________________ > gumstix-users mailing list > gum...@li... > https://lists.sourceforge.net/lists/listinfo/gumstix-users > |
From: Dave H. <dhy...@gm...> - 2007-05-15 15:58:39
|
Hi Jeff, On 5/15/07, Jeff Sadowski <jef...@gm...> wrote: > after all the includes I included this > > #define __KERNEL__ > #include <asm-arm/posix_types.h> This is almost certainly the wrong thing to do. The file build_arm_nofpu/staging_dir/include/select.h seems to have the correct defintions of FD_ZERO for user mode code (and it includes bits/select.h which has the definition of __FD_ZERO) -- Dave Hylands Vancouver, BC, Canada http://www.DaveHylands.com/ |
From: Jeff S. <jef...@gm...> - 2007-05-15 16:07:36
|
ah ok I'll take a look at that then actually its sys/select.h with FD_ZERO and bits/select.h with __FD_ZERO I suspect a problem in bits/select.h I'll try and reproduce the error with simple code and try and fix it to do what it is suppose to. On 5/15/07, Dave Hylands <dhy...@gm...> wrote: > Hi Jeff, > > On 5/15/07, Jeff Sadowski <jef...@gm...> wrote: > > after all the includes I included this > > > > #define __KERNEL__ > > #include <asm-arm/posix_types.h> > > This is almost certainly the wrong thing to do. > > The file build_arm_nofpu/staging_dir/include/select.h seems to have > the correct defintions of FD_ZERO for user mode code (and it includes > bits/select.h which has the definition of __FD_ZERO) > > -- > Dave Hylands > Vancouver, BC, Canada > http://www.DaveHylands.com/ > > ------------------------------------------------------------------------- > This SF.net email is sponsored by DB2 Express > Download DB2 Express C - the FREE version of DB2 express and take > control of your XML. No limits. Just data. Click to get it now. > http://sourceforge.net/powerbar/db2/ > _______________________________________________ > gumstix-users mailing list > gum...@li... > https://lists.sourceforge.net/lists/listinfo/gumstix-users > |
From: Jeff S. <jef...@gm...> - 2007-05-15 16:20:01
|
oooh I'm thinking it may have an issue with while(0) hmm this seems to be put there as a scope thing I'll see if I can remove the do and the while(0) so from #define __FD_ZERO(s) \ do { \ unsigned int __i; \ fd_set *__arr = (s); \ for (__i = 0; __i < sizeof (fd_set) / sizeof (__fd_mask); ++__i) \ __FDS_BITS (__arr)[__i] = 0; \ } while (0) to #define __FD_ZERO(s) \ { \ unsigned int __i; \ fd_set *__arr = (s); \ for (__i = 0; __i < sizeof (fd_set) / sizeof (__fd_mask); ++__i) \ __FDS_BITS (__arr)[__i] = 0; \ } and wala now im at my next error yes that was definatly it. I'm not sure if my fix is 100% when you add a layer of scope it should be ok {} adds a scope from what I remember and the while(0) was probably to loop through once. there is another way by introducing a variable set in the loop and set it to zero thanks for getting me further. seems the newer gccs don't like while(0) ;-) On 5/15/07, Jeff Sadowski <jef...@gm...> wrote: > ah ok I'll take a look at that then > actually its > sys/select.h with FD_ZERO and > bits/select.h with __FD_ZERO > > I suspect a problem in bits/select.h > I'll try and reproduce the error with simple code and try and fix it > to do what it is suppose to. > > On 5/15/07, Dave Hylands <dhy...@gm...> wrote: > > Hi Jeff, > > > > On 5/15/07, Jeff Sadowski <jef...@gm...> wrote: > > > after all the includes I included this > > > > > > #define __KERNEL__ > > > #include <asm-arm/posix_types.h> > > > > This is almost certainly the wrong thing to do. > > > > The file build_arm_nofpu/staging_dir/include/select.h seems to have > > the correct defintions of FD_ZERO for user mode code (and it includes > > bits/select.h which has the definition of __FD_ZERO) > > > > -- > > Dave Hylands > > Vancouver, BC, Canada > > http://www.DaveHylands.com/ > > > > ------------------------------------------------------------------------- > > This SF.net email is sponsored by DB2 Express > > Download DB2 Express C - the FREE version of DB2 express and take > > control of your XML. No limits. Just data. Click to get it now. > > http://sourceforge.net/powerbar/db2/ > > _______________________________________________ > > gumstix-users mailing list > > gum...@li... > > https://lists.sourceforge.net/lists/listinfo/gumstix-users > > > |
From: Jeff S. <jef...@gm...> - 2007-05-15 16:22:52
|
nope that wasn't it its still erroring at the same place On 5/15/07, Jeff Sadowski <jef...@gm...> wrote: > oooh I'm thinking it may have an issue with while(0) > hmm this seems to be put there as a scope thing I'll see if I can remove the do > and the while(0) > > so from > > #define __FD_ZERO(s) \ > do { \ > unsigned int __i; \ > fd_set *__arr = (s); \ > for (__i = 0; __i < sizeof (fd_set) / sizeof (__fd_mask); ++__i) \ > __FDS_BITS (__arr)[__i] = 0; \ > } while (0) > > > to > > #define __FD_ZERO(s) \ > { \ > unsigned int __i; \ > fd_set *__arr = (s); \ > for (__i = 0; __i < sizeof (fd_set) / sizeof (__fd_mask); ++__i) \ > __FDS_BITS (__arr)[__i] = 0; \ > } > > and wala now im at my next error yes that was definatly it. > I'm not sure if my fix is 100% when you add a layer of scope it should be ok > {} adds a scope from what I remember and the while(0) was probably to > loop through once. > there is another way by introducing a variable set in the loop and set > it to zero > > thanks for getting me further. seems the newer gccs don't like while(0) ;-) > > On 5/15/07, Jeff Sadowski <jef...@gm...> wrote: > > ah ok I'll take a look at that then > > actually its > > sys/select.h with FD_ZERO and > > bits/select.h with __FD_ZERO > > > > I suspect a problem in bits/select.h > > I'll try and reproduce the error with simple code and try and fix it > > to do what it is suppose to. > > > > On 5/15/07, Dave Hylands <dhy...@gm...> wrote: > > > Hi Jeff, > > > > > > On 5/15/07, Jeff Sadowski <jef...@gm...> wrote: > > > > after all the includes I included this > > > > > > > > #define __KERNEL__ > > > > #include <asm-arm/posix_types.h> > > > > > > This is almost certainly the wrong thing to do. > > > > > > The file build_arm_nofpu/staging_dir/include/select.h seems to have > > > the correct defintions of FD_ZERO for user mode code (and it includes > > > bits/select.h which has the definition of __FD_ZERO) > > > > > > -- > > > Dave Hylands > > > Vancouver, BC, Canada > > > http://www.DaveHylands.com/ > > > > > > ------------------------------------------------------------------------- > > > This SF.net email is sponsored by DB2 Express > > > Download DB2 Express C - the FREE version of DB2 express and take > > > control of your XML. No limits. Just data. Click to get it now. > > > http://sourceforge.net/powerbar/db2/ > > > _______________________________________________ > > > gumstix-users mailing list > > > gum...@li... > > > https://lists.sourceforge.net/lists/listinfo/gumstix-users > > > > > > |
From: Dave H. <dhy...@gm...> - 2007-05-15 17:12:46
|
Hi Jeff, > oooh I'm thinking it may have an issue with while(0) > hmm this seems to be put there as a scope thing I'll see if I can remove the do > and the while(0) The do while (0) is a common construct for creating multiline macros. Removing it will almost certainly have no improvement and may cause code that did work to not work. For example if ( foo ) FD_ZERO( something ); else DoSomethingElse; will only compile properly when FD_ZERO is setup using the do {} while(0) - which incidentaly executes the contents exactly once, so I'm not sure why you would think its a problem. As far as I can tell there is nothing wrong with the these macros. I'm much more likely to suspect the code that's trying to use the macros. -- Dave Hylands Vancouver, BC, Canada http://www.DaveHylands.com/ |
From: Jeff S. <jef...@gm...> - 2007-05-15 20:42:28
|
no your right I found the macro isn't even getting put in. somehow it is not loading the header files correctly. On 5/15/07, Dave Hylands <dhy...@gm...> wrote: > Hi Jeff, > > > oooh I'm thinking it may have an issue with while(0) > > hmm this seems to be put there as a scope thing I'll see if I can remove the do > > and the while(0) > > The do while (0) is a common construct for creating multiline macros. > > Removing it will almost certainly have no improvement and may cause > code that did work to not work. For example > > if ( foo ) > FD_ZERO( something ); > else > DoSomethingElse; > > will only compile properly when FD_ZERO is setup using the do {} > while(0) - which incidentaly executes the contents exactly once, so > I'm not sure why you would think its a problem. > > As far as I can tell there is nothing wrong with the these macros. I'm > much more likely to suspect the code that's trying to use the macros. > > -- > Dave Hylands > Vancouver, BC, Canada > http://www.DaveHylands.com/ > > ------------------------------------------------------------------------- > This SF.net email is sponsored by DB2 Express > Download DB2 Express C - the FREE version of DB2 express and take > control of your XML. No limits. Just data. Click to get it now. > http://sourceforge.net/powerbar/db2/ > _______________________________________________ > gumstix-users mailing list > gum...@li... > https://lists.sourceforge.net/lists/listinfo/gumstix-users > |
From: Jeff S. <jef...@gm...> - 2007-05-15 22:06:32
|
ah ha I figured it out had nothing to do with the buildroot environment the makefile in the tools directory of lirc had flags -I/usr/include that was messing me up. On 5/15/07, Jeff Sadowski <jef...@gm...> wrote: > no your right I found the macro isn't even getting put in. > somehow it is not loading the header files correctly. > > On 5/15/07, Dave Hylands <dhy...@gm...> wrote: > > Hi Jeff, > > > > > oooh I'm thinking it may have an issue with while(0) > > > hmm this seems to be put there as a scope thing I'll see if I can remove the do > > > and the while(0) > > > > The do while (0) is a common construct for creating multiline macros. > > > > Removing it will almost certainly have no improvement and may cause > > code that did work to not work. For example > > > > if ( foo ) > > FD_ZERO( something ); > > else > > DoSomethingElse; > > > > will only compile properly when FD_ZERO is setup using the do {} > > while(0) - which incidentaly executes the contents exactly once, so > > I'm not sure why you would think its a problem. > > > > As far as I can tell there is nothing wrong with the these macros. I'm > > much more likely to suspect the code that's trying to use the macros. > > > > -- > > Dave Hylands > > Vancouver, BC, Canada > > http://www.DaveHylands.com/ > > > > ------------------------------------------------------------------------- > > This SF.net email is sponsored by DB2 Express > > Download DB2 Express C - the FREE version of DB2 express and take > > control of your XML. No limits. Just data. Click to get it now. > > http://sourceforge.net/powerbar/db2/ > > _______________________________________________ > > gumstix-users mailing list > > gum...@li... > > https://lists.sourceforge.net/lists/listinfo/gumstix-users > > > |
From: Jeff S. <jef...@gm...> - 2007-05-16 05:24:25
|
turns out that the lirc clients that come with lirc all all X based. when I used the --without-x it compiled nicely with no modifications. I downloaded lirccd separately and it compiled with no issues. I can't wait to try it whe my device gets here. I bought one of these http://iguanaworks.net/product1.psp On 5/15/07, Jeff Sadowski <jef...@gm...> wrote: > ah ha I figured it out had nothing to do with the buildroot environment > > the makefile in the tools directory of lirc had flags -I/usr/include > that was messing me up. > > On 5/15/07, Jeff Sadowski <jef...@gm...> wrote: > > no your right I found the macro isn't even getting put in. > > somehow it is not loading the header files correctly. > > > > On 5/15/07, Dave Hylands <dhy...@gm...> wrote: > > > Hi Jeff, > > > > > > > oooh I'm thinking it may have an issue with while(0) > > > > hmm this seems to be put there as a scope thing I'll see if I can remove the do > > > > and the while(0) > > > > > > The do while (0) is a common construct for creating multiline macros. > > > > > > Removing it will almost certainly have no improvement and may cause > > > code that did work to not work. For example > > > > > > if ( foo ) > > > FD_ZERO( something ); > > > else > > > DoSomethingElse; > > > > > > will only compile properly when FD_ZERO is setup using the do {} > > > while(0) - which incidentaly executes the contents exactly once, so > > > I'm not sure why you would think its a problem. > > > > > > As far as I can tell there is nothing wrong with the these macros. I'm > > > much more likely to suspect the code that's trying to use the macros. > > > > > > -- > > > Dave Hylands > > > Vancouver, BC, Canada > > > http://www.DaveHylands.com/ > > > > > > ------------------------------------------------------------------------- > > > This SF.net email is sponsored by DB2 Express > > > Download DB2 Express C - the FREE version of DB2 express and take > > > control of your XML. No limits. Just data. Click to get it now. > > > http://sourceforge.net/powerbar/db2/ > > > _______________________________________________ > > > gumstix-users mailing list > > > gum...@li... > > > https://lists.sourceforge.net/lists/listinfo/gumstix-users > > > > > > |