Index: head/benchmarks/Makefile =================================================================== --- head/benchmarks/Makefile (revision 546065) +++ head/benchmarks/Makefile (revision 546066) @@ -1,103 +1,104 @@ # $FreeBSD$ # COMMENT = Benchmarking tools SUBDIR += apib SUBDIR += autobench SUBDIR += blogbench SUBDIR += bombardier SUBDIR += bonnie SUBDIR += bonnie++ SUBDIR += clpeak SUBDIR += cpipe SUBDIR += dbench SUBDIR += dbs SUBDIR += dhrystone SUBDIR += dkftpbench SUBDIR += fhourstones SUBDIR += fio SUBDIR += flamegraph SUBDIR += flops SUBDIR += flowgrind SUBDIR += forkbomb SUBDIR += glmark2 SUBDIR += gtkperf SUBDIR += hey SUBDIR += himenobench SUBDIR += hipercontracer SUBDIR += hpl SUBDIR += httperf SUBDIR += hyperfine SUBDIR += imb SUBDIR += interbench SUBDIR += iorate SUBDIR += iozone SUBDIR += iozone21 SUBDIR += iperf SUBDIR += iperf3 SUBDIR += libcelero SUBDIR += libmicro SUBDIR += linux-vdbench SUBDIR += lmbench SUBDIR += lzbench + SUBDIR += mangohud SUBDIR += mdtest SUBDIR += nbench SUBDIR += netio SUBDIR += netperf SUBDIR += netperfmeter SUBDIR += nosqlbench SUBDIR += nqueens SUBDIR += nttcp SUBDIR += nuttcp SUBDIR += octave-forge-benchmark SUBDIR += p5-Benchmark-Forking SUBDIR += p5-Benchmark-Stopwatch SUBDIR += p5-Dumbbench SUBDIR += pathchirp SUBDIR += pathload SUBDIR += pathrate SUBDIR += pear-Benchmark SUBDIR += perftest SUBDIR += phoronix-test-suite SUBDIR += pipebench SUBDIR += polygraph SUBDIR += postal SUBDIR += postmark SUBDIR += py-locust SUBDIR += py-naarad SUBDIR += py-throughpy SUBDIR += py-zopkio SUBDIR += raidtest SUBDIR += ramspeed SUBDIR += randomio SUBDIR += rubygem-benchmark SUBDIR += rubygem-benchmark-ips SUBDIR += rubygem-benchmark-memory SUBDIR += rubygem-derailed_benchmarks SUBDIR += rubygem-gitlab-derailed_benchmarks SUBDIR += rubygem-railsbench SUBDIR += scimark2 SUBDIR += scimark2c SUBDIR += siege SUBDIR += sipp SUBDIR += slowloris SUBDIR += smhasher SUBDIR += spp SUBDIR += stream SUBDIR += stress-ng SUBDIR += super-smack SUBDIR += sysbench SUBDIR += tcpblast SUBDIR += thrulay SUBDIR += tsung SUBDIR += ttcp SUBDIR += typometer SUBDIR += ubench SUBDIR += unixbench SUBDIR += uperf SUBDIR += vegeta SUBDIR += webbench SUBDIR += wrk .include Index: head/benchmarks/mangohud/Makefile =================================================================== --- head/benchmarks/mangohud/Makefile (nonexistent) +++ head/benchmarks/mangohud/Makefile (revision 546066) @@ -0,0 +1,47 @@ +# Created by: Alexey Dokuchaev +# $FreeBSD$ + +PORTNAME= mangohud +PORTVERSION= 0.5.1 +DISTVERSIONPREFIX= v +CATEGORIES= benchmarks graphics + +MAINTAINER= danfe@FreeBSD.org +COMMENT= Vulkan/OpenGL overlay for CPU/GPU monitoring + +LICENSE= MIT +LICENSE_FILE= ${WRKSRC}/LICENSE + +BUILD_DEPENDS= glslangValidator:devel/glslang \ + ${LOCALBASE}/share/vulkan/registry/vk.xml:devel/vulkan-headers \ + ${PYTHON_PKGNAMEPREFIX}mako>=0:textproc/py-mako@${PY_FLAVOR} +LIB_DEPENDS= libdbus-1.so:devel/dbus \ + libinotify.so:devel/libinotify + +USES= compiler:c++14-lang meson pkgconfig python:build xorg +USE_GITHUB= yes +GH_ACCOUNT= flightlessmango +GH_PROJECT= MangoHud +USE_XORG= x11 +MESON_ARGS= -Duse_system_vulkan=enabled -Dwith_xnvctrl=disabled + +PLIST_FILES= bin/mangohud lib/mangohud/libMangoHud.so \ + lib/mangohud/libMangoHud_dlsym.so man/man1/mangohud.1.gz \ + share/vulkan/implicit_layer.d/MangoHud.json +PORTEXAMPLES= MangoHud.conf.example + +OPTIONS_DEFINE= EXAMPLES + +post-patch: + @${REINPLACE_CMD} -e '/version : /s,0\.4\.0,${PORTVERSION}, ; \ + /^prog_python = /s,3,${PYTHON_VER},' ${WRKSRC}/meson.build + @${REINPLACE_CMD} -e '1s,usr/bin/env ba,bin/,' \ + ${WRKSRC}/bin/mangohud.in + @${REINPLACE_CMD} -e 's,/usr/share/doc,${PREFIX}/share/examples,' \ + ${WRKSRC}/data/mangohud.1 + @${REINPLACE_CMD} -e '/#include /d' \ + ${WRKSRC}/src/overlay_params.cpp + @${REINPLACE_CMD} -e 's,libdl\.so,ld-elf.so,' \ + ${WRKSRC}/src/real_dlsym.cpp + +.include Property changes on: head/benchmarks/mangohud/Makefile ___________________________________________________________________ Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +FreeBSD=%H \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/benchmarks/mangohud/distinfo =================================================================== --- head/benchmarks/mangohud/distinfo (nonexistent) +++ head/benchmarks/mangohud/distinfo (revision 546066) @@ -0,0 +1,3 @@ +TIMESTAMP = 1597596860 +SHA256 (flightlessmango-MangoHud-v0.5.1_GH0.tar.gz) = 3e91d4fc7369d46763894c13f3315133871dd02705072981770c3cf58e8081c6 +SIZE (flightlessmango-MangoHud-v0.5.1_GH0.tar.gz) = 15042595 Property changes on: head/benchmarks/mangohud/distinfo ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/benchmarks/mangohud/files/patch-include_elfhacks.h =================================================================== --- head/benchmarks/mangohud/files/patch-include_elfhacks.h (nonexistent) +++ head/benchmarks/mangohud/files/patch-include_elfhacks.h (revision 546066) @@ -0,0 +1,19 @@ +--- include/elfhacks.h.orig 2020-08-16 16:54:20 UTC ++++ include/elfhacks.h +@@ -58,6 +58,16 @@ extern "C" { + # endif + #endif + ++#ifndef __ELF_NATIVE_CLASS ++#define __ELF_NATIVE_CLASS __WORDSIZE ++#endif ++ ++/* We use this macro to refer to ELF types independent of the native wordsize. ++ `ElfW(TYPE)' is used in place of `Elf32_TYPE' or `Elf64_TYPE'. */ ++#define ElfW(type) _ElfW (Elf, __ELF_NATIVE_CLASS, type) ++#define _ElfW(e,w,t) _ElfW_1 (e, w, _##t) ++#define _ElfW_1(e,w,t) e##w##t ++ + /** + * \defgroup elfhacks elfhacks + * Elfhacks is a collection of functions that aim for retvieving Property changes on: head/benchmarks/mangohud/files/patch-include_elfhacks.h ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/benchmarks/mangohud/files/patch-meson.build =================================================================== --- head/benchmarks/mangohud/files/patch-meson.build (nonexistent) +++ head/benchmarks/mangohud/files/patch-meson.build (revision 546066) @@ -0,0 +1,20 @@ +--- meson.build.orig 2020-08-16 16:54:20 UTC ++++ meson.build +@@ -98,7 +98,7 @@ inc_common = [ + include_directories('include'), + ] + +-dep_vulkan = dependency('vulkan', required: get_option('use_system_vulkan')) ++dep_inotify = dependency('libinotify') + dep_pthread = dependency('threads') + dbus_dep = dependency('dbus-1', required: get_option('with_dbus')).partial_dependency(compile_args : true, includes : true) + +@@ -170,7 +170,7 @@ else + dep_rt = cc.find_library('rt') + endif + +-if dep_vulkan.found() ++if true + datadir = get_option('datadir') + if not datadir.startswith('/') + datadir = get_option('prefix') / datadir Property changes on: head/benchmarks/mangohud/files/patch-meson.build ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/benchmarks/mangohud/files/patch-src_elfhacks.cpp =================================================================== --- head/benchmarks/mangohud/files/patch-src_elfhacks.cpp (nonexistent) +++ head/benchmarks/mangohud/files/patch-src_elfhacks.cpp (revision 546066) @@ -0,0 +1,29 @@ +--- src/elfhacks.cpp.orig 2020-08-16 16:54:20 UTC ++++ src/elfhacks.cpp +@@ -195,22 +195,22 @@ int eh_init_obj(eh_obj_t *obj) + if (obj->strtab) + return ENOTSUP; + +- obj->strtab = (const char *) obj->dynamic[p].d_un.d_ptr; ++ obj->strtab = (const char *) (obj->dynamic[p].d_un.d_ptr + obj->addr); + } else if (obj->dynamic[p].d_tag == DT_HASH) { + if (obj->hash) + return ENOTSUP; + +- obj->hash = (ElfW(Word) *) obj->dynamic[p].d_un.d_ptr; ++ obj->hash = (ElfW(Word) *) (obj->dynamic[p].d_un.d_ptr + obj->addr); + } else if (obj->dynamic[p].d_tag == DT_GNU_HASH) { + if (obj->gnu_hash) + return ENOTSUP; + +- obj->gnu_hash = (Elf32_Word *) obj->dynamic[p].d_un.d_ptr; ++ obj->gnu_hash = (Elf32_Word *) (obj->dynamic[p].d_un.d_ptr + obj->addr); + } else if (obj->dynamic[p].d_tag == DT_SYMTAB) { + if (obj->symtab) + return ENOTSUP; + +- obj->symtab = (ElfW(Sym) *) obj->dynamic[p].d_un.d_ptr; ++ obj->symtab = (ElfW(Sym) *) (obj->dynamic[p].d_un.d_ptr + obj->addr); + } + p++; + } Property changes on: head/benchmarks/mangohud/files/patch-src_elfhacks.cpp ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/benchmarks/mangohud/files/patch-src_meson.build =================================================================== --- head/benchmarks/mangohud/files/patch-src_meson.build (nonexistent) +++ head/benchmarks/mangohud/files/patch-src_meson.build (revision 546066) @@ -0,0 +1,29 @@ +--- src/meson.build.orig 2020-08-16 16:54:20 UTC ++++ src/meson.build +@@ -3,7 +3,7 @@ glslang = find_program('glslangValidator') + # Needs prefix for configure_file() + if get_option('append_libdir_mangohud') + libdir_mangohud = join_paths(get_option('libdir'), 'mangohud') +- ld_libdir_mangohud = get_option('prefix') + '/\$LIB/mangohud/' ++ ld_libdir_mangohud = get_option('prefix') + '/lib/mangohud/' + else + libdir_mangohud = get_option('libdir') + ld_libdir_mangohud = get_option('prefix') + '/\$LIB/' +@@ -141,7 +141,7 @@ vklayer_mesa_overlay = shared_library( + dep_dl, + dep_rt, + dep_pthread, +- dep_vulkan], ++ dep_inotify], + include_directories : [inc_common], + link_args : link_args, + install_dir : libdir_mangohud, +@@ -187,7 +187,7 @@ configure_file(input : '../bin/mangohud.in', + if get_option('include_doc') + install_data( + files('../bin/MangoHud.conf'), +- install_dir : join_paths(get_option('datadir'), 'doc', 'mangohud'), ++ install_dir : join_paths(get_option('datadir'), 'examples', 'mangohud'), + rename : ['MangoHud.conf.example'] + ) + endif Property changes on: head/benchmarks/mangohud/files/patch-src_meson.build ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/benchmarks/mangohud/pkg-descr =================================================================== --- head/benchmarks/mangohud/pkg-descr (nonexistent) +++ head/benchmarks/mangohud/pkg-descr (revision 546066) @@ -0,0 +1,4 @@ +MangoHud is a Vulkan/OpenGL overlay for monitoring FPS, temperatures, +CPU/GPU load, and more. + +WWW: https://github.com/flightlessmango/MangoHud Property changes on: head/benchmarks/mangohud/pkg-descr ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property