-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Kaiyang Wu <[email protected]>
- Loading branch information
1 parent
b955afa
commit c2408ed
Showing
3 changed files
with
68 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
#lang racket/base | ||
|
||
(require racket/contract | ||
"macro.rkt") | ||
|
||
; TODO: limit abtype and abhost to a set of valid values with contract | ||
(define-vars #f string? pkgname pkgsec abhost abtype) | ||
(define-vars #t string? pkgdes) | ||
(define-vars #f (listof string?) | ||
pkgdep builddep pkgrecom pkgbreak pkgsug pkgconfl pkgrep) | ||
(define-vars #f (listof string?) | ||
autotools-def cmake-def waf-def qtproj-def) | ||
(define-vars #t (listof string?) | ||
autotools-after cmake-after waf-after qtproj-after go-build-after | ||
cargo-after) | ||
(define-vars #f boolean? | ||
ab-flags-o3 ab-flags-specs ab-flags-ssp ab-flags-ftf ab-flags-rro | ||
nolto useclang ab-flags-pie ab-flags-pic abshadow abconfighack | ||
abclean noparallel abstrip absplitdbg) | ||
(define-vars #f boolean? reconf nopython2 nopython3) | ||
(define-vars #f exact-nonnegative-integer? | ||
abthreads) | ||
|
||
(struct defines-type (opts) #:transparent) | ||
|
||
(define/contract (defines opts) | ||
(-> (listof pair?) defines-type?) | ||
;; TODO: checks here | ||
(defines-type opts)) | ||
|
||
(define/contract (defines->string defines) | ||
(-> defines-type? string?) | ||
;; TODO: ->string here, apply ->string to each opt | ||
"") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters