Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Doc]Refine README in cpp about building #182

Merged
merged 4 commits into from
Jun 6, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions cpp/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Building requires:
sufficient. For MacOS, at least clang 5 is required
* CMake 3.5 or higher
* On Linux and macOS, ``make`` build utilities
* curl-devel (Linux) or curl (macOS), for s3 filesystem support
* curl-devel with SSL (Linux) or curl (macOS), for s3 filesystem support

Dependencies for optional features:

Expand All @@ -43,7 +43,7 @@ Building
All the instructions below assume that you have cloned the GraphAr git
repository and navigated to the ``cpp`` subdirectory:

.. code-block::
.. code-block:: shell

$ git clone https://github.com/alibaba/GraphAr.git
$ cd GraphAr
Expand All @@ -52,12 +52,12 @@ repository and navigated to the ``cpp`` subdirectory:

Release build:

.. code-block::
.. code-block:: shell

$ mkdir build-release
$ cd build-release
$ cmake ..
$ make -j8 # if you have 8 CPU cores, otherwise adjust
$ make -j8 # if you have 8 CPU cores, otherwise adjust, use -j`nproc` for all cores
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we can unify the usage of ".. code-block:: shell" ".. code-block::" and ".. code:: shell" in this file

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! I unified it in both README of cpp and README of spark.

Has any other place where I can make it better?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! I unified it in both README of cpp and README of spark.

Has any other place where I can make it better?

Thanks for your contribution! This change looks good to me now.


Build with a custom namespace:

Expand All @@ -70,7 +70,7 @@ setting :code:`NAMESPACE` option with cmake:
$ mkdir build
$ cd build
$ cmake -DNAMESPACE=MyNamespace ..
$ make -j8 # if you have 8 CPU cores, otherwise adjust
$ make -j8 # if you have 8 CPU cores, otherwise adjust, use -j`nproc` for all cores

Debug build with unit tests:

Expand All @@ -80,7 +80,7 @@ Debug build with unit tests:
$ mkdir build-debug
$ cd build-debug
$ cmake -DCMAKE_BUILD_TYPE=Debug -DBUILD_TESTS=ON ..
$ make -j8 # if you have 8 CPU cores, otherwise adjust
$ make -j8 # if you have 8 CPU cores, otherwise adjust, use -j`nproc` for all cores
$ make test # to run the tests

Build with examples:
Expand All @@ -91,7 +91,7 @@ Build with examples:
$ mkdir build-examples
$ cd build-examples
$ cmake -DBUILD_EXAMPLES=ON ..
$ make -j8 # if you have 8 CPU cores, otherwise adjust
$ make -j8 # if you have 8 CPU cores, otherwise adjust, use -j`nproc` for all cores
$ ./bgl_example # run the BGL example

Install
Expand All @@ -101,7 +101,7 @@ After the building, you can install the GraphAr C++ library with:

.. code-block:: shell

$ sudo make install
$ sudo make install # run in directory you build, like build-release, build and so on

Generate API document
^^^^^^^^^^^^^^^^^^^^^
Expand Down
10 changes: 5 additions & 5 deletions spark/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Building
All the instructions below assume that you have cloned the GraphAr git
repository and navigated to the ``spark`` subdirectory:

.. code-block::
.. code-block:: shell

$ git clone https://github.com/alibaba/GraphAr.git
$ cd GraphAr
Expand All @@ -33,7 +33,7 @@ repository and navigated to the ``spark`` subdirectory:

Build the package:

.. code-block::
.. code-block:: shell

$ mvn clean package -DskipTests

Expand All @@ -42,19 +42,19 @@ After compilation, the package file graphar-x.x.x-SNAPSHOT-shaded.jar is generat

Build the package and run the unit tests:

.. code-block::
.. code-block:: shell

$ mvn clean package

Build and run the unit tests:

.. code-block::
.. code-block:: shell

$ mvn clean test

Build and run certain unit test:

.. code-block::
.. code-block:: shell

$ mvn clean test -Dsuites='com.alibaba.graphar.GraphInfoSuite' # run the GraphInfo test suite
$ mvn clean test -Dsuites='com.alibaba.graphar.GraphInfoSuite load graph info' # run the `load graph info` test of test suite
Expand Down