Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 10 Dec 2019 18:07:15 +0000 (UTC)
From:      Alexey Dokuchaev <danfe@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r519774 - in head/devel: . axmldec axmldec/files
Message-ID:  <201912101807.xBAI7FIG040115@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: danfe
Date: Tue Dec 10 18:07:14 2019
New Revision: 519774
URL: https://svnweb.freebsd.org/changeset/ports/519774

Log:
  - Add a port of a stand-alone binary AndroidManifest.xml decoder
  - Pull `archivers/minizip' port instead of using the bundled copy
  
  WWW: https://github.com/ytsutano/axmldec

Added:
  head/devel/axmldec/
  head/devel/axmldec/Makefile   (contents, props changed)
  head/devel/axmldec/distinfo   (contents, props changed)
  head/devel/axmldec/files/
  head/devel/axmldec/files/patch-CMakeLists.txt   (contents, props changed)
  head/devel/axmldec/pkg-descr   (contents, props changed)
Modified:
  head/devel/Makefile

Modified: head/devel/Makefile
==============================================================================
--- head/devel/Makefile	Tue Dec 10 18:02:22 2019	(r519773)
+++ head/devel/Makefile	Tue Dec 10 18:07:14 2019	(r519774)
@@ -205,6 +205,7 @@
     SUBDIR += aws-sdk-cpp
     SUBDIR += aws-sdk-php
     SUBDIR += awscli
+    SUBDIR += axmldec
     SUBDIR += b2
     SUBDIR += babeltrace
     SUBDIR += bam

Added: head/devel/axmldec/Makefile
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/devel/axmldec/Makefile	Tue Dec 10 18:07:14 2019	(r519774)
@@ -0,0 +1,24 @@
+# Created by: Alexey Dokuchaev <danfe@FreeBSD.org>
+# $FreeBSD$
+
+PORTNAME=	axmldec
+PORTVERSION=	1.2.0
+DISTVERSIONPREFIX=	v
+CATEGORIES=	devel
+
+MAINTAINER=	danfe@FreeBSD.org
+COMMENT=	Stand-alone binary AndroidManifest.xml decoder
+
+LICENSE=	ISCL
+LICENSE_FILE=	${WRKSRC}/LICENSE.md
+
+LIB_DEPENDS=	libminizip.so:archivers/minizip \
+		libboost_system.so:devel/boost-libs
+
+USES=		cmake compiler:c++14-lang pkgconfig
+USE_GITHUB=	yes
+GH_ACCOUNT=	ytsutano
+
+PLIST_FILES=	bin/${PORTNAME}
+
+.include <bsd.port.mk>

Added: head/devel/axmldec/distinfo
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/devel/axmldec/distinfo	Tue Dec 10 18:07:14 2019	(r519774)
@@ -0,0 +1,3 @@
+TIMESTAMP = 1494186284
+SHA256 (ytsutano-axmldec-v1.2.0_GH0.tar.gz) = f83a6a7cdccdb20847a6824d54a4d2e548110307cd27473841630e91c13def6f
+SIZE (ytsutano-axmldec-v1.2.0_GH0.tar.gz) = 188496

Added: head/devel/axmldec/files/patch-CMakeLists.txt
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/devel/axmldec/files/patch-CMakeLists.txt	Tue Dec 10 18:07:14 2019	(r519774)
@@ -0,0 +1,34 @@
+--- CMakeLists.txt.orig	2017-05-07 19:44:44 UTC
++++ CMakeLists.txt
+@@ -61,23 +61,17 @@ add_definitions(
+ target_link_libraries(axmldec ${Boost_LIBRARIES})
+ 
+ if(ENABLE_APK_LOADING)
+-    find_package(ZLIB REQUIRED)
+-    include_directories(${ZLIB_INCLUDE_DIR})
+-
++    include (FindPkgConfig)
++    if (PKG_CONFIG_FOUND)
++        pkg_check_modules(MINIZIP minizip)
++    endif()
++    include_directories(${MINIZIP_INCLUDE_DIRS})
++    find_library(MINIZIP_FROM_PORTS ${MINIZIP_LIBRARIES}
++        PATHS ${MINIZIP_LIBRARY_DIRS})
+     add_definitions(
+         -DENABLE_APK_LOADING=1
+     )
+-    add_library(minizip STATIC
+-        ${CMAKE_CURRENT_SOURCE_DIR}/external/minizip/unzip.c
+-        ${CMAKE_CURRENT_SOURCE_DIR}/external/minizip/ioapi.c
+-    )
+-    set_target_properties(minizip PROPERTIES
+-        COMPILE_DEFINITIONS "NOUNCRYPT;NOCRYPT")
+-    target_link_libraries(minizip ${ZLIB_LIBRARIES})
+-    set(MINIZIP_INCLUDE_DIR ${CMAKE_SOURCE_DIR}/external/minizip)
+-    set(MINIZIP_LIBRARIES minizip)
+-    include_directories(SYSTEM ${MINIZIP_INCLUDE_DIR})
+-    target_link_libraries(axmldec ${MINIZIP_LIBRARIES})
++    target_link_libraries(axmldec ${MINIZIP_FROM_PORTS})
+ endif()
+ 
+ #-------------------------------------------------------------------------------

Added: head/devel/axmldec/pkg-descr
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/devel/axmldec/pkg-descr	Tue Dec 10 18:07:14 2019	(r519774)
@@ -0,0 +1,13 @@
+AndroidManifest.xml file in an APK file is binary encoded.  This tool
+accepts either a binary or a text XML file and prints the decoded XML to
+the standard output or a file.  It also allows you to extract the decoded
+AndroidManifest.xml directly from an APK file.
+
+Popular tools such as Apktool are designed to process the whole APK file
+including the resource files for reverse engineering purpose.  They may
+also need a Java virtual machine to run.  As a result, they are too slow
+for batch processing many APK files just to get the XML information.  In
+contrast, axmldec is specialized for binary XML decoding and written in
+simple modern C++, so it runs nicely within a shell script.
+
+WWW: https://github.com/ytsutano/axmldec



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201912101807.xBAI7FIG040115>