Don't set _POSIX_C_SOURCE for VXI/RPC related files.
Make vxi.h the first #include in all affected files and #undef the _POSIX_C_SOURCE macro in vxi.h. This avoids various build issues on e.g. FreeBSD or Mac OS X where setting _POSIX_C_SOURCE leads to the unavailability of certain types such as u_long (as used in the VXI/RPC code).
This commit is contained in:
parent
c05a0ba528
commit
d40b8557a9
|
@ -20,9 +20,9 @@
|
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include "vxi.h"
|
||||
#include <rpc/rpc.h>
|
||||
#include <string.h>
|
||||
#include "vxi.h"
|
||||
#include <libsigrok/libsigrok.h>
|
||||
#include "libsigrok-internal.h"
|
||||
#include "scpi.h"
|
||||
|
|
|
@ -3,6 +3,8 @@
|
|||
* It was generated using rpcgen.
|
||||
*/
|
||||
|
||||
#undef _POSIX_C_SOURCE
|
||||
|
||||
#ifndef _VXI_H_RPCGEN
|
||||
#define _VXI_H_RPCGEN
|
||||
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
* It was generated using rpcgen.
|
||||
*/
|
||||
|
||||
#include <memory.h> /* for memset */
|
||||
#include "vxi.h"
|
||||
#include <memory.h> /* for memset */
|
||||
|
||||
/* Default timeout can be changed using clnt_control() */
|
||||
static struct timeval TIMEOUT = { 25, 0 };
|
||||
|
|
Loading…
Reference in New Issue