packages/utils/sumo/Makefile
Rosen Penev a31b732007 treewide: build CMake projects with Ninja
faster to compile.

A small selection of packages was tested going from:

Executed in  696.30 secs   fish           external
   usr time   82.98 mins  395.00 micros   82.98 mins
   sys time    9.02 mins    0.00 micros    9.02 mins

to:

Executed in  592.20 secs   fish           external
   usr time   84.84 mins  361.00 micros   84.84 mins
   sys time    8.85 mins   57.00 micros    8.85 mins

Tested by running make -j 12 and wiping staging/build_dir/target_x

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-03-27 21:51:50 -07:00

55 lines
1.8 KiB
Makefile

#
# Copyright (C) 2015-2016 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:=sumo
PKG_VERSION:=1.8.0
PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-src-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=@SF/sumo
PKG_HASH:=fb0636152085153155ddb41841f0175c5f1e7989907b883f6c7453c63af49edb
PKG_MAINTAINER:=Álvaro Fernández Rojas <noltari@gmail.com>
PKG_LICENSE:=GPL-3.0-or-later
PKG_LICENSE_FILES:=COPYING
include $(INCLUDE_DIR)/package.mk
include ../../devel/ninja/ninja-cmake.mk
define Package/sumo
SECTION:=utils
CATEGORY:=Utilities
TITLE:=SUMO - Simulation of Urban MObility
URL:=https://sumo.dlr.de/
DEPENDS:=+libxerces-c +zlib
endef
define Package/sumo/description
SUMO is a free and open traffic simulation suite which is available since 2001.
SUMO allows modelling of intermodal traffic systems including road vehicles,
public transport and pedestrians. Included with SUMO is a wealth of supporting
tools which handle tasks such as route finding, visualization, network import
and emission calculation. SUMO can be enhanced with custom models and provides
various APIs to remotely control the simulation.
endef
CMAKE_OPTIONS += \
-DCCACHE_SUPPORT=OFF
define Package/sumo/install
$(INSTALL_DIR) $(1)/usr/bin
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/{activitygen,dfrouter,duarouter,emissionsDrivingCycle,emissionsMap,jtrrouter,marouter,netconvert,netgenerate,od2trips,polyconvert} $(1)/usr/bin
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/sumo $(1)/usr/bin/sumo-bin
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) files/sumo.sh $(1)/usr/sbin/sumo
$(INSTALL_DIR) $(1)/usr/share/sumo
$(CP) $(PKG_BUILD_DIR)/data $(1)/usr/share/sumo/
endef
$(eval $(call BuildPackage,sumo))