Package-Manager: Portage-2.3.94, Repoman-2.3.21
Signed-off-by: Georgy Yakovlev <gyakovlev@gentoo.org>
CWARNS := -Wall -pedantic
CFLAGS += -I$(LUA_INC) -fPIC $(CWARNS)
LIB_OPTION := -shared
+LDFLAGS += $(LIB_OPTION)
SONAME := lua-utf8.so
SONAMEV := $(SONAME).0
ln -s $(SONAMEV) $@
$(LIBRARY): $(OBJ)
- $(CC) $(CFLAGS) $(LIB_OPTION) -o $(LIBRARY) $(OBJ) -lc
+ $(CC) $(CFLAGS) $(LDFLAGS) -o $(LIBRARY) $(OBJ) -lc
install:
install -d $(DESTDIR)$(LUA_LIBDIR)
src_prepare() {
default
- cp -v ${FILESDIR}/${PN}.Makefile ${S}/Makefile || die
+ cp -v "${FILESDIR}/${PN}".Makefile "${S}"/Makefile || die
}
src_compile() {
+ tc-export CC
emake DESTDIR="${D}" PREFIX="${EPREFIX}" MY_USE_LUA="$(usex luajit 'luajit' 'lua')" PKG_CONFIG="$(tc-getPKG_CONFIG)"
}
}
src_test() {
- LUA_CPATH=./src/?.so $(usex luajit 'luajit' 'lua') test.lua || die
+ LUA_CPATH=./?.so $(usex luajit 'luajit' 'lua') test.lua || die
}