github.com/metux/go-metabuild@v0.0.0-20240118143255-d9ed5ab697f9/examples/pkg/lincity/metabuild.yaml (about)

     1  # TODO
     2  #
     3  # * move it under /usr/games
     4  # * executable xlincity & lincity (symlink)
     5  # * fixme: data-locales --> symlink
     6  
     7  package:      lincity
     8  version:      1.13.1
     9  maintainer:   Enrico Weigelt, metux IT consult <info@metux.net>
    10  homepage:     http://lincity.sourceforge.net
    11  shortname:    Lincity
    12  name:         City simulation game
    13  license:      GPLv2
    14  description:  |
    15   Clone of the classic SimCity
    16  
    17  # srcdir: ../lincity
    18  
    19  configure:
    20      generate:
    21          - config.h:       config.h
    22            template:       config.h.template
    23            marker:         /*@@CONFIG_INSERTED_HERE@@*/
    24      checks:
    25          # using list instead of struct, so we can define the order
    26          - type:           target-distro
    27          - type:           c/compiler
    28            mandatory:      true
    29          - c/header:       dirent.h
    30            yes/c/defines:  HAVE_DIRENT_H
    31          - c/header:       stdlib.h
    32            mandatory:      true
    33          - c/header:       sys/stat.h
    34            mandatory:      true
    35          - c/function:     gettimeofday
    36            mandatory:      true
    37          - c/function:     popen
    38            yes/c/defines:  HAVE_POPEN
    39          - c/header:       stdint.h
    40            yes/c/defines:  HAVE_STDINT_H
    41          - c/header:       strings.h
    42            yes/c/defines:  HAVE_STRINGS_H
    43          - c/header:       string.h
    44            yes/c/defines:  HAVE_STRING_H
    45          - c/header:       sys/dir.h
    46            yes/c/defines:  HAVE_SYS_DIR_H
    47          - c/header:       sys/ndir.h
    48            yes/c/defines:  HAVE_SYS_NDIR_H
    49          - c/header:       sys/time.h
    50            yes/c/defines:  HAVE_SYS_TIME_H
    51          - c/header:       unistd.h
    52            yes/c/defines:  HAVE_UNISTD_H
    53          - pkgconf:
    54              x11:          x11
    55              xext:         xext
    56              zlib:         zlib
    57              libpng:       libpng
    58            mandatory:      true
    59          - type:           i18n/linguas
    60  
    61  misc:
    62      c/defines:
    63          - HAVE_CONFIG_H
    64          - DEFAULT_LIBDIR="${buildconf::@targetdist::install-dirs::datadir}/${package}"
    65          - LC_X11=1
    66          - VERSION="${version}"
    67          - ${buildconf::host::flags::c/defines}
    68      c/cflags:
    69          - -Wall
    70  
    71  targets:
    72      lincitymodules{c/library}:
    73          install:            false
    74          skip/shared:        true
    75          skip/pkgconf:       true
    76          include/dir:        [ ., ./modules ]
    77          c/defines:          ${misc::c/defines}
    78          c/cflags:           ${misc::c/cflags}
    79          source/dir:         modules
    80          source:             "*.c"
    81  
    82      lincityengine{c/library}:
    83          c/defines:          ${misc::c/defines}
    84          c/cflags:           ${misc::c/cflags}
    85          skip/shared:        true
    86          skip/pkgconf:       true
    87          link/static:        lincitymodules
    88          install:            false
    89          source:
    90              - lclib.c
    91              - power.c
    92              - ldsvguts.c
    93              - engine.c
    94              - transport.c
    95              - market.c
    96              - simulate.c
    97              - shrtypes.c
    98              - lintypes.c
    99              - readpng.c
   100              - timer.c
   101              - fileutil.c
   102              - shrglobs.c
   103              - stats.c
   104  
   105      lincitygui{c/library}:
   106          pkgconf/import:     [x11, xext, zlib, libpng, libc/math]
   107          link/static:        [lincityengine, lincitymodules]
   108          skip/shared:        true
   109          skip/pkgconf:       true
   110          c/defines:          ${misc::c/defines}
   111          c/ldflags:          ${misc::c/ldflags}
   112          c/cflags:           ${misc::c/cflags}
   113          install:            false
   114          source:
   115              - lcx11.c
   116              - ldsvgui.c
   117              - splash.c
   118              - lchelp.c
   119              - main.c
   120              - mouse.c
   121              - mps.c
   122              - screen.c
   123              - pixmap.c
   124              - cliglobs.c
   125              - geometry.c
   126              - pbar.c
   127              - module_buttons.c
   128              - dialbox.c
   129  
   130      lincity{c/executable}:
   131          pkgconf/import:     [x11, xext, zlib, libpng, libc/math]
   132          c/ldflags:          ${misc::c/ldflags}
   133          c/cflags:           ${misc::c/cflags}
   134  
   135          ## FIXME: order really matters here. need lincitymodules twice since circular dependency
   136          link/static:        [lincitygui, lincitymodules, lincityengine, lincitymodules]
   137  
   138      lincity.desktop{data/desktop}:
   139          desktop/categories: Application;Game;StrategyGame
   140          desktop/exec:       lincity
   141          desktop/tryexec:    ${buildconf::install-dirs::bindir}/lincity
   142  
   143      colour.pal{data/misc}:
   144          install/subdir:     ${package}
   145          source:             colour.pal
   146  
   147      opening{data/misc}:
   148          install/subdir:     ${package}/${@@^::@id}
   149          source:             "*"
   150          source/dir:         ${@@^::@id}
   151  
   152      messages{data/misc}:
   153          install/subdir:     ${package}/${@@^::@id}
   154          source:             "*.mes"
   155          source/dir:         ${@@^::@id}
   156  
   157      icons{data/misc}:
   158          install/subdir:     ${package}/${@@^::@id}
   159          source:             "*.csi"
   160          source/dir:         ${@@^::@id}
   161  
   162      lincity.xpm{data/pixmap}:
   163  
   164      help{data/misc}:
   165          install/subdir:     ${package}/${@@^::@id}
   166          source:             "*.hlp"
   167          source/dir:         ${@@^::@id}
   168  
   169      po{i18n/po}:
   170  
   171      docs{doc/misc}:
   172          source:
   173              - Acknowledgements
   174              - README
   175              - TODO
   176              - CHANGES
   177              - COPYING
   178              - COPYRIGHT
   179  
   180      lincity.6{doc/man}:
   181          man/alias:          xlincity
   182  
   183  features:
   184      gzip:
   185          type:     bool
   186          default:  y
   187          set@y:
   188              c/defines:      HAVE_GZIP=1
   189      nls:
   190          type:     bool
   191          default:  y
   192          set@y:
   193              c/defines:      [ENABLE_NLS, PACKAGE="lincity"]
   194  
   195  # currently really broken
   196  #    svgalib:
   197  #        type:     bool
   198  #        default:  n
   199  #        set@y:
   200  #            c/defines:      SVGALIB=1
   201  
   202  distro:
   203      _default_:
   204          packages:
   205              dev:
   206                  skip: true
   207              lib:
   208                  skip: true