Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for aarch64 #140

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ else if (ArchLoader.IS_AIX) {
if (ArchName.is64()) {
getProject().setProperty("jni.arch64", "true");
if (ArchLoader.IS_LINUX) {
if (!osArch.equals("ia64")) {
if (!osArch.equals("ia64") && !osArch.equals("aarch64")) {
getProject().setProperty("jni.gccm", "-m64");
}
}
Expand Down
6 changes: 3 additions & 3 deletions include/sigar_util.h
Original file line number Diff line number Diff line change
Expand Up @@ -75,11 +75,11 @@ int sigar_inet_ntoa(sigar_t *sigar,
struct hostent *sigar_gethostbyname(const char *name,
sigar_hostent_t *data);

SIGAR_INLINE char *sigar_skip_line(char *buffer, int buflen);
char *sigar_skip_line(char *buffer, int buflen);

SIGAR_INLINE char *sigar_skip_token(char *p);
char *sigar_skip_token(char *p);

SIGAR_INLINE char *sigar_skip_multiple_token(char *p, int count);
char *sigar_skip_multiple_token(char *p, int count);

char *sigar_getword(char **line, char stop);

Expand Down
1 change: 1 addition & 0 deletions src/os/linux/linux_sigar.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
#include <sys/stat.h>
#include <sys/times.h>
#include <sys/utsname.h>
#include <sys/sysmacros.h>

#include "sigar.h"
#include "sigar_private.h"
Expand Down
8 changes: 4 additions & 4 deletions src/sigar_util.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
#include <dirent.h>
#include <sys/stat.h>

SIGAR_INLINE char *sigar_uitoa(char *buf, unsigned int n, int *len)
char *sigar_uitoa(char *buf, unsigned int n, int *len)
{
char *start = buf + UITOA_BUFFER_SIZE - 1;

Expand All @@ -46,22 +46,22 @@ SIGAR_INLINE char *sigar_uitoa(char *buf, unsigned int n, int *len)
return start;
}

SIGAR_INLINE char *sigar_skip_line(char *buffer, int buflen)
char *sigar_skip_line(char *buffer, int buflen)
{
char *ptr = buflen ?
(char *)memchr(buffer, '\n', buflen) : /* bleh */
strchr(buffer, '\n');
return ++ptr;
}

SIGAR_INLINE char *sigar_skip_token(char *p)
char *sigar_skip_token(char *p)
{
while (sigar_isspace(*p)) p++;
while (*p && !sigar_isspace(*p)) p++;
return p;
}

SIGAR_INLINE char *sigar_skip_multiple_token(char *p, int count)
char *sigar_skip_multiple_token(char *p, int count)
{
int i;

Expand Down