 ;; buildX - build our ST friendly objects
 ;;-----------------------------------------------------------------
 
-(defn buildfunction [{:keys [rettype functionName param index]}]
+(defn- buildfunction [{:keys [rettype functionName param index]}]
   (vector functionName (->Function (when (not= rettype "void") rettype) functionName param index)))
 
-(defn buildfunctions [functions]
+(defn- buildfunctions [functions]
   (into {} (for [[k v] functions]
              (buildfunction v))))
 
-(defn buildinterface [base name interface]
+(defn- buildinterface [base name interface]
   (let [transactions (buildfunctions (:transactions interface))
         queries (buildfunctions (:queries interface))]
     (vector name (->Interface name (package-name name) (package-camel name) (package-path base name) transactions queries))))
 
-(defn build [base interfaces]
+(defn- build [base interfaces]
   (into {} (map (fn [[name interface]] (buildinterface base name interface)) interfaces)))
 
-(defn buildcci [ipath name]
+(defn- buildcci [ipath name]
   (let [path (io/file ipath (str name ".cci"))
         os (ByteArrayOutputStream.)]
 

;;------------------------------------------------------------------
;; X-cmd interfaces: Invoke external commands
;;------------------------------------------------------------------
(defn protoc-cmd [_path _proto]
  (let [path (->> _path io/file .getCanonicalPath)
        go_out (str "--go_out=" path)
        proto_path (str "--proto_path=" path)

;; structures suitable for surfacing via the
;; org.hyperledger.chaintool.meta interface
;;-----------------------------------------------------------------
(defn- render-metadata [config ipath]
  (let [facts (buildfacts config)
        provides (buildccis ipath (intf/getprovides config))]
    (render-golang "metadata" [["facts" facts]
