svn commit: r433881 - in head/sysutils: . lttng-tools lttng-tools/files lttng-ust lttng-ust/files
Mahdi Mokhtari
mmokhi at FreeBSD.org
Sat Feb 11 15:36:23 UTC 2017
Author: mmokhi
Date: Sat Feb 11 15:36:17 2017
New Revision: 433881
URL: https://svnweb.freebsd.org/changeset/ports/433881
Log:
Adding sysutils/lttng-ust and sysutils/lttng-tools.
LTTng stands for Linux Trace Toolkit: next generation. It's a modern toolkit
for tracing Linux (And now FreeBSD, only userspace now) programs.
PR: 216142
Submitted by: mmokhi
Reported by: mmokhi
Reviewed by: feld, mat
Approved by: feld, mat (mentors)
Differential Revision: https://reviews.freebsd.org/D9200
Added:
head/sysutils/lttng-tools/
head/sysutils/lttng-tools/Makefile (contents, props changed)
head/sysutils/lttng-tools/distinfo (contents, props changed)
head/sysutils/lttng-tools/files/
head/sysutils/lttng-tools/files/patch-configure.ac (contents, props changed)
head/sysutils/lttng-tools/files/patch-include_Makefile.am (contents, props changed)
head/sysutils/lttng-tools/files/patch-src_bin_lttng-crash_lttng-crash.c (contents, props changed)
head/sysutils/lttng-tools/files/patch-src_bin_lttng-relayd_stream.c (contents, props changed)
head/sysutils/lttng-tools/files/patch-src_bin_lttng-sessiond_consumer.c (contents, props changed)
head/sysutils/lttng-tools/files/patch-src_bin_lttng-sessiond_session.h (contents, props changed)
head/sysutils/lttng-tools/files/patch-src_bin_lttng-sessiond_ust-consumer.c (contents, props changed)
head/sysutils/lttng-tools/files/patch-src_bin_lttng-sessiond_ust-metadata.c (contents, props changed)
head/sysutils/lttng-tools/files/patch-src_bin_lttng-sessiond_utils.h (contents, props changed)
head/sysutils/lttng-tools/files/patch-src_bin_lttng_commands_view.c (contents, props changed)
head/sysutils/lttng-tools/files/patch-src_common_common.h (contents, props changed)
head/sysutils/lttng-tools/files/patch-src_common_compat_compat-epoll.c (contents, props changed)
head/sysutils/lttng-tools/files/patch-src_common_compat_compat-poll.c (contents, props changed)
head/sysutils/lttng-tools/files/patch-src_common_compat_endian.h (contents, props changed)
head/sysutils/lttng-tools/files/patch-src_common_compat_fcntl.h (contents, props changed)
head/sysutils/lttng-tools/files/patch-src_common_defaults.h (contents, props changed)
head/sysutils/lttng-tools/files/patch-src_common_kernel-consumer_kernel-consumer.h (contents, props changed)
head/sysutils/lttng-tools/files/patch-src_common_testpoint_Makefile.am (contents, props changed)
head/sysutils/lttng-tools/files/patch-src_common_utils.h (contents, props changed)
head/sysutils/lttng-tools/files/patch-tests_regression_kernel_select__poll__epoll.c (contents, props changed)
head/sysutils/lttng-tools/files/patch-tests_regression_ust_baddr-statedump_Makefile.am (contents, props changed)
head/sysutils/lttng-tools/files/patch-tests_regression_ust_linking_Makefile.am (contents, props changed)
head/sysutils/lttng-tools/files/patch-tests_regression_ust_ust-dl_Makefile.am (contents, props changed)
head/sysutils/lttng-tools/files/patch-tests_regression_ust_ust-dl_prog.c (contents, props changed)
head/sysutils/lttng-tools/pkg-descr (contents, props changed)
head/sysutils/lttng-tools/pkg-plist (contents, props changed)
head/sysutils/lttng-ust/
head/sysutils/lttng-ust/Makefile (contents, props changed)
head/sysutils/lttng-ust/distinfo (contents, props changed)
head/sysutils/lttng-ust/files/
head/sysutils/lttng-ust/files/patch-config_libtool.m4 (contents, props changed)
head/sysutils/lttng-ust/files/patch-doc_examples_clock-override_Makefile (contents, props changed)
head/sysutils/lttng-ust/files/patch-doc_examples_demo-tracef_Makefile (contents, props changed)
head/sysutils/lttng-ust/files/patch-doc_examples_demo-tracelog_Makefile (contents, props changed)
head/sysutils/lttng-ust/files/patch-doc_examples_demo_Makefile (contents, props changed)
head/sysutils/lttng-ust/files/patch-doc_examples_easy-ust_Makefile (contents, props changed)
head/sysutils/lttng-ust/files/patch-doc_examples_gen-tp_Makefile (contents, props changed)
head/sysutils/lttng-ust/files/patch-doc_examples_getcpu-override_Makefile (contents, props changed)
head/sysutils/lttng-ust/files/patch-doc_examples_hello-static-lib_Makefile (contents, props changed)
head/sysutils/lttng-ust/files/patch-doc_man_lttng-ust.3 (contents, props changed)
head/sysutils/lttng-ust/files/patch-doc_man_lttng-ust.3.txt (contents, props changed)
head/sysutils/lttng-ust/files/patch-include_lttng_ust-dlfcn.h (contents, props changed)
head/sysutils/lttng-ust/files/patch-include_lttng_ust-elf.h (contents, props changed)
head/sysutils/lttng-ust/files/patch-include_lttng_ust-tracepoint-event.h (contents, props changed)
head/sysutils/lttng-ust/files/patch-liblttng-ust-ctl_Makefile.am (contents, props changed)
head/sysutils/lttng-ust/files/patch-liblttng-ust-ctl_Makefile.in (contents, props changed)
head/sysutils/lttng-ust/files/patch-liblttng-ust-ctl_ustctl.c (contents, props changed)
head/sysutils/lttng-ust/files/patch-liblttng-ust-dl_ust__dl.h (contents, props changed)
head/sysutils/lttng-ust/files/patch-liblttng-ust_Makefile.am (contents, props changed)
head/sysutils/lttng-ust/files/patch-liblttng-ust_Makefile.in (contents, props changed)
head/sysutils/lttng-ust/files/patch-lttng-ust.pc.in (contents, props changed)
head/sysutils/lttng-ust/files/patch-tests_gcc-weak-hidden_Makefile.am (contents, props changed)
head/sysutils/lttng-ust/files/patch-tests_ust-elf_Makefile.am (contents, props changed)
head/sysutils/lttng-ust/files/patch-tools_lttng-gen-tp (contents, props changed)
head/sysutils/lttng-ust/pkg-descr (contents, props changed)
head/sysutils/lttng-ust/pkg-plist (contents, props changed)
Modified:
head/sysutils/Makefile
Modified: head/sysutils/Makefile
==============================================================================
--- head/sysutils/Makefile Sat Feb 11 15:32:33 2017 (r433880)
+++ head/sysutils/Makefile Sat Feb 11 15:36:17 2017 (r433881)
@@ -555,6 +555,8 @@
SUBDIR += lr
SUBDIR += lsof
SUBDIR += ltrace
+ SUBDIR += lttng-tools
+ SUBDIR += lttng-ust
SUBDIR += luckybackup
SUBDIR += lxinput
SUBDIR += lxsplit
Added: head/sysutils/lttng-tools/Makefile
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/Makefile Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,36 @@
+# Created by: Mahdi Mokhtari <mokhi64 at gmail.com>
+# $FreeBSD$
+
+PORTNAME= lttng-tools
+PORTVERSION= 2.9.0
+CATEGORIES= sysutils
+MASTER_SITES= http://lttng.org/files/${PORTNAME}/
+
+MAINTAINER= mokhi64 at gmail.com
+COMMENT= Set of tools to control LTTng tracing
+
+LICENSE= LGPL21 GPLv2
+LICENSE_COMB= dual
+LICENSE_FILE_LGPL21= ${WRKSRC}/lgpl-2.1.txt
+LICENSE_FILE_GPLv2= ${WRKSRC}/gpl-2.0.txt
+
+LIB_DEPENDS= libpopt.so:devel/popt \
+ liburcu.so:sysutils/liburcu \
+ liblttng-ust-ctl.so:sysutils/lttng-ust
+
+USES= autoreconf bison libtool localbase pathfix \
+ shebangfix tar:bzip2
+USE_LDCONFIG= yes
+USE_GNOME= libxml2
+
+GNU_CONFIGURE= yes
+CONFIGURE_ARGS= --with-lttng-ust-prefix=${LOCALBASE} \
+ --disable-maintainer-mode
+INSTALL_TARGET= install-strip
+
+post-install:
+ ${INSTALL_MAN} ${WRKSRC}/doc/man/*.1 ${STAGEDIR}${MANPREFIX}/man/man1/
+ ${INSTALL_MAN} ${WRKSRC}/doc/man/*.3 ${STAGEDIR}${MANPREFIX}/man/man3/
+ ${INSTALL_MAN} ${WRKSRC}/doc/man/*.8 ${STAGEDIR}${MANPREFIX}/man/man8/
+
+.include <bsd.port.mk>
Added: head/sysutils/lttng-tools/distinfo
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/distinfo Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,3 @@
+TIMESTAMP = 1483798712
+SHA256 (lttng-tools-2.9.0.tar.bz2) = eff3003f3c37ae8f2921ba76de777171405935eec48f4c1a15abdda8d0859422
+SIZE (lttng-tools-2.9.0.tar.bz2) = 1150584
Added: head/sysutils/lttng-tools/files/patch-configure.ac
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-configure.ac Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,11 @@
+--- configure.ac.orig 2016-11-29 22:48:37 UTC
++++ configure.ac
+@@ -443,7 +443,7 @@ AS_IF([test "x$lttng_ust_support" = "xye
+ lttng_ust_ctl_found=yes
+ ],
+ [AC_MSG_ERROR([Cannot find LTTng-UST >= 2.2.x. Use --with-lttng-ust-prefix=PREFIX to specify its location, or specify --without-lttng-ust to build lttng-tools without LTTng-UST support.])],
+- [-lurcu-common -lurcu-bp -lurcu-cds -lrt -ldl]
++ [-lurcu-common -lurcu-bp -lurcu-cds -lrt]
+ )
+ ])
+ AM_CONDITIONAL([HAVE_LIBLTTNG_UST_CTL], [test "x$lttng_ust_ctl_found" = xyes])
Added: head/sysutils/lttng-tools/files/patch-include_Makefile.am
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-include_Makefile.am Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,17 @@
+--- include/Makefile.am.orig 2017-01-12 17:07:16 UTC
++++ include/Makefile.am
+@@ -1,8 +1,8 @@
+-if LTTNG_TOOLS_BUILD_GIT_SOURCE
+-GIT_DESCRIBE_CMD = (cd $(top_srcdir); git describe)
+-else
+-GIT_DESCRIBE_CMD = /bin/true
+-endif
++##if LTTNG_TOOLS_BUILD_GIT_SOURCE
++##GIT_DESCRIBE_CMD = (cd ${top_srcdir}; git describe)
++##else
++GIT_DESCRIBE_CMD = /usr/bin/true
++##endif
+
+ ##
+ ## The version.h file must be verified and generated or updated if the
+
Added: head/sysutils/lttng-tools/files/patch-src_bin_lttng-crash_lttng-crash.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-src_bin_lttng-crash_lttng-crash.c Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,33 @@
+--- src/bin/lttng-crash/lttng-crash.c.orig 2016-11-29 22:48:37 UTC
++++ src/bin/lttng-crash/lttng-crash.c
+@@ -21,17 +21,29 @@
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <string.h>
+-#include <sys/stat.h>
+ #include <sys/types.h>
+ #include <sys/stat.h>
+ #include <sys/mman.h>
+ #include <fcntl.h>
+ #include <sys/wait.h>
+ #include <unistd.h>
+ #include <ctype.h>
+ #include <dirent.h>
++#if defined(__FreeBSD__)
++#include <sys/types.h>
++#include <sys/endian.h>
++#include <inttypes.h>
++#define bswap_16 bswap16
++#define bswap_32 bswap32
++#define bswap_64 bswap64
++#define __bswap_16 bswap16
++#define __bswap_32 bswap32
++#define __bswap_64 bswap64
++#define NT_GNU_BUILD_ID 3
++#else
+ #include <byteswap.h>
+ #include <inttypes.h>
++#endif
+ #include <stdbool.h>
+
+ #include <version.h>
Added: head/sysutils/lttng-tools/files/patch-src_bin_lttng-relayd_stream.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-src_bin_lttng-relayd_stream.c Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,10 @@
+--- src/bin/lttng-relayd/stream.c.orig 2016-11-29 22:48:37 UTC
++++ src/bin/lttng-relayd/stream.c
+@@ -22,6 +22,7 @@
+ #include <common/utils.h>
+ #include <common/defaults.h>
+ #include <urcu/rculist.h>
++#include <sys/types.h>
+ #include <sys/stat.h>
+
+ #include "lttng-relayd.h"
Added: head/sysutils/lttng-tools/files/patch-src_bin_lttng-sessiond_consumer.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-src_bin_lttng-sessiond_consumer.c Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,12 @@
+--- src/bin/lttng-sessiond/consumer.c.orig 2016-11-29 22:48:37 UTC
++++ src/bin/lttng-sessiond/consumer.c
+@@ -635,6 +635,9 @@ int consumer_set_network_uri(struct cons
+ {
+ int ret;
+ char tmp_path[PATH_MAX];
++#if defined(__FreeBSD__)
++ const size_t HOST_NAME_MAX = sysconf(_SC_HOST_NAME_MAX);
++#endif
+ char hostname[HOST_NAME_MAX];
+ struct lttng_uri *dst_uri = NULL;
+
Added: head/sysutils/lttng-tools/files/patch-src_bin_lttng-sessiond_session.h
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-src_bin_lttng-sessiond_session.h Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,14 @@
+--- src/bin/lttng-sessiond/session.h.orig 2016-11-29 22:48:37 UTC
++++ src/bin/lttng-sessiond/session.h
+@@ -60,7 +60,11 @@ struct ltt_session_list {
+ */
+ struct ltt_session {
+ char name[NAME_MAX];
++#if defined(__FreeBSD__)
++ char hostname[256]; /* Local hostname. */
++#else
+ char hostname[HOST_NAME_MAX]; /* Local hostname. */
++#endif
+ struct ltt_kernel_session *kernel_session;
+ struct ltt_ust_session *ust_session;
+ /*
Added: head/sysutils/lttng-tools/files/patch-src_bin_lttng-sessiond_ust-consumer.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-src_bin_lttng-sessiond_ust-consumer.c Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,11 @@
+--- src/bin/lttng-sessiond/ust-consumer.c.orig 2016-11-29 22:48:37 UTC
++++ src/bin/lttng-sessiond/ust-consumer.c
+@@ -21,6 +21,8 @@
+ #include <stdlib.h>
+ #include <string.h>
+ #include <unistd.h>
++#include <sys/types.h>
++#include <sys/stat.h>
+ #include <inttypes.h>
+
+ #include <common/common.h>
Added: head/sysutils/lttng-tools/files/patch-src_bin_lttng-sessiond_ust-metadata.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-src_bin_lttng-sessiond_ust-metadata.c Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,28 @@
+--- src/bin/lttng-sessiond/ust-metadata.c.orig 2016-11-29 22:48:37 UTC
++++ src/bin/lttng-sessiond/ust-metadata.c
+@@ -50,6 +50,7 @@ int _lttng_field_statedump(struct ust_re
+ const struct ustctl_field *fields, size_t nr_fields,
+ size_t *iter_field, size_t nesting);
+
++#if !defined(__FreeBSD__)
+ static inline
+ int fls(unsigned int x)
+ {
+@@ -79,6 +80,7 @@ int fls(unsigned int x)
+ }
+ return r;
+ }
++#endif
+
+ static inline
+ int get_count_order(unsigned int count)
+@@ -879,6 +881,9 @@ int ust_metadata_session_statedump(struc
+ char uuid_s[UUID_STR_LEN],
+ clock_uuid_s[UUID_STR_LEN];
+ int ret = 0;
++#if defined(__FreeBSD__)
++ const size_t HOST_NAME_MAX = sysconf(_SC_HOST_NAME_MAX);
++#endif
+ char hostname[HOST_NAME_MAX];
+
+ assert(session);
Added: head/sysutils/lttng-tools/files/patch-src_bin_lttng-sessiond_utils.h
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-src_bin_lttng-sessiond_utils.h Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,12 @@
+--- src/bin/lttng-sessiond/utils.h.orig 2016-11-29 22:48:37 UTC
++++ src/bin/lttng-sessiond/utils.h
+@@ -18,6 +18,9 @@
+ #ifndef _LTT_UTILS_H
+ #define _LTT_UTILS_H
+
++#include <sys/types.h>
++#include <sys/stat.h>
++
+ struct lttng_ht;
+
+ const char *get_home_dir(void);
Added: head/sysutils/lttng-tools/files/patch-src_bin_lttng_commands_view.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-src_bin_lttng_commands_view.c Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,12 @@
+--- src/bin/lttng/commands/view.c.orig 2016-11-29 22:48:37 UTC
++++ src/bin/lttng/commands/view.c
+@@ -269,6 +269,9 @@ static char *build_live_path(char *sessi
+ {
+ int ret;
+ char *path = NULL;
++#if defined(__FreeBSD__)
++ const size_t HOST_NAME_MAX = sysconf(_SC_HOST_NAME_MAX);
++#endif
+ char hostname[HOST_NAME_MAX];
+
+ ret = gethostname(hostname, sizeof(hostname));
Added: head/sysutils/lttng-tools/files/patch-src_common_common.h
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-src_common_common.h Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,17 @@
+--- src/common/common.h.orig 2016-11-29 22:48:37 UTC
++++ src/common/common.h
+@@ -19,6 +19,14 @@
+ #ifndef _COMMON_H
+ #define _COMMON_H
+
++#if defined(__FreeBSD__)
++
++#include <sys/endian.h>
++
++#define ENODATA ENOATTR
++
++#endif
++
+ #include "error.h"
+ #include "macros.h"
+ #include "runas.h"
Added: head/sysutils/lttng-tools/files/patch-src_common_compat_compat-epoll.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-src_common_compat_compat-epoll.c Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,34 @@
+--- src/common/compat/compat-epoll.c.orig 2017-01-13 22:20:45 UTC
++++ src/common/compat/compat-epoll.c
+@@ -31,7 +31,11 @@
+
+ #include "poll.h"
+
+-unsigned int poll_max_size;
++unsigned int poll_max_size
++#if defined(__FreeBSD__)
++= DEFAULT_POLL_SIZE
++#endif
++;
+
+ /*
+ * Resize the epoll events structure of the new size.
+@@ -258,6 +262,7 @@ int compat_epoll_set_max_size(void)
+ ssize_t size_ret;
+ char buf[64];
+
++#if !defined(__FreeBSD__)
+ fd = open(COMPAT_EPOLL_PROC_PATH, O_RDONLY);
+ if (fd < 0) {
+ retval = -1;
+@@ -282,8 +287,10 @@ end_read:
+ PERROR("close");
+ }
+ end:
++#endif
+ if (!poll_max_size) {
+ poll_max_size = DEFAULT_POLL_SIZE;
++ retval = 0;
+ }
+ DBG("epoll set max size is %d", poll_max_size);
+ return retval;
Added: head/sysutils/lttng-tools/files/patch-src_common_compat_compat-poll.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-src_common_compat_compat-poll.c Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,14 @@
+--- src/common/compat/compat-poll.c.orig 2017-01-13 22:38:05 UTC
++++ src/common/compat/compat-poll.c
+@@ -112,7 +112,11 @@ int compat_poll_create(struct lttng_poll
+
+ if (!poll_max_size) {
+ ERR("poll_max_size not initialized yet");
++#if defined(__FreeBSD__)
++ poll_max_size = DEFAULT_POLL_SIZE;
++#else
+ goto error;
++#endif
+ }
+
+ /* Don't bust the limit here */
Added: head/sysutils/lttng-tools/files/patch-src_common_compat_endian.h
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-src_common_compat_endian.h Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,23 @@
+--- src/common/compat/endian.h.orig 2016-11-29 22:48:37 UTC
++++ src/common/compat/endian.h
+@@ -27,7 +27,19 @@
+ */
+ #ifdef __USE_BSD
+ /* Conversion interfaces. */
+-# include <byteswap.h>
++#if defined(__FreeBSD__)
++#include <sys/types.h>
++#include <sys/endian.h>
++#define bswap_16 bswap16
++#define bswap_32 bswap32
++#define bswap_64 bswap64
++#define __bswap_16 bswap16
++#define __bswap_32 bswap32
++#define __bswap_64 bswap64
++#define NT_GNU_BUILD_ID 3
++#else
++#include <byteswap.h>
++#endif
+
+ # if __BYTE_ORDER == __LITTLE_ENDIAN
+ # ifndef htobe16
Added: head/sysutils/lttng-tools/files/patch-src_common_compat_fcntl.h
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-src_common_compat_fcntl.h Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,35 @@
+--- src/common/compat/fcntl.h.orig 2016-11-29 22:48:37 UTC
++++ src/common/compat/fcntl.h
+@@ -22,11 +22,15 @@
+ #include <errno.h>
+ #include <sys/types.h>
+
+ #if (defined(__FreeBSD__) || defined(__CYGWIN__))
+ typedef long long off64_t;
+ #endif
+
+-#if (defined(__FreeBSD__) || defined(__sun__))
++#if defined(__FreeBSD__)
++typedef off_t loff_t;
++#endif
++
++#if defined(__sun__)
+ typedef off64_t loff_t;
+ #endif
+
+@@ -69,15 +73,6 @@ static inline ssize_t splice(int fd_in,
+ }
+ #endif
+
+-#ifdef __FreeBSD__
+-#define POSIX_FADV_DONTNEED 0
+-
+-static inline int posix_fadvise(int fd, off_t offset, off_t len, int advice)
+-{
+- return -ENOSYS;
+-}
+-#endif
+-
+ #if !(defined(__linux__) || defined(__FreeBSD__) || defined(__CYGWIN__) || defined(__sun__) || defined(__APPLE__))
+ #error "Please add support for your OS."
+ #endif /* __linux__ , __FreeBSD__, __CYGWIN__, __sun__, __APPLE__ */
Added: head/sysutils/lttng-tools/files/patch-src_common_defaults.h
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-src_common_defaults.h Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,12 @@
+--- src/common/defaults.h.orig 2016-11-29 22:48:37 UTC
++++ src/common/defaults.h
+@@ -366,6 +366,9 @@ size_t default_get_ust_uid_channel_subbu
+ * pthread_attr_t pointer where the thread stack size is set to the soft stack
+ * size limit.
+ */
++#if defined(__FreeBSD__)
++#include <pthread.h>
++#endif
+ LTTNG_HIDDEN
+ pthread_attr_t *default_pthread_attr(void);
+
Added: head/sysutils/lttng-tools/files/patch-src_common_kernel-consumer_kernel-consumer.h
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-src_common_kernel-consumer_kernel-consumer.h Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,11 @@
+--- src/common/kernel-consumer/kernel-consumer.h.orig 2016-11-29 22:48:37 UTC
++++ src/common/kernel-consumer/kernel-consumer.h
+@@ -19,6 +19,8 @@
+ #ifndef _LTTNG_KCONSUMER_H
+ #define _LTTNG_KCONSUMER_H
+
++#include <errno.h>
++
+ #include <common/consumer/consumer.h>
+
+ int lttng_kconsumer_take_snapshot(struct lttng_consumer_stream *stream);
Added: head/sysutils/lttng-tools/files/patch-src_common_testpoint_Makefile.am
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-src_common_testpoint_Makefile.am Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,8 @@
+--- src/common/testpoint/Makefile.am.orig 2017-01-12 17:07:16 UTC
++++ src/common/testpoint/Makefile.am
+@@ -3,4 +3,4 @@ AM_CPPFLAGS =
+ noinst_LTLIBRARIES = libtestpoint.la
+
+ libtestpoint_la_SOURCES = testpoint.h testpoint.c
+-libtestpoint_la_LIBADD = -ldl
++libtestpoint_la_LIBADD =
Added: head/sysutils/lttng-tools/files/patch-src_common_utils.h
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-src_common_utils.h Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,10 @@
+--- src/common/utils.h.orig 2016-11-29 22:48:37 UTC
++++ src/common/utils.h
+@@ -19,6 +19,7 @@
+ #define _COMMON_UTILS_H
+
+ #include <sys/types.h>
++#include <sys/stat.h>
+ #include <unistd.h>
+ #include <stdint.h>
+ #include <getopt.h>
Added: head/sysutils/lttng-tools/files/patch-tests_regression_kernel_select__poll__epoll.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-tests_regression_kernel_select__poll__epoll.c Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,122 @@
+--- tests/regression/kernel/select_poll_epoll.c.orig 2016-11-29 22:48:37 UTC
++++ tests/regression/kernel/select_poll_epoll.c
+@@ -10,7 +10,9 @@
+ #include <string.h>
+ #include <stddef.h>
+ #include <sys/select.h>
++#if !defined(__FreeBSD__)
+ #include <sys/epoll.h>
++#endif
+ #include <popt.h>
+ #include <sys/time.h>
+ #include <sys/resource.h>
+@@ -249,6 +251,7 @@ void test_ppoll_big(void)
+ return;
+ }
+
++#if !defined(__FreeBSD__)
+ void test_epoll(void)
+ {
+ int ret, epollfd;
+@@ -332,6 +335,7 @@ void test_pepoll(void)
+ end:
+ return;
+ }
++#endif
+
+ void run_working_cases(void)
+ {
+@@ -356,8 +360,10 @@ void run_working_cases(void)
+ test_select_big();
+ test_poll();
+ test_ppoll();
++#if !defined(__FreeBSD__)
+ test_epoll();
+ test_pepoll();
++#endif
+
+ if (timeout > 0) {
+ ret = close(pipe_fds[0]);
+@@ -458,7 +464,11 @@ void pselect_fd_too_big(void)
+ }
+
+ FD_SET(fd2, (fd_set *) &rfds);
++#if defined(__FreeBSD__)
++ ret = __syscall(SYS_pselect, fd2 + 1, &rfds, NULL, NULL, NULL, NULL);
++#else
+ ret = syscall(SYS_pselect6, fd2 + 1, &rfds, NULL, NULL, NULL, NULL);
++#endif
+
+ if (ret == -1) {
+ perror("# pselect()");
+@@ -487,9 +497,13 @@ void pselect_invalid_pointer(void)
+
+ FD_ZERO(&rfds);
+ FD_SET(wait_fd, &rfds);
+-
++#if defined(__FreeBSD__)
++ ret = __syscall(SYS_pselect, 1, &rfds, (fd_set *) invalid, NULL, NULL,
++ NULL);
++#else
+ ret = syscall(SYS_pselect6, 1, &rfds, (fd_set *) invalid, NULL, NULL,
+ NULL);
++#endif
+
+ if (ret == -1) {
+ perror("# pselect()");
+@@ -505,6 +519,7 @@ void pselect_invalid_pointer(void)
+
+ }
+
++#if !defined(__FreeBSD__)
+ /*
+ * Pass an invalid pointer to epoll_pwait, should fail with
+ * "Bad address", the event returns 0 FDs.
+@@ -591,6 +606,7 @@ void epoll_pwait_int_max(void)
+ end:
+ return;
+ }
++#endif
+
+ void *ppoll_writer(void *arg)
+ {
+@@ -700,6 +716,7 @@ void ppoll_concurrent_write(void)
+ return;
+ }
+
++#if !defined(__FreeBSD__)
+ void *epoll_pwait_writer(void *addr)
+ {
+ srand(time(NULL));
+@@ -795,6 +812,7 @@ end_unmap:
+ end:
+ return;
+ }
++#endif
+
+ void usage(poptContext optCon, int exitcode, char *error, char *addl)
+ {
+@@ -906,18 +924,20 @@ int main(int argc, const char **argv)
+ case 7:
+ ppoll_fds_ulong_max();
+ break;
++#if !defined(__FreeBSD__)
+ case 8:
+ epoll_pwait_invalid_pointer();
+ break;
+ case 9:
+ epoll_pwait_int_max();
+ break;
+- case 10:
+- ppoll_concurrent_write();
+- break;
+ case 11:
+ epoll_pwait_concurrent_munmap();
+ break;
++#endif
++ case 10:
++ ppoll_concurrent_write();
++ break;
+ default:
+ poptPrintUsage(optCon, stderr, 0);
+ ret = -1;
Added: head/sysutils/lttng-tools/files/patch-tests_regression_ust_baddr-statedump_Makefile.am
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-tests_regression_ust_baddr-statedump_Makefile.am Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,11 @@
+--- tests/regression/ust/baddr-statedump/Makefile.am.orig 2017-01-12 17:10:21 UTC
++++ tests/regression/ust/baddr-statedump/Makefile.am
+@@ -6,7 +6,7 @@ AM_CPPFLAGS = -I$(srcdir) -g
+
+ noinst_PROGRAMS = prog
+ prog_SOURCES = prog.c tp.c tp.h
+-prog_LDADD = -llttng-ust -ldl
++prog_LDADD = -llttng-ust
+
+ noinst_SCRIPTS = test_baddr-statedump test_baddr-statedump.py
+ EXTRA_DIST = test_baddr-statedump test_baddr-statedump.py
Added: head/sysutils/lttng-tools/files/patch-tests_regression_ust_linking_Makefile.am
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-tests_regression_ust_linking_Makefile.am Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,45 @@
+--- tests/regression/ust/linking/Makefile.am.orig 2017-01-12 17:07:16 UTC
++++ tests/regression/ust/linking/Makefile.am
+@@ -10,6 +10,8 @@ LIBS =
+ demo_builtin_SOURCES = demo.c tp.c tp2.c tp3.c ust_tests_demo.h \
+ ust_tests_demo2.h ust_tests_demo3.h
+ demo_builtin_LDADD = -llttng-ust
++demo_builtin_LDFLAGS = \
++ -L/usr/local/lib
+ demo_builtin_CFLAGS = -Werror=old-style-definition
+
+ # Build a version statically linked to the providers
+@@ -22,12 +24,16 @@ liblttng_ust_provider_ust_tests_demo_sta
+ tp2.c ust_tests_demo2.h
+ liblttng_ust_provider_ust_tests_demo_static_la_LIBADD = \
+ -llttng-ust
++liblttng_ust_provider_ust_tests_demo_static_la_LDFLAGS = \
++ -L/usr/local/lib
+
+ # contains ust_tests_demo3.h provider probes
+ liblttng_ust_provider_ust_tests_demo3_static_la_SOURCES = \
+ tp3.c ust_tests_demo3.h
+ liblttng_ust_provider_ust_tests_demo3_static_la_LIBADD = \
+ -llttng-ust
++liblttng_ust_provider_ust_tests_demo3_static_la_LDFLAGS = \
++ -L/usr/local/lib
+
+ demo_static_SOURCES = demo.c
+ demo_static_LDADD = liblttng-ust-provider-ust-tests-demo-static.la \
+@@ -68,14 +74,14 @@ liblttng_ust_provider_ust_tests_demo_la_
+ tp2.c ust_tests_demo2.h
+ liblttng_ust_provider_ust_tests_demo_la_LIBADD = -llttng-ust
+ liblttng_ust_provider_ust_tests_demo_la_LDFLAGS = \
+- $(FORCE_SHARED_LIB_OPTIONS)
++ $(FORCE_SHARED_LIB_OPTIONS) -L/usr/local/lib
+
+ #contains ust_tests_demo3.h provider probes
+ liblttng_ust_provider_ust_tests_demo3_la_SOURCES = \
+ tp3.c ust_tests_demo3.h
+ liblttng_ust_provider_ust_tests_demo3_la_LIBADD = -llttng-ust
+ liblttng_ust_provider_ust_tests_demo3_la_LDFLAGS = \
+- $(FORCE_SHARED_LIB_OPTIONS)
++ $(FORCE_SHARED_LIB_OPTIONS) -L/usr/local/lib
+
+ noinst_PROGRAMS += demo
+ demo_SOURCES = demo.c ust_tests_demo.h
Added: head/sysutils/lttng-tools/files/patch-tests_regression_ust_ust-dl_Makefile.am
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-tests_regression_ust_ust-dl_Makefile.am Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,11 @@
+--- tests/regression/ust/ust-dl/Makefile.am.orig 2017-01-12 17:21:10 UTC
++++ tests/regression/ust/ust-dl/Makefile.am
+@@ -19,7 +19,7 @@ AM_CPPFLAGS = -I$(srcdir) -g
+
+ noinst_PROGRAMS = prog
+ prog_SOURCES = prog.c
+-prog_LDADD = -ldl
++prog_LDADD =
+
+ noinst_LTLIBRARIES = libzzz.la libbar.la libfoo.la libtp.la
+
Added: head/sysutils/lttng-tools/files/patch-tests_regression_ust_ust-dl_prog.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/files/patch-tests_regression_ust_ust-dl_prog.c Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,14 @@
+--- tests/regression/ust/ust-dl/prog.c.orig 2017-01-12 17:19:54 UTC
++++ tests/regression/ust/ust-dl/prog.c
+@@ -21,7 +21,11 @@ int main(int argc, char **argv)
+ if (!h0) {
+ goto get_error;
+ }
++#if defined(__FreeBSD__)
++ h1 = dlopen("libfoo.so", RTLD_LAZY);
++#else
+ h1 = dlmopen(LM_ID_BASE, "libfoo.so", RTLD_LAZY);
++#endif
+ if (!h1) {
+ goto get_error;
+ }
Added: head/sysutils/lttng-tools/pkg-descr
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/pkg-descr Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,7 @@
+LTTng-tools is a set of tools to control LTTng tracing.
+The project includes the LTTng session daemon
+consumer daemon and relay daemon, as well as liblttng-ctl,
+a C library used to communicate with the session daemon
+and lttng, a command line interface to liblttng-ctl.
+
+WWW: http://lttng.org/
Added: head/sysutils/lttng-tools/pkg-plist
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-tools/pkg-plist Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,61 @@
+bin/lttng
+bin/lttng-crash
+bin/lttng-relayd
+bin/lttng-sessiond
+include/lttng/channel.h
+include/lttng/constant.h
+include/lttng/domain.h
+include/lttng/event.h
+include/lttng/handle.h
+include/lttng/health.h
+include/lttng/load.h
+include/lttng/lttng-error.h
+include/lttng/lttng.h
+include/lttng/save.h
+include/lttng/session.h
+include/lttng/snapshot.h
+include/lttng/version.h.tmpl
+lib/liblttng-ctl.a
+lib/liblttng-ctl.so
+lib/liblttng-ctl.so.0
+lib/liblttng-ctl.so.0.0.0
+lib/lttng/libexec/lttng-consumerd
+libdata/pkgconfig/lttng-ctl.pc
+man/man1/lttng-add-context.1.gz
+man/man1/lttng-crash.1.gz
+man/man1/lttng-create.1.gz
+man/man1/lttng-destroy.1.gz
+man/man1/lttng-disable-channel.1.gz
+man/man1/lttng-disable-event.1.gz
+man/man1/lttng-enable-channel.1.gz
+man/man1/lttng-enable-event.1.gz
+man/man1/lttng-help.1.gz
+man/man1/lttng-list.1.gz
+man/man1/lttng-load.1.gz
+man/man1/lttng-metadata.1.gz
+man/man1/lttng-regenerate.1.gz
+man/man1/lttng-save.1.gz
+man/man1/lttng-set-session.1.gz
+man/man1/lttng-snapshot.1.gz
+man/man1/lttng-start.1.gz
+man/man1/lttng-status.1.gz
+man/man1/lttng-stop.1.gz
+man/man1/lttng-track.1.gz
+man/man1/lttng-untrack.1.gz
+man/man1/lttng-version.1.gz
+man/man1/lttng-view.1.gz
+man/man1/lttng.1.gz
+man/man3/lttng-health-check.3.gz
+man/man8/lttng-relayd.8.gz
+man/man8/lttng-sessiond.8.gz
+%%PORTDOCS%%%%DOCSDIR%%/ChangeLog
+%%PORTDOCS%%%%DOCSDIR%%/LICENSE
+%%PORTDOCS%%%%DOCSDIR%%/README.md
+%%PORTDOCS%%%%DOCSDIR%%/live-reading-howto.txt
+%%PORTDOCS%%%%DOCSDIR%%/live-reading-protocol.txt
+%%PORTDOCS%%%%DOCSDIR%%/python-howto.txt
+%%PORTDOCS%%%%DOCSDIR%%/quickstart.txt
+%%PORTDOCS%%%%DOCSDIR%%/snapshot-howto.txt
+%%PORTDOCS%%%%DOCSDIR%%/streaming-howto.txt
+%%PORTDOCS%%%%DOCSDIR%%/valgrind-howto.txt
+share/xml/lttng/session.xsd
Added: head/sysutils/lttng-ust/Makefile
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-ust/Makefile Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,31 @@
+# Created by: Mahdi Mokhtari <mokhi64 at gmail.com>
+# $FreeBSD$
+
+PORTNAME= lttng-ust
+PORTVERSION= 2.9.0
+CATEGORIES= sysutils
+MASTER_SITES= http://lttng.org/files/${PORTNAME}/
+
+MAINTAINER= mokhi64 at gmail.com
+COMMENT= Libraries to instrument and trace user applications
+
+LICENSE= LGPL21 MIT GPLv2
+LICENSE_COMB= dual
+LICENSE_FILE_LGPL21= ${WRKSRC}/COPYING
+LICENSE_FILE_MIT= ${WRKSRC}/COPYING
+LICENSE_FILE_GPLv2= ${WRKSRC}/COPYING
+
+LIB_DEPENDS= liburcu.so:sysutils/liburcu
+
+USES= autoreconf libtool localbase pathfix python \
+ shebangfix tar:bzip2
+USE_LDCONFIG= yes
+GNU_CONFIGURE= yes
+INSTALL_TARGET= install-strip
+TEST_TARGET= check
+
+post-patch:
+ @${REINPLACE_CMD} -e 's|%%PYTHON_VERSION%%|${PYTHON_VERSION}|g' \
+ ${PATCH_WRKSRC}/tools/lttng-gen-tp
+
+.include <bsd.port.mk>
Added: head/sysutils/lttng-ust/distinfo
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-ust/distinfo Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,3 @@
+TIMESTAMP = 1483807828
+SHA256 (lttng-ust-2.9.0.tar.bz2) = 4d541a863f42dfc685ca05024027a442c70d03594c154a43e62bc109b1ea5daf
+SIZE (lttng-ust-2.9.0.tar.bz2) = 764027
Added: head/sysutils/lttng-ust/files/patch-config_libtool.m4
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-ust/files/patch-config_libtool.m4 Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,15 @@
+--- config/libtool.m4.orig 2016-05-12 15:26:58 UTC
++++ config/libtool.m4
+@@ -1866,6 +1866,12 @@ else
+ lt_cv_dlopen_libs=
+
+ case $host_os in
++ FreeBSD*)
++ lt_cv_dlopen="dlopen"
++ lt_cv_dlopen_libs=""
++ lt_cv_dlopen_self=yes
++ ;;
++
+ beos*)
+ lt_cv_dlopen="load_add_on"
+ lt_cv_dlopen_libs=
Added: head/sysutils/lttng-ust/files/patch-doc_examples_clock-override_Makefile
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-ust/files/patch-doc_examples_clock-override_Makefile Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,17 @@
+--- doc/examples/clock-override/Makefile.orig 2016-08-25 21:53:05 UTC
++++ doc/examples/clock-override/Makefile
+@@ -15,12 +15,8 @@
+ #
+ # This makefile is purposefully kept simple to support GNU and BSD make.
+
+-ifdef AM_CC
+- CC = $(AM_CC)
+-endif
+-
+-LIBS = -ldl # On Linux
+-#LIBS = -lc # On BSD
++#LIBS = -ldl # On Linux
++LIBS = # On FreeBSD
+ LOCAL_CPPFLAGS += -I.
+
+ all: lttng-ust-clock-override-example.so
Added: head/sysutils/lttng-ust/files/patch-doc_examples_demo-tracef_Makefile
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-ust/files/patch-doc_examples_demo-tracef_Makefile Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,26 @@
+--- doc/examples/demo-tracef/Makefile.orig 2016-08-08 21:25:36 UTC
++++ doc/examples/demo-tracef/Makefile
+@@ -15,12 +15,8 @@
+ #
+ # This makefile is purposefully kept simple to support GNU and BSD make.
+
+-ifdef AM_CC
+- CC = $(AM_CC)
+-endif
+-
+-LIBS = -ldl -llttng-ust # On Linux
+-#LIBS = -lc # On BSD
++#LIBS = -ldl -llttng-ust # On Linux
++LIBS = -llttng-ust # On FreeBSD
+ LOCAL_CPPFLAGS += -I.
+
+ all: demo-tracef
+@@ -31,7 +27,7 @@ demo-tracef.o: demo-tracef.c
+
+ demo-tracef: demo-tracef.o
+ $(CC) $(LDFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(AM_CFLAGS) \
+- -o $@ $< $(LIBS)
++ -o $@ demo-tracef.o $(LIBS)
+
+ .PHONY: clean
+ clean:
Added: head/sysutils/lttng-ust/files/patch-doc_examples_demo-tracelog_Makefile
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-ust/files/patch-doc_examples_demo-tracelog_Makefile Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,26 @@
+--- doc/examples/demo-tracelog/Makefile.orig 2016-08-25 21:53:05 UTC
++++ doc/examples/demo-tracelog/Makefile
+@@ -15,12 +15,8 @@
+ #
+ # This makefile is purposefully kept simple to support GNU and BSD make.
+
+-ifdef AM_CC
+- CC = $(AM_CC)
+-endif
+-
+-LIBS = -ldl -llttng-ust # On Linux
+-#LIBS = -lc # On BSD
++#LIBS = -ldl -llttng-ust # On Linux
++LIBS = -llttng-ust # On FreeBSD
+ LOCAL_CPPFLAGS += -I.
+
+ all: demo-tracelog
+@@ -31,7 +27,7 @@ demo-tracelog.o: demo-tracelog.c
+
+ demo-tracelog: demo-tracelog.o
+ $(CC) $(LDFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(AM_CFLAGS) \
+- -o $@ $< $(LIBS)
++ -o $@ demo-tracelog.o $(LIBS)
+
+ .PHONY: clean
+ clean:
Added: head/sysutils/lttng-ust/files/patch-doc_examples_demo_Makefile
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-ust/files/patch-doc_examples_demo_Makefile Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,17 @@
+--- doc/examples/demo/Makefile.orig 2016-08-08 21:25:36 UTC
++++ doc/examples/demo/Makefile
+@@ -14,12 +14,8 @@
+ #
+ # This makefile is purposefully kept simple to support GNU and BSD make.
+
+-ifdef AM_CC
+- CC = $(AM_CC)
+-endif
+-
+-LIBS = -ldl # On Linux
+-#LIBS = -lc # On BSD
++#LIBS = -ldl # On Linux
++LIBS = # On FreeBSD
+ LOCAL_CPPFLAGS += -I.
+
+ all: demo lttng-ust-provider-ust-tests-demo.so lttng-ust-provider-ust-tests-demo3.so
Added: head/sysutils/lttng-ust/files/patch-doc_examples_easy-ust_Makefile
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-ust/files/patch-doc_examples_easy-ust_Makefile Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,17 @@
+--- doc/examples/easy-ust/Makefile.orig 2016-08-08 21:25:36 UTC
++++ doc/examples/easy-ust/Makefile
+@@ -16,12 +16,8 @@
+ #
+ # This makefile is purposefully kept simple to support GNU and BSD make.
+
+-ifdef AM_CC
+- CC = $(AM_CC)
+-endif
+-
+-LIBS = -ldl -llttng-ust # On Linux
+-#LIBS = -lc -llttng-ust # On BSD
++#LIBS = -ldl -llttng-ust # On Linux
++LIBS = -llttng-ust # On FreeBSD
+ LOCAL_CPPFLAGS += -I.
+
+ all: sample
Added: head/sysutils/lttng-ust/files/patch-doc_examples_gen-tp_Makefile
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-ust/files/patch-doc_examples_gen-tp_Makefile Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,17 @@
+--- doc/examples/gen-tp/Makefile.orig 2016-08-08 21:25:36 UTC
++++ doc/examples/gen-tp/Makefile
+@@ -17,12 +17,8 @@
+ #
+ # This makefile is purposefully kept simple to support GNU and BSD make.
+
+-ifdef AM_CC
+- CC = $(AM_CC)
+-endif
+-
+-LIBS = -ldl -llttng-ust #On Linux
+-#LIBS = -lc -llttng-ust #On BSD
++#LIBS = -ldl -llttng-ust #On Linux
++LIBS = -llttng-ust #On FreeBSD
+
+ all: sample
+
Added: head/sysutils/lttng-ust/files/patch-doc_examples_getcpu-override_Makefile
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-ust/files/patch-doc_examples_getcpu-override_Makefile Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,17 @@
+--- doc/examples/getcpu-override/Makefile.orig 2016-08-25 21:53:05 UTC
++++ doc/examples/getcpu-override/Makefile
+@@ -15,12 +15,8 @@
+ #
+ # This makefile is purposefully kept simple to support GNU and BSD make.
+
+-ifdef AM_CC
+- CC = $(AM_CC)
+-endif
+-
+-LIBS = -ldl # On Linux
+-#LIBS = -lc # On BSD
++#LIBS = -ldl # On Linux
++LIBS = # On FreeBSD
+ LOCAL_CPPFLAGS += -I.
+
+ all: lttng-ust-getcpu-override-example.so
Added: head/sysutils/lttng-ust/files/patch-doc_examples_hello-static-lib_Makefile
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-ust/files/patch-doc_examples_hello-static-lib_Makefile Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,25 @@
+--- doc/examples/hello-static-lib/Makefile.orig 2016-08-08 21:25:36 UTC
++++ doc/examples/hello-static-lib/Makefile
+@@ -14,19 +14,15 @@
+ #
+ # This makefile is purposefully kept simple to support GNU and BSD make.
+
+-ifdef AM_CC
+- CC = $(AM_CC)
+-endif
+-
+ LOCAL_CPPFLAGS += -I.
+-LIBS = -ldl -llttng-ust # On Linux
+-#LIBS = -lc -llttng-ust # On BSD
++#LIBS = -ldl -llttng-ust # On Linux
++LIBS = -llttng-ust # On FreeBSD
+
+ all: hello
+
+ lttng-ust-provider-hello.o: tp.c ust_tests_hello.h
+ $(CC) $(CPPFLAGS) $(LOCAL_CPPFLAGS) $(CFLAGS) $(AM_CPPFLAGS) \
+- $(AM_CFLAGS) -c -o $@ $<
++ $(AM_CFLAGS) -c -o $@ tp.c
+
+ lttng-ust-provider-hello.a: lttng-ust-provider-hello.o
+ ar -rc $@ lttng-ust-provider-hello.o
Added: head/sysutils/lttng-ust/files/patch-doc_man_lttng-ust.3
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/sysutils/lttng-ust/files/patch-doc_man_lttng-ust.3 Sat Feb 11 15:36:17 2017 (r433881)
@@ -0,0 +1,38 @@
+--- doc/man/lttng-ust.3.orig 2016-11-29 22:13:51 UTC
++++ doc/man/lttng-ust.3
+@@ -88,7 +88,7 @@ lttng-ust \- LTTng user space tracing
+ #define \fBtracepoint_enabled\fR(\fIprov_name\fR, \fIt_name\fR)
+ .fi
+ .sp
+-Link with \fB-llttng-ust -ldl\fR, following this man page\&.
++Link with \fB-llttng-ust\fR, following this man page\&.
+ .SH "DESCRIPTION"
+ .sp
+ The \fILinux Trace Toolkit: next generation\fR <http://lttng.org/> is an open source software package used for correlated tracing of the Linux kernel, user applications, and user libraries\&.
+@@ -919,7 +919,7 @@ Then, link your application with this ob
+ .RS 4
+ .\}
+ .nf
+-cc \-o app tp\&.o app\&.o \-llttng\-ust \-ldl
++cc \-o app tp\&.o app\&.o \-llttng\-ust
+ .fi
+ .if n \{\
+ .RE
+@@ -1004,7 +1004,7 @@ This tracepoint provider shared object i
+ .RS 4
+ .\}
+ .nf
*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***
More information about the svn-ports-head
mailing list