Skip to content

Commit 503006f

Browse files
committed
Add project structure
1 parent 86b590f commit 503006f

20 files changed

+417
-0
lines changed

.gitattributes

Lines changed: 96 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,96 @@
1+
* text=auto !eol svneol=native#text/plain
2+
*.gitattributes text svneol=native#text/plain
3+
4+
# Scriptish formats
5+
*.bat text svneol=native#text/plain
6+
*.bsh text svneol=native#text/x-beanshell
7+
*.cgi text svneol=native#text/plain
8+
*.cmd text svneol=native#text/plain
9+
*.js text svneol=native#text/javascript
10+
*.php text svneol=native#text/x-php
11+
*.pl text svneol=native#text/x-perl
12+
*.pm text svneol=native#text/x-perl
13+
*.py text svneol=native#text/x-python
14+
*.sh eol=lf svneol=LF#text/x-sh
15+
configure eol=lf svneol=LF#text/x-sh
16+
17+
# Image formats
18+
*.bmp binary svneol=unset#image/bmp
19+
*.gif binary svneol=unset#image/gif
20+
*.ico binary svneol=unset#image/ico
21+
*.jpeg binary svneol=unset#image/jpeg
22+
*.jpg binary svneol=unset#image/jpeg
23+
*.png binary svneol=unset#image/png
24+
*.tif binary svneol=unset#image/tiff
25+
*.tiff binary svneol=unset#image/tiff
26+
*.svg text svneol=native#image/svg%2Bxml
27+
28+
# Data formats
29+
*.pdf binary svneol=unset#application/pdf
30+
*.avi binary svneol=unset#video/avi
31+
*.doc binary svneol=unset#application/msword
32+
*.dsp text svneol=crlf#text/plain
33+
*.dsw text svneol=crlf#text/plain
34+
*.eps binary svneol=unset#application/postscript
35+
*.gz binary svneol=unset#application/gzip
36+
*.mov binary svneol=unset#video/quicktime
37+
*.mp3 binary svneol=unset#audio/mpeg
38+
*.ppt binary svneol=unset#application/vnd.ms-powerpoint
39+
*.ps binary svneol=unset#application/postscript
40+
*.psd binary svneol=unset#application/photoshop
41+
*.rdf binary svneol=unset#text/rdf
42+
*.rss text svneol=unset#text/xml
43+
*.rtf binary svneol=unset#text/rtf
44+
*.sln text svneol=native#text/plain
45+
*.swf binary svneol=unset#application/x-shockwave-flash
46+
*.tgz binary svneol=unset#application/gzip
47+
*.vcproj text svneol=native#text/xml
48+
*.vcxproj text svneol=native#text/xml
49+
*.vsprops text svneol=native#text/xml
50+
*.wav binary svneol=unset#audio/wav
51+
*.xls binary svneol=unset#application/vnd.ms-excel
52+
*.zip binary svneol=unset#application/zip
53+
54+
# Text formats
55+
.htaccess text svneol=native#text/plain
56+
*.bbk text svneol=native#text/xml
57+
*.cmake text svneol=native#text/plain
58+
*.css text svneol=native#text/css
59+
*.dtd text svneol=native#text/xml
60+
*.htm text svneol=native#text/html
61+
*.html text svneol=native#text/html
62+
*.ini text svneol=native#text/plain
63+
*.log text svneol=native#text/plain
64+
*.mak text svneol=native#text/plain
65+
*.qbk text svneol=native#text/plain
66+
*.rst text svneol=native#text/plain
67+
*.sql text svneol=native#text/x-sql
68+
*.txt text svneol=native#text/plain
69+
*.xhtml text svneol=native#text/xhtml%2Bxml
70+
*.xml text svneol=native#text/xml
71+
*.xsd text svneol=native#text/xml
72+
*.xsl text svneol=native#text/xml
73+
*.xslt text svneol=native#text/xml
74+
*.xul text svneol=native#text/xul
75+
*.yml text svneol=native#text/plain
76+
boost-no-inspect text svneol=native#text/plain
77+
CHANGES text svneol=native#text/plain
78+
COPYING text svneol=native#text/plain
79+
INSTALL text svneol=native#text/plain
80+
Jamfile text svneol=native#text/plain
81+
Jamroot text svneol=native#text/plain
82+
Jamfile.v2 text svneol=native#text/plain
83+
Jamrules text svneol=native#text/plain
84+
Makefile* text svneol=native#text/plain
85+
README text svneol=native#text/plain
86+
TODO text svneol=native#text/plain
87+
88+
# Code formats
89+
*.c text svneol=native#text/plain
90+
*.cpp text svneol=native#text/plain
91+
*.h text svneol=native#text/plain
92+
*.hpp text svneol=native#text/plain
93+
*.ipp text svneol=native#text/plain
94+
*.tpp text svneol=native#text/plain
95+
*.jam text svneol=native#text/plain
96+
*.java text svneol=native#text/plain

CMakeLists.txt

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# Generated by `boostdep --cmake decimal`
2+
# Copyright 2020, 2021 Peter Dimov
3+
# Distributed under the Boost Software License, Version 1.0.
4+
# https://www.boost.org/LICENSE_1_0.txt
5+
6+
cmake_minimum_required(VERSION 3.8...3.20)
7+
8+
project(boost_decimal VERSION "${BOOST_SUPERPROJECT_VERSION}" LANGUAGES CXX)
9+
10+
add_library(boost_decimal
11+
src/decimal32.cpp
12+
)
13+
14+
add_library(Boost::decimal ALIAS boost_decimal)
15+
16+
target_include_directories(boost_decimal PUBLIC include)
17+
18+
target_link_libraries(boost_decimal
19+
PUBLIC
20+
Boost::config
21+
)
22+
23+
target_compile_features(boost_decimal PUBLIC cxx_std_14)
24+
25+
target_compile_definitions(boost_decimal
26+
PUBLIC BOOST_CHARCONV_NO_LIB
27+
PRIVATE BOOST_CHARCONV_SOURCE
28+
)
29+
30+
if(BUILD_SHARED_LIBS)
31+
target_compile_definitions(boost_decimal PUBLIC BOOST_DECIMAL_DYN_LINK)
32+
else()
33+
target_compile_definitions(boost_decimal PUBLIC BOOST_DECIMAL_STATIC_LINK)
34+
endif()
35+
36+
if(BUILD_TESTING AND EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/test/CMakeLists.txt")
37+
38+
add_subdirectory(test)
39+
40+
endif()

build/Jamfile

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# Copyright 2023 Matt Borland
2+
# Distributed under the Boost Software License, Version 1.0.
3+
# https://www.boost.org/LICENSE_1_0.txt
4+
5+
import ../../config/checks/config : requires ;
6+
7+
project boost/decimal ;
8+
9+
local SOURCES = decimal32.cpp ;
10+
11+
lib boost_decimal
12+
13+
# sources
14+
: ../src/$(SOURCES)
15+
16+
# requirements
17+
: <link>shared:<define>BOOST_DECIMAL_DYN_LINK=1
18+
<define>BOOST_DECIMAL_SOURCE=1
19+
20+
[ requires cxx14_decltype_auto cxx14_generic_lambdas cxx14_return_type_deduction cxx14_variable_templates ]
21+
22+
23+
# default-build
24+
:
25+
26+
# usage-requirements
27+
: <link>shared:<define>BOOST_DECIMAL_DYN_LINK=1
28+
;
29+
30+
boost-install boost_decimal ;

doc/.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
/pdf/
2+
/html/

doc/Jamfile

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Copyright 2017, 2018 Peter Dimov
2+
# Distributed under the Boost Software License, Version 1.0.
3+
# https://www.boost.org/LICENSE_1_0.txt
4+
5+
import asciidoctor ;
6+
7+
html decimal.html : decimal.adoc ;
8+
9+
install html_ : decimal.html : <location>html ;
10+
11+
pdf decimal.pdf : decimal.adoc ;
12+
explicit decimal.pdf ;
13+
14+
install pdf_ : decimal.pdf : <location>pdf ;
15+
explicit pdf_ ;
16+
17+
###############################################################################
18+
alias boostdoc ;
19+
explicit boostdoc ;
20+
alias boostrelease : html_ ;
21+
explicit boostrelease ;

doc/decimal-docinfo-footer.html

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<style>
2+
3+
*:not(pre)>code { background: none; color: #600000; }
4+
:not(pre):not([class^=L])>code { background: none; color: #600000; }
5+
6+
</style>

doc/decimal.adoc

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
////
2+
Copyright 2023 Matt Borland
3+
Distributed under the Boost Software License, Version 1.0.
4+
https://www.boost.org/LICENSE_1_0.txt
5+
////
6+
7+
# Decimal: An Implementation of IEEE 754 Decimal Floating Point Numbers
8+
:toc: left
9+
:toclevels: 4
10+
:idprefix:
11+
:listing-caption: Code Example
12+
:docinfo: private-footer
13+
:source-highlighter: rouge
14+
:source-language: c++
15+
16+
:leveloffset: +1
17+
18+
include::decimal/overview.adoc[]
19+
include::decimal/reference.adoc[]
20+
include::decimal/copyright.adoc[]
21+
22+
:leveloffset: -1

doc/decimal/copyright.adoc

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
////
2+
Copyright 2023 Peter Dimov
3+
Distributed under the Boost Software License, Version 1.0.
4+
https://www.boost.org/LICENSE_1_0.txt
5+
////
6+
7+
[#copyright]
8+
# Copyright and License
9+
:idprefix:
10+
11+
This documentation is copyright 2023 Matt Borland and is distributed under
12+
the http://www.boost.org/LICENSE_1_0.txt[Boost Software License, Version 1.0].

doc/decimal/overview.adoc

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
////
2+
Copyright 2023 Matt Borland
3+
Distributed under the Boost Software License, Version 1.0.
4+
https://www.boost.org/LICENSE_1_0.txt
5+
////
6+
7+
[#overview]
8+
# Overview
9+
:idprefix: overview_
10+
11+
## Description
12+
13+
...
14+
15+
## Usage Examples
16+
17+
...
18+
19+
## Supported Compilers
20+
21+
* GCC 5 or later
22+
* Clang 5 or later
23+
* Visual Studio 2017 or later
24+
25+
Tested on https://github.com/cppalliance/decimal/actions[Github Actions].

doc/decimal/reference.adoc

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
////
2+
Copyright 2023 Peter Dimov
3+
Distributed under the Boost Software License, Version 1.0.
4+
https://www.boost.org/LICENSE_1_0.txt
5+
////
6+
7+
[#reference]
8+
# Reference
9+
:idprefix: ref_
10+
11+
## <boost/decimal/decimal32.hpp
12+
13+
### Synopsis
14+
15+
## <boost/decimal.hpp>
16+
17+
This convenience header includes all headers previously
18+
mentioned.

0 commit comments

Comments
 (0)