Add rtmp lib for openwrt

I try to add librtmp ,but get some erro codes.
I want use rtmp for gstreamer. which need librtmp.
FFmpeg can work,but high cpu use, and low fps.

Can you detail how far you got with making a new package?

Copyright (C) 2019 OpenWrt.org

This is free software, licensed under the GNU General Public License v2.

See /LICENSE for more information.

include $(TOPDIR)/rules.mk

PKG_NAME:=librtmp
PKG_RELEASE:=1

PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://git.ffmpeg.org/rtmpdump.git
PKG_SOURCE_DATE:=2024-03-01
PKG_SOURCE_VERSION:=f3042b5bb7dcb42eda32ad9dd88029b24a2c282b
PKG_MIRROR_HASH:=

PKG_LICENSE:=GPL-2.0
PKG_LICENSE_FILES:=COPYING

include $(INCLUDE_DIR)/package.mk

define Package/librtmp
SECTION:=libs
CATEGORY:=Libraries
TITLE:=librtmp
URL:=http://git.ffmpeg.org/rtmpdump.git
DEPENDS:=+libopenssl
endef

define Build/InstallDev
$(INSTALL_DIR) $(1)/usr/include
$(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/.so $(1)/usr/lib/
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/rtmp.pc $(1)/usr/lib/pkgconfig/
endef

define Package/librtmp/install
$(INSTALL_DIR) $(1)/usr/bin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/librtmp $(1)/usr/bin/
endef

$(eval $(call BuildPackage,librtmp))

I got the code from here

now I find a new code is very similer to openwrt.
So,I want to have a try.