diff options
author | V3n3RiX <venerix@koprulu.sector> | 2024-11-03 03:04:04 +0000 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2024-11-03 03:04:04 +0000 |
commit | 212000bb5eabdfeb9a6e7a9b8f28e2740cae555a (patch) | |
tree | dbbe26e892147b95a24336cc44d791dbe0c0ce5f /dev-lua/luadbi | |
parent | 37a097af13d675b83911ac006ee9ee22d2163f9a (diff) |
gentoo auto-resync : 03:11:2024 - 03:04:03
Diffstat (limited to 'dev-lua/luadbi')
-rw-r--r-- | dev-lua/luadbi/Manifest | 2 | ||||
-rw-r--r-- | dev-lua/luadbi/luadbi-0.7.4.ebuild | 101 |
2 files changed, 103 insertions, 0 deletions
diff --git a/dev-lua/luadbi/Manifest b/dev-lua/luadbi/Manifest index e4f7b9b73e40..8cb4908cd056 100644 --- a/dev-lua/luadbi/Manifest +++ b/dev-lua/luadbi/Manifest @@ -1,3 +1,5 @@ DIST luadbi-0.7.3.tar.gz 35753 BLAKE2B ff5fdd144560153fc74733131b48a60a14b7e95de5d6faaa982588cc5df28aa979aa805c5000fdc76fae98b99be4cc4ccb82938c8f6222bcdfe4fca4d12c9bfa SHA512 1122bc9e83cf7071aff8685163a2dc387b40d2fb28aeb57e9c19e14afa6dcb0fb05fa76ea700f69751fdc79b0f1155235195d525041124fed5cefab0d50835bb +DIST luadbi-0.7.4.tar.gz 39077 BLAKE2B 9d7a91c5b8e92e181eb874a9a3f91b82434833cbf428f3c17a0d69693c7881c97646290c98533ee0f83bcbdfc5b9f42b727154db526c766105f1e04df55ee58c SHA512 9614b19c4e2fd134ec4bb196fa67f498a58ff66f06144a42d390ac7a52bab66293e4961f4d4227ea3b24b0662764de2e6497bc40d4976933aa7ffff5ec0929ec EBUILD luadbi-0.7.3.ebuild 1910 BLAKE2B e388e2fb61d89497cf760b3cd9308215739878e7009f94532052ff54e4582f12f625a1bdba83d2357d634fd4aef3ef8f5679a26e5fc8f04ba5626b604e21be13 SHA512 f046b595d1e59d8ae0381c94f04c4012e509c4236034b2fceb44c8f3ad039cb7531f195039d87a031158cb8905a350725b8662224592b530f2ef39314ca8444b +EBUILD luadbi-0.7.4.ebuild 1914 BLAKE2B 11e0cd914e33c424a387db957eda57efa4d1fff0ed4077453f3734772189b7be1f21c3c7090c15f7c684ddd2ce6febf14cace4929c923e5d55d935b03766117c SHA512 b3c11175c61513993042dd62ed9974f3a900b3eb3aa5f401e0f740bcdc4bc68dc741673a6388e997bec7f3561fe5998981a61c1f44df9c746285d7e54882593c MISC metadata.xml 329 BLAKE2B 63f2efc683cb8c68fc27953c6003708f965328cc4b445e5b62c1cffc85e79c9971ef4bfca6ae6b7a95179c3ad13e9374a2d0f1e06518403902a461d7598ade72 SHA512 c1f454ba961c109a06e0a06e85ad426dc6d6cc5697e6c2ceda3fe003242c1d50ef5c71fa0a84201d0a20b7d22bdf1ab597ff780b681a3a32e08c14457f7a2081 diff --git a/dev-lua/luadbi/luadbi-0.7.4.ebuild b/dev-lua/luadbi/luadbi-0.7.4.ebuild new file mode 100644 index 000000000000..be8445e6d2da --- /dev/null +++ b/dev-lua/luadbi/luadbi-0.7.4.ebuild @@ -0,0 +1,101 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +LUA_COMPAT=( lua5-{1..4} luajit ) + +inherit lua toolchain-funcs + +DESCRIPTION="A database interface library for Lua" +HOMEPAGE="https://github.com/mwild1/luadbi" +SRC_URI="https://github.com/mwild1/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ppc ~ppc64 ~sparc ~x86" +IUSE="mysql postgres +sqlite test" +REQUIRED_USE=" + ${LUA_REQUIRED_USE} + || ( mysql postgres sqlite ) +" +RESTRICT="test" + +RDEPEND=" + ${LUA_DEPS} + mysql? ( dev-db/mysql-connector-c:0= ) + postgres? ( dev-db/postgresql:= ) + sqlite? ( dev-db/sqlite ) +" + +DEPEND="${RDEPEND}" + +BDEPEND=" + virtual/pkgconfig + test? ( + dev-lua/busted[${LUA_USEDEP}] + dev-lua/luarocks + ) +" + +src_prepare() { + default + + # Respect users CFLAGS + sed -e 's/-g //' -e 's/-O2 //g' -i Makefile || die + + lua_copy_sources +} + +lua_src_compile() { + pushd "${BUILD_DIR}" || die + + tc-export AR CC + + local myemakeargs=( + "LUA_INC=$(lua_get_CFLAGS)" + ) + + use mysql && emake ${myemakeargs} MYSQL_INC="-I$(mariadb_config --libs)" mysql + use postgres && emake ${myemakeargs} PSQL_INC="-I$(pg_config --libdir)" psql + use sqlite emake ${myemakeargs} SQLITE3_INC="-I/usr/include" sqlite + + popd +} + +src_compile() { + lua_foreach_impl lua_src_compile +} + +lua_src_test() { + pushd "${BUILD_DIR}" || die + cd "${S}"/tests && ${ELUA} run_tests.lua || die + popd +} + +src_test() { + lua_foreach_impl lua_src_test +} + +lua_src_install() { + pushd "${BUILD_DIR}" || die + + local myemakeargs=( + DESTDIR="${ED}" + LUA_CDIR="$(lua_get_cmod_dir)" + LUA_INC="$(lua_get_CFLAGS)" + LUA_LDIR="$(lua_get_lmod_dir)" + ) + + use mysql && emake ${myemakeargs[@]} install_mysql + use postgres && emake ${myemakeargs[@]} install_psql + use sqlite && emake ${myemakeargs[@]} install_sqlite3 + + popd +} + +src_install() { + lua_foreach_impl lua_src_install + + einstalldocs +} |