Skip to content

Commit

Permalink
Move build/win up to just build
Browse files Browse the repository at this point in the history
Since this tool is very specific to the Windows OS, there's no point
generalizing the build directory structure for other systems. This
change basically moves all build files up from the old `win` directory.

I also changed the output target of the experimental `netuse` tool to
direct output to `out/x64/Debug` instead of just `out`.
  • Loading branch information
hollasch committed Oct 16, 2016
1 parent 591ecf2 commit 94a7fd2
Show file tree
Hide file tree
Showing 6 changed files with 46 additions and 48 deletions.
41 changes: 19 additions & 22 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,27 +12,25 @@ command takes no arguments.
Usage
-----

```
drives 1.0
drives: Print drive and volume information.
Usage: drives [/?|-h|--help] [--version] [-v|--verbose] [-p|--parseable]
[drive]
drives 1.0
drives: Print drive and volume information.
Usage: drives [/?|-h|--help] [--version] [-v|--verbose] [-p|--parseable]
[drive]

Single letter options may use either dashes (-) or slashes (/) as option
prefixes, and are case insensitive. This program also prints all network
mappings and drive substitutions (see the 'subst' command).
Single letter options may use either dashes (-) or slashes (/) as option
prefixes, and are case insensitive. This program also prints all network
mappings and drive substitutions (see the 'subst' command).

--help / -h Print help information.
--help / -h Print help information.

--verbose / -v Print verbose; print additional information (only affects
human format).
--verbose / -v Print verbose; print additional information (only affects
human format).

--version Print program version.
--version Print program version.

--parseable / -p Print results in machine-parseable format.
--parseable / -p Print results in machine-parseable format.

[drive] Drive letter for single drive report.
```
[drive] Drive letter for single drive report.


Sample Output
Expand All @@ -49,13 +47,12 @@ Sample Output
Developing
----------

This project is managed with Visual Studio. It is built as a 64-bit application.
However, it is structured in a way that is friendly to add build setups from
other environments. Here's the overall tree structure:
This project is managed with Visual Studio, and is built as a 64-bit
application. However, it is structured in a way that is friendly to add build
setups from other environments. Here's the overall tree structure:

+---src
^---build
| ^---win
^---out
^---x64
^---Debug
Expand All @@ -67,10 +64,10 @@ other environments. Here's the overall tree structure:

Pure source files are in the `src` directory. The `build` directory contains all
of the configuration for build tools. For now, it just has the Visual Studio
build environment, in `build/win`. All generated build output goes to the `out`
directory (it's always safe to delete the entire `out` directory).
build environment and an `nmake`-style makefile. All generated build output goes
to the `out` directory (it's always safe to delete the entire `out` directory).

There's also a makefile that will build netuse, an experimental tool for now.
The makefile just builds netuse, an experimental tool for now.


--------------------------------------------------------------------------------
Expand Down
File renamed without changes.
14 changes: 7 additions & 7 deletions build/win/drives.vcxproj → build/drives.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\src\drives.cpp" />
</ItemGroup>
<PropertyGroup Label="Globals">
<ProjectGuid>{17B3A31D-06A2-4275-A777-D508F1769838}</ProjectGuid>
<Keyword>Win32Proj</Keyword>
Expand Down Expand Up @@ -71,16 +74,16 @@
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<LinkIncremental>true</LinkIncremental>
<OutDir>$(SolutionDir)..\..\out\$(Platform)\$(Configuration)\</OutDir>
<IntDir>$(SolutionDir)..\..\out\$(Platform)\$(Configuration)\intermediate\</IntDir>
<OutDir>$(SolutionDir)..\out\$(Platform)\$(Configuration)\</OutDir>
<IntDir>$(SolutionDir)..\out\$(Platform)\$(Configuration)\intermediate\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<LinkIncremental>false</LinkIncremental>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<LinkIncremental>false</LinkIncremental>
<OutDir>$(SolutionDir)..\..\out\$(Platform)\$(Configuration)\</OutDir>
<IntDir>$(SolutionDir)..\..\out\$(Platform)\$(Configuration)\intermediate\</IntDir>
<OutDir>$(SolutionDir)..\out\$(Platform)\$(Configuration)\</OutDir>
<IntDir>$(SolutionDir)..\out\$(Platform)\$(Configuration)\intermediate\</IntDir>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
Expand Down Expand Up @@ -152,9 +155,6 @@
<AdditionalDependencies>mpr.lib;%(AdditionalDependencies)</AdditionalDependencies>
</Link>
</ItemDefinitionGroup>
<ItemGroup>
<ClCompile Include="..\..\src\drives.cpp" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
</Filter>
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\..\src\drives.cpp">
<ClCompile Include="..\src\drives.cpp">
<Filter>Source Files</Filter>
</ClCompile>
</ItemGroup>
Expand Down
19 changes: 19 additions & 0 deletions build/makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@

LIBS = kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib \
advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib \
odbccp32.lib

OUT = ..\out\x64\Debug
SRC = ..\src
SRCFromOut = ..\..\..\src

all: $(OUT)\netuse.exe

$(OUT)\netuse.exe: $(SRC)\netuse.cpp
-mkdir 2>nul $(OUT)
cd $(OUT) & cl -nologo /Zi $(SRCFromOut)\netuse.cpp

clean clobber:
-cd $(OUT) & del 2>nul netuse.* vc120.pdb

fresh: clobber all
18 changes: 0 additions & 18 deletions build/win/makefile

This file was deleted.

0 comments on commit 94a7fd2

Please sign in to comment.