head	1.4;
access;
symbols
	pkgsrc-2026Q1:1.4.0.36
	pkgsrc-2026Q1-base:1.4
	pkgsrc-2025Q4:1.4.0.34
	pkgsrc-2025Q4-base:1.4
	pkgsrc-2025Q3:1.4.0.32
	pkgsrc-2025Q3-base:1.4
	pkgsrc-2025Q2:1.4.0.30
	pkgsrc-2025Q2-base:1.4
	pkgsrc-2025Q1:1.4.0.28
	pkgsrc-2025Q1-base:1.4
	pkgsrc-2024Q4:1.4.0.26
	pkgsrc-2024Q4-base:1.4
	pkgsrc-2024Q3:1.4.0.24
	pkgsrc-2024Q3-base:1.4
	pkgsrc-2024Q2:1.4.0.22
	pkgsrc-2024Q2-base:1.4
	pkgsrc-2024Q1:1.4.0.20
	pkgsrc-2024Q1-base:1.4
	pkgsrc-2023Q4:1.4.0.18
	pkgsrc-2023Q4-base:1.4
	pkgsrc-2023Q3:1.4.0.16
	pkgsrc-2023Q3-base:1.4
	pkgsrc-2023Q2:1.4.0.14
	pkgsrc-2023Q2-base:1.4
	pkgsrc-2023Q1:1.4.0.12
	pkgsrc-2023Q1-base:1.4
	pkgsrc-2022Q4:1.4.0.10
	pkgsrc-2022Q4-base:1.4
	pkgsrc-2022Q3:1.4.0.8
	pkgsrc-2022Q3-base:1.4
	pkgsrc-2022Q2:1.4.0.6
	pkgsrc-2022Q2-base:1.4
	pkgsrc-2022Q1:1.4.0.4
	pkgsrc-2022Q1-base:1.4
	pkgsrc-2021Q4:1.4.0.2
	pkgsrc-2021Q4-base:1.4
	pkgsrc-2017Q4:1.2.0.18
	pkgsrc-2017Q4-base:1.2
	pkgsrc-2017Q3:1.2.0.16
	pkgsrc-2017Q3-base:1.2
	pkgsrc-2017Q2:1.2.0.12
	pkgsrc-2017Q2-base:1.2
	pkgsrc-2017Q1:1.2.0.10
	pkgsrc-2017Q1-base:1.2
	pkgsrc-2016Q4:1.2.0.8
	pkgsrc-2016Q4-base:1.2
	pkgsrc-2016Q3:1.2.0.6
	pkgsrc-2016Q3-base:1.2
	pkgsrc-2016Q2:1.2.0.4
	pkgsrc-2016Q2-base:1.2
	pkgsrc-2016Q1:1.2.0.2
	pkgsrc-2016Q1-base:1.2
	pkgsrc-2015Q4:1.1.0.4
	pkgsrc-2015Q4-base:1.1
	pkgsrc-2015Q3:1.1.0.2
	pkgsrc-2015Q3-base:1.1;
locks; strict;
comment	@# @;


1.4
date	2021.12.07.16.34.44;	author jperkin;	state Exp;
branches;
next	1.3;
commitid	yIqEKjwmnBFUNJjD;

1.3
date	2018.02.23.02.42.06;	author khorben;	state dead;
branches;
next	1.2;
commitid	DNKX0PZLlc0ADVrA;

1.2
date	2016.02.20.11.40.30;	author jperkin;	state Exp;
branches;
next	1.1;
commitid	6hAu7oDAkj3VdEVy;

1.1
date	2015.07.28.12.48.14;	author sevan;	state Exp;
branches;
next	;
commitid	mQHE40RJJ2Rkf3vy;


desc
@@


1.4
log
@capstone: Fix install_name on Darwin.
@
text
@$NetBSD$

Fix install_name on Darwin.

--- Makefile.orig	2020-05-08 10:03:30.000000000 +0000
+++ Makefile
@@@@ -284,7 +284,7 @@@@ LDFLAGS += $(foreach arch,$(LIBARCHS),-a
 endif
 EXT = dylib
 VERSION_EXT = $(API_MAJOR).$(EXT)
-$(LIBNAME)_LDFLAGS += -dynamiclib -install_name lib$(LIBNAME).$(VERSION_EXT) -current_version $(PKG_MAJOR).$(PKG_MINOR).$(PKG_EXTRA) -compatibility_version $(PKG_MAJOR).$(PKG_MINOR)
+$(LIBNAME)_LDFLAGS += -dynamiclib -install_name ${PREFIX}/lib/lib$(LIBNAME).$(VERSION_EXT) -current_version $(PKG_MAJOR).$(PKG_MINOR).$(PKG_EXTRA) -compatibility_version $(PKG_MAJOR).$(PKG_MINOR)
 AR_EXT = a
 # Homebrew wants to make sure its formula does not disable FORTIFY_SOURCE
 # However, this is not really necessary because 'CAPSTONE_USE_SYS_DYN_MEM=yes' by default
@


1.3
log
@Update devel/capstone to version 3.0.5-rc2

This provides important fixes in the core & several bindings:

Library

    Fix build for Visual Studio 2012
    Fix X86_REL_ADDR macro
    Add CS_VERSION_MAJOR, CS_VERSION_MINOR, CS_VERSION_EXTRA
    Better support for embedding Capstone into Windows kernel drivers
    Support to embedded Capstone into MacOS kernel
    Support MacOS 10.11 and up
    Better support for Cygwin
    Support build packages for FreeBSD & DragonflyBSD
    Add a command-line tool "cstool"
    Properly handle switching to Endian mode at run-time for Arm, Arm64, Mips & Sparc

X86

    Some random 16-bit code can be handled wrongly.
    Remove abundant operand type X86_OP_FP
    Fix instructions MOVQ, LOOP, LOOPE, LOOPNE, CALL/JMP rel16, REPNE LODSD, MOV *AX, MOFFS, FAR JMP/CALL
    Add X86_REG_EFLAGS for STC and STD
    Fix instruction attributes for SYSEXIT, MOVW, ROL, LGS, SLDT
    Rename registers ST0-ST7 to be consistent with asm output

Arm

    Properly handle IT instruction
    Fix LDRSB
    Fix writeback for LDR
    Fix Thumb BigEndian setup

Arm

    Fix arith extender
    Fix writeback for LDR
    Rename enum arm64_mrs_reg to arm64_sysreg

PowerPC

    Print 0 offset for memory operand

Sparc

    Fix POPC instruction

Python binding

    Better PyPy support
    Add __version__
    Better support for Python 3
    Fix CS_SKIPDATA_CALLBACK prototype
    Cast skipdata function inside binding to simplify the API

Java binding

    Better handle input with invalid code

PowerShell binding

    New binding

Build-tested with devel/ropper and devel/{py-,}radare2 on NetBSD/amd64.
@
text
@d1 1
a1 6
$NetBSD: patch-Makefile,v 1.2 2016/02/20 11:40:30 jperkin Exp $

Unbreak build on FreeBSD and DragonflyBSD.

Patch accepted upstream:
https://github.com/aquynh/capstone/commit/453b41a29ed7f02f8319329cc86853d394b85a1e
d5 1
a5 1
--- Makefile.orig	2015-07-15 07:44:42.000000000 +0000
d7 1
a7 14
@@@@ -70,12 +70,18 @@@@ LIBDIRARCH ?= lib
 LIBDIR = $(DESTDIR)$(PREFIX)/$(LIBDIRARCH)
 
 LIBDATADIR = $(LIBDIR)
+
+# Don't redefine $LIBDATADIR when global environment variable
+# USE_GENERIC_LIBDATADIR is set. This is used by the pkgsrc framework.
+
+ifndef USE_GENERIC_LIBDATADIR
 ifeq ($(UNAME_S), FreeBSD)
 LIBDATADIR = $(DESTDIR)$(PREFIX)/libdata
 endif
 ifeq ($(UNAME_S), DragonFly)
 LIBDATADIR = $(DESTDIR)$(PREFIX)/libdata
a8 6
+endif
 
 INSTALL_BIN ?= install
 INSTALL_DATA ?= $(INSTALL_BIN) -m0644
@@@@ -248,7 +254,7 @@@@ IS_APPLE := $(shell $(CC) -dM -E - < /de
 ifeq ($(IS_APPLE),1)
d12 1
a12 1
+$(LIBNAME)_LDFLAGS += -dynamiclib -install_name ${LIBDIR}/lib$(LIBNAME).$(VERSION_EXT) -current_version $(PKG_MAJOR).$(PKG_MINOR).$(PKG_EXTRA) -compatibility_version $(PKG_MAJOR).$(PKG_MINOR)
a15 5
@@@@ -463,4 +469,3 @@@@ define generate-pkgcfg
 	echo 'Libs: -L$${libdir} -lcapstone' >> $(PKGCFGF)
 	echo 'Cflags: -I$${includedir}' >> $(PKGCFGF)
 endef
-
@


1.2
log
@Fix install_name on Darwin.  Bump PKGREVISION.
@
text
@d1 1
a1 1
$NetBSD: patch-Makefile,v 1.1 2015/07/28 12:48:14 sevan Exp $
@


1.1
log
@
"Backport upstream patch for pkgsrc to unbreak FreeBSD and DragonflyBSD" - kamil@@
@
text
@d1 1
a1 1
$NetBSD$
d8 2
d31 9
@

