Ticket #33243 (closed enhancement: fixed)
fuse4x-kext: add +trace variant
| Reported by: | anatol.pomozov@… | Owned by: | dports@… |
|---|---|---|---|
| Priority: | Normal | Milestone: | |
| Component: | ports | Version: | 2.0.3 |
| Keywords: | Cc: | ||
| Port: | fuse4x-kext |
Description
Hi, Dan.
During debugging fuse4x-kext kernel issues it might be useful to enable logging for this port (e.g. by using "+trace" variant). If this variant is enabled then following compile flags should be set
#define FUSE_COUNT_MEMORY 1 #define FUSE_DEBUG 1 #define FUSE_TRACE 1 #define FUSE_TRACE_LK 1 #define FUSE_TRACE_MSLEEP 1 #define FUSE_TRACE_OP 1 #define FUSE_TRACE_VNCACHE 1 #define M_FUSE4X_SERIALIZE_LOGGING 1
See the list here https://github.com/fuse4x/kext/blob/master/fuse.h
It should be either uncommented in fuse.h file or passed to xcode during compilation. The second option looks better to me but I do not know how to do it. Dan, could you please help me?
Attachments
Change History
comment:1 Changed 15 months ago by dports@…
- Status changed from new to assigned
- Owner changed from macports-tickets@… to dports@…
- Cc dports@… removed
comment:3 Changed 15 months ago by anatol.pomozov@…
FYI macros names are changed in 0.9.0 to be more consistent with each other.
So what I need is to pass "-D...." to kext compilation. I do "configure.cflags-append -DFUSE4X_DEBUG". And it does not work and does not affect compilation using xcode.
My question - how to add a compile parameter to a xcode-based project?
comment:4 Changed 15 months ago by dports@…
- Status changed from assigned to closed
- Resolution set to fixed
It turns out the answer is
xcode.build.settings-append GCC_PREPROCESSOR_DEFINITIONS='FUSE4X_DEBUG FUSE4X_TRACE FUSE4X_TRACE_LK FUSE4X_TRACE_MSLEEP FUSE4X_TRACE_OP FUSE4X_TRACE_VNCACHE FUSE4X_SERIALIZE_LOGGING'
which was surprisingly hard to figure out. Let me know if I missed any defines.
I thought about calling the variant +debug because that's more commonly used by other ports, but decided +trace was better because +debug usually just means compiling with debug symbols and this is far more than that.
comment:5 Changed 15 months ago by anatol.pomozov@…
Hi, thanks for taking care of it. Also thanks for updating to 0.9.0 although it requires a few additional things
- kext needs FUSE4X_DISABLE_MACFUSE_MODE flag passed to GCC_PREPROCESSOR_DEFINITIONS. This disables some sysctl entries that mimic macfuse.
- fuse needs "configure.cflags-append -D_DARWIN_USE_64_BIT_INODE", it forces to use 64bit inodes. The flag is no-op on 10.6+ but on 10.5 32bit inodes are used by default. In fuse4x version prior 0.9.0 this flag was a part of ./configure script (and forced 64bit inodes on all platforms) but now it is moved outside to a separate build script.
- Portfiles (both kext and fuse) still mention "/System/" it should be removed I think.
As GCC_PREPROCESSOR_DEFINITIONS I also expected something cleaner. Something like xcode.build.definitions-append 'FUSE4X_DEBUG'
comment:6 Changed 15 months ago by anatol.pomozov@…
- Status changed from closed to reopened
- Resolution fixed deleted
Reopening it as it still requires some additional changes.
comment:7 Changed 15 months ago by dports@…
- Status changed from reopened to closed
- Resolution set to fixed
Changed 15 months ago by anatol.pomozov@…
- Attachment fix_path.patch added
Fix path to kext in comments


Sure, I'll take a look.