Add header. Clean-up file. Add CMake file.

This commit is contained in:
Doru Bercea 2019-12-18 16:02:55 -05:00
parent f3207be963
commit b6a2a50dd8
4 changed files with 28 additions and 3 deletions

19
CMakeLists.txt Normal file
View File

@ -0,0 +1,19 @@
# TODO: remove for release.
if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE Debug CACHE STRING "build type")
endif()
# Require 3.3 and set policy CMP0057 for IN_LIST operator support
cmake_minimum_required(VERSION 3.3)
cmake_policy(SET CMP0057 NEW)
project(onnf)
set(CMAKE_CXX_FLAGS_DEBUG "-g")
set(CMAKE_CXX_FLAGS_RELEASE "-O2 -DNDEBUG")
set(ONNF_ROOT "${CMAKE_CURRENT_SOURCE_DIR}")
# Set cxx standard only for onnf project files.
set(CMAKE_CXX_STANDARD 14)
add_subdirectory(src/builder)

View File

@ -1,5 +1,3 @@
add_definitions(-DBOOST_LOG_DYN_LINK)
add_library(builder add_library(builder
sgir.cpp sgir.cpp
) )

View File

@ -1,3 +1,11 @@
//===----------------------------------------------------------------------===//
//
// Copyright 2019 The IBM Research Authors.
//
// =============================================================================
//
//===----------------------------------------------------------------------===//
#include "sgir.hpp" #include "sgir.hpp"
//empty module for MLIR is generated to test the compile/link of MLIR code //empty module for MLIR is generated to test the compile/link of MLIR code